Add Paper Problem 1 upstream reference generation#33
Open
bernalde wants to merge 1 commit into
Open
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
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.
Summary
benchmarks/paper_problem1_reference.pyto generate the Paper Problem 1 upstream reference via a batch-safe MATLAB wrapper, without editing the upstream clone..matloading to preserve full-reference fields (policy,tsw) and expose metrics needed for initialization/comparison.compare_paper_problem1_trajectories()for Pyomo-vs-upstream drying time, first switch time, terminal interface position, and max-temperature deviations.Tests run
python -m ruff check lyopronto/pyomo_models/paper_ocp.py lyopronto/pyomo_models/__init__.py benchmarks/paper_problem1_reference.py tests/test_pyomo_models/test_paper_ocp.py tests/test_pyomo_models/test_init.py- passed.pytest tests/test_pyomo_models/test_paper_ocp.py tests/test_pyomo_models/test_init.py -k 'load_upstream or compare_paper_problem1 or reference_runner or pyomo_exports' -n 0- 5 passed, 14 deselected.pytest tests/test_pyomo_models/test_paper_ocp.py -m 'not slow' -n 0- 11 passed, 3 deselected.pytest tests/test_pyomo_models/test_init.py -n 0- 5 passed.python benchmarks/paper_problem1_reference.py generate --runner-only --work-dir /tmp/lyopronto-paper-problem1-runner --upstream-root /home/bernalde/repos/simDAE-optimalcontrol-lyo --output /tmp/lyopronto-paper-problem1-reference.mat- passed; wrote the batch-safe MATLAB wrappers and printed thematlab -batchcommand.git diff --checkandgit diff --cached --check- passed.Notes about tests not run
matlabexecutable on PATH; the runner-only mode verified generation of the MATLAB wrapper files and command.pytest tests/test_pyomo_models -m 'not slow' -n 0 --maxfail=1failed during collection withModuleNotFoundError: No module named 'tests.utils'; direct Python imports can resolvetests.utils.python -m pytest tests/test_pyomo_models -m 'not slow' -n 0 --maxfail=1; it progressed through existing optimizer replay tests and was stopped after it became impractically long for this issue pass.Closes #27