• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

FlexMeasures / flexmeasures / 30826076910
84%

Build:
DEFAULT BRANCH: main
Ran 03 Aug 2026 03:19PM UTC
Jobs 1
Files 175
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

03 Aug 2026 03:08PM UTC coverage: 83.653% (+0.2%) from 83.465%
30826076910

push

github

web-flow
Add a Pyomo-free scheduling backend (direct highspy model construction) (#2364)

* feat: direct HiGHS (highspy) implementation of the device scheduler

Add flexmeasures/data/models/planning/highspy_optimization.py, which builds
the device scheduler's LP/MILP directly with the HiGHS Python API (highspy),
bypassing Pyomo's model construction and solution-ingestion overhead. The
Pyomo implementation (linear_optimization.device_scheduler) remains the
semantic reference; the module docstring prominently documents that the two
models must be kept in sync, as well as the (verified) deviations:

- ems_flow_commitment_equalities are not built: on the Pyomo path they are
  bound-less, i.e. free rows without any effect on the solution
- rows no finite assignment can satisfy (bounds involving +/-inf quantities)
  are skipped, mirroring HiGHS rejecting such rows when appsi adds them
- solver results and model are lightweight shims exposing the attributes
  callers consume (termination_condition/status strings, commitment_costs,
  commodity_costs, costs, and indexed variable views)

The model is built with vectorized numpy arrays (addVars/addRows/
changeColsCost/changeColsIntegrality), constructing and solving typical
battery problems in milliseconds, where the Pyomo layer needs seconds.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WtuVTVfL4fQ9QSqbLXmAGD
Signed-off-by: F.N. Claessen <claessen@seita.nl>

* feat: expose the direct HiGHS backend as solver choice "highspy"

When FLEXMEASURES_LP_SOLVER is set to "highspy", device_scheduler delegates
to device_scheduler_highspy with the same inputs and the same return
contract. All other solver names keep using the Pyomo path unchanged.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WtuVTVfL4fQ9QSqbLXmAGD
Signed-off-by: F.N. Claessen <claessen@seita.nl>

* tests: prove equivalence of the highspy and Pyomo... (continued)

582 of 624 new or added lines in 4 files covered. (93.27%)

21 existing lines in 1 file now uncovered.

16995 of 20316 relevant lines covered (83.65%)

0.84 hits per line

Uncovered Changes

Lines Coverage ∆ File
30
86.96
flexmeasures/data/models/planning/scheduling_problem.py
9
97.38
flexmeasures/data/models/planning/highspy_optimization.py
3
89.16
-2.19% flexmeasures/data/models/planning/linear_optimization.py

Coverage Regressions

Lines Coverage ∆ File
21
89.16
-2.19% flexmeasures/data/models/planning/linear_optimization.py
Jobs
ID Job ID Ran Files Coverage
1 30826076910.1 03 Aug 2026 03:19PM UTC 175
83.65
GitHub Action Run
Source Files on build 30826076910
  • Tree
  • List 175
  • Changed 2
  • Source Changed 2
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #30826076910
  • fc0b7bda on github
  • Prev Build on main (#30822135090)
  • Next Build on main (#30855245504)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc