Skip to content

feat: support sparse inline linear solves#117

Open
AayushSabharwal wants to merge 1 commit into
mainfrom
as/sparse-inline-linsolve
Open

feat: support sparse inline linear solves#117
AayushSabharwal wants to merge 1 commit into
mainfrom
as/sparse-inline-linsolve

Conversation

@AayushSabharwal

Copy link
Copy Markdown
Member

The switching condition is just a heuristic.


A_sparsity = min(round(Int, 100 * count(SU._iszero ∘ unwrap, A) / length(A)), 99)
use_sparse_A = (A_sparsity == 97 && 80 <= N <= 120) ||
(A_sparsity == 98 && 150 <= N <= 250) || (A_sparsity == 99 && N >= 100)

@baggepinnen baggepinnen Jun 23, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isn't it strange that the lower N-bound for use_sparse_A is 80, 150, 100 as sparsity increases?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, the 150 is an odd one out. I forgot why I did that 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants