Open
Conversation
- Remove leftover `display(S)` debug statement in coloring.jl - Add missing `Int[]` for `hess_J` field in `_FunctionStorage` else branch https://claude.ai/code/session_01WBu9hZukriWDSSybN9gfBq
- Build lower triangular sparsity pattern (row >= col) instead of full symmetric matrix, so decompress_csc! with :L works correctly - Always add diagonal entries explicitly (old Coloring module did this implicitly; SMC requires them to be in the sparsity pattern) - Get CSC structure directly from the sparse matrix instead of going through compress/decompress - Switch decompress_csc! from :U to :L to match lower triangular storage - Update test expectations to CSC lower triangular order: J=[1,1,2] (was [1,2,1]), V=[3.4,2.1,1.3] (was [3.4,1.3,2.1]) https://claude.ai/code/session_01WBu9hZukriWDSSybN9gfBq
The SMC-based Hessian recovery stores nonzeros in lower triangular CSC format (column-major: all entries of column j before column j+1, with diagonal first in each column). Update all multivariate Hessian structure and value expectations to match this ordering instead of the old diagonal-first ordering. https://claude.ai/code/session_01WBu9hZukriWDSSybN9gfBq
…ad of Base.promote_op
Base.promote_op may return Any for SMC.coloring since it lacks an explicit return
type annotation, causing TypeError when constructing _FunctionStorage{Any} because
Any <: AbstractColoringResult is false. Use a small test coloring call instead.
https://claude.ai/code/session_01WBu9hZukriWDSSybN9gfBq
48c9f41 to
68d6fe9
Compare
…or_preprocess The function was returning I/J in local variable indices but callers use them as global variable indices (for hessian_lagrangian_structure). This caused wrong sparsity patterns when a function depends on non-contiguous variables (e.g., variables 4 and 5 out of 5 total). https://claude.ai/code/session_01WBu9hZukriWDSSybN9gfBq
… coloring
Pass a full symmetric sparsity pattern to SMC.coloring instead of lower
triangular, so the tree edges are correctly oriented. Store full_colptr,
lower_pos, and full_buffer in ColoringResult to allow recovery via
decompress_csc! with :F, then extract lower-triangular values.
This fixes: BoundsError: attempt to access 0-element Vector{Int64} at index [1]
in test_coloring_end_to_end_hessian_coloring_and_recovery.
https://claude.ai/code/session_01WBu9hZukriWDSSybN9gfBq
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## bl/sparse_matrix_col #35 +/- ##
=======================================================
Coverage ? 89.28%
=======================================================
Files ? 19
Lines ? 2072
Branches ? 0
=======================================================
Hits ? 1850
Misses ? 222
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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
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.
No description provided.