Skip to content

Speed up lazy vector-backed LP and NLP solves#130

Merged
daggbt merged 2 commits into
mainfrom
experiment/lazy-vectorvariable
May 14, 2026
Merged

Speed up lazy vector-backed LP and NLP solves#130
daggbt merged 2 commits into
mainfrom
experiment/lazy-vectorvariable

Conversation

@daggbt
Copy link
Copy Markdown
Collaborator

@daggbt daggbt commented May 14, 2026

Summary

Preserve lazy VectorVariable metadata further into LP and SciPy solve setup so single-vector problems avoid unnecessary scalar materialization and compile overhead.

What changed

  • propagate lazy vector metadata through LP extraction, bounds handling, and solver setup
  • add a contiguous single-vector compile/cache path for SciPy NLP solves to avoid repeated per-element name generation and index lookups
  • keep solution values lazy on the solver result path while preserving warm-start behavior
  • add regression coverage for the lazy-cache/compiler paths and refresh benchmark artifacts/docs

Why

These changes carry the constructor-side lazy vector win through problem.solve(), reducing cold-start overhead for large single-vector NLPs while keeping the Python implementation path intact.

@daggbt daggbt merged commit f870fb6 into main May 14, 2026
3 checks passed
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.

1 participant