forked from cvxpy/cvxpy
-
Notifications
You must be signed in to change notification settings - Fork 1
sync from master #135
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Transurgeon
wants to merge
15
commits into
cvxgrp:master
Choose a base branch
from
cvxpy:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
sync from master #135
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* WIP - I have two questions in NOTES - I want to add a small test to verify that the variable names do appear in the exported LP files - I need to remove the lines that export the LPs * Refactor logic into a collect_column_names function and add tests * make linter happy * Fix HiGHS LP export test for Windows * Remove accidental breakpoint() from CuClarabel test * Cleanup HiGHS write_model_file implementation - Fix type hint: validate_column_name returns None, not bool - Extract set_column_names_from_variables() helper to reduce duplication - Remove outdated TODO about HiGHS PR #2274 (merged in v1.11.0) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> --------- Co-authored-by: Halil Sen <20163961+senhalil@users.noreply.github.com> Co-authored-by: Steven Diamond <diamond@cs.stanford.edu> Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
* feat: support warm_start for COPT QP extension * feat: add copt warmstart test
* first prototype of nd matmul * cleaning up and adding tests * more and cleaner ND matmul tests * unified code paths * remove kron_r * further unification of methods * make COO matmul clearer * add unit tests and optimize more cases * align scipy and coo * tests + broadcasting * clarify cases for mul backend * all tests pass * clarification / cleanup * attempt at cleanup * clarify get constant data * fix failing tests * distinguish reshape use cases * reorganized new tests * remove unneeded comments * remove erroneous test * Add comprehensive docstrings for COO backend ND-matmul operations Improve documentation for key functions in the COO canonicalization backend: - `select_rows`: Explain broadcast deduplication and param_idx handling - `_select_rows_no_duplicates`: Add concrete example of reverse mapping - `_select_rows_with_duplicates`: Detailed algorithm walkthrough with example - `_kron_nd_structure`: Explain why I_n ⊗ C ⊗ I_B structure is needed for batched matmul, with full derivation and visual example - `_build_interleaved`: Explain batch-varying constant handling with interleaved indexing pattern and concrete matrix example - `mul`: Document the three cases (parametric, batch-varying, 2D constant) and why each requires different handling - `broadcast_to`, `promote`: Explain how they create duplicate row indices Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * Add detailed docstring for reshape_parametric_constant Document the broadcast deduplication logic: - Explain why duplicates occur (broadcast via select_rows) - Show what goes wrong without deduplication - Concrete example: P(2,3) broadcast to (4,2,3) showing before/after - Explain param_idx to (row, col) position calculation Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * Address review comments on PR #3048 - Add cross-reference from select_rows to broadcast_to/reshape_parametric_constant - Add assertion that batch-varying constants are non-parametric - Add detection logic section to mul() docstring - Clarify comment about p in scipy_backend reshape - Add detailed comment explaining broadcast detection via duplicate param_idx Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> --------- Co-authored-by: William Zijie Zhang <william@gridmatic.com> Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Steven Diamond <steven@optimalintellect.com>
* iterating on moreau interface * fix pcp tests * fixed tests * Add MOREAU to CITATION_DICT and fix missing solver imports - Add MOREAU citation to centralized CITATION_DICT - Update moreau_conif.py to use CITATION_DICT instead of hardcoded citation - Add missing solver imports to conic_solvers/__init__.py: COSMO, CUCLARABEL, CUOPT, ECOS_BB, MOREAU - Sort imports alphabetically for consistency Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * change url * unneeded special handling for IPM settings * docs * back to old table * remove unnecesssary soc3 changes * ruff fixes * fix soc dim 3 * dimension check * address comments --------- Co-authored-by: Steven Diamond <steven@optimalintellect.com> Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
* Complete trace TODO in sparse covariance estimate example * Shift from trace to vdot for speed improvement * Add explanation for use of vdot
Add a dismissable banner to the documentation announcing: - The inaugural CVXPY Community Workshop on Feb 20-21 at Stanford/Zoom - Listening sessions for community feedback Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
* add ND rmul backend support * remove extra copy * round of review * working on aligning mul and rmul * align mul and rmul * fix: handle 1D vectors correctly in get_nd_rmul_dims For 1D vectors in rmul (w @ alpha where both are 1D): - Variable w is (k,) treated as row vector (1, k), so m=1 - Constant alpha is (k,) treated as column vector (k, 1), so n=1 The previous code incorrectly used var_shape[0] for m and const_shape[-1] for n, which caused dimension mismatches like (3, 9) @ (3, 3). Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * test: add regression test for 1D vector @ 1D constant Test the case where both variable and constant are 1D vectors, which produces a scalar result. This catches the bug fixed in the previous commit where get_nd_rmul_dims incorrectly computed m and n for 1D vectors. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Bumps [JamesIves/github-pages-deploy-action](https://github.com/jamesives/github-pages-deploy-action) from 4.7.6 to 4.8.0. - [Release notes](https://github.com/jamesives/github-pages-deploy-action/releases) - [Commits](JamesIves/github-pages-deploy-action@v4.7.6...v4.8.0) --- updated-dependencies: - dependency-name: JamesIves/github-pages-deploy-action dependency-version: 4.8.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
The moreau solver API has been updated to remove the `l` and `u` variable bounds parameters. Variable bounds are now handled through CVXPY's standard constraint mechanism via the CvxAttr2Constr reduction. Changes: - Set BOUNDED_VARIABLES = False to use constraint-based bounds - Remove bounds extraction and passing in solve_via_data() Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
* Add num_iters to gurobi conic solver * Use hasattr * ruff * Address comment
The SOCDim3 reduction failed with IndexError when X was a scalar (shape ()) because len(X.shape) == 0 was not handled. Changed the condition from `len(X.shape) == 1` to `len(X.shape) <= 1` to handle both scalar and 1D cases. Added regression test test_scalar_x_soc that verifies scalar SOC constraints work correctly through the decomposition. Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Please include a short summary of the change.
Issue link (if applicable):
Type of change
Contribution checklist