Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose write_to_file and compute_iis #61

Merged
merged 10 commits into from
Jan 10, 2025

Conversation

sstroemer
Copy link
Member

This is linked to (depends on) this core PR.

This fixes #60.


This pull request includes several updates and improvements across multiple files. The changes focus on enhancing functionality, fixing bugs, and updating dependencies. Below are the most important changes:

Enhancements:

  • Added a new section in the documentation to explain how to force a solver executable version by explicitly adding the corresponding _jll as a dependency (docs/pages/manual/python/configuration.md).

  • Introduced a new method write_to_file in the Model class to write the model to a file, with detailed documentation and examples (src/iesopt/model.py).

  • Added a new method compute_iis in the Model class to compute and print the Irreducible Infeasible Set (IIS) of the model, including optional file output and examples (src/iesopt/model.py).

Dependency Updates:

  • Updated the IESOPT_CORE, IESOPT_JUMP, and IESOPT_SOLVER_HIGHS versions in the Config class (src/iesopt/config.py).

  • Bumped the project version from 2.2.1 to 2.3.0 in pyproject.toml.

Bug Fixes:

  • Fixed the key transformation logic in the init method of the Config class to handle keys starting with IESOPT_PKG_ correctly (src/iesopt/config.py).

  • Enhanced error logging in the jl_safe_seval function to include exception details (src/iesopt/julia/util.py).

  • Improved the setup_julia function to handle exceptions when importing and adding custom Julia packages (src/iesopt/julia/setup.py).

@sstroemer
Copy link
Member Author

The (already anticipated) IESopt core version currently does not exist - after the linked PR is merged and the new release is registered, tests should pass.

@sstroemer
Copy link
Member Author

Note: tests are "passing" but fail due to some sort of juliacall-in-environment issue (that normally requires cleaning the julia env). Does not seem to happen with uv and only with poetry, so merging for now since we will switch anyways.

@sstroemer sstroemer merged commit ec53075 into ait-energy:main Jan 10, 2025
2 of 3 checks passed
@sstroemer sstroemer deleted the feature-writefile-iis branch January 10, 2025 10:22
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.

Add compute_IIS to Python API
1 participant