Optiframe

Optiframe is an optimization framework for writing mixed integer programs (MIPs).
It allows you to structure your MIPs in a way that allows clear separation of concerns, high modularity and testability.
Core Concepts
- The optimization process is divided into multiple steps which are clearly separated:
- Validation allows you to validate the input data.
- Pre-processing allows you to optimize the provided data to reduce the size of the final model.
- MIP building allows you to modify the MIP to define the optimization problem.
- Solving is a pre-defined step that obtains an optimal solution for the problem.
- Solution extraction allows you to process the variable values of the solution into something more meaningful.
- Tasks are the core components that allow you to implement functionality for each step.
- The constructor of a task allows you to define dependencies for that task, which are automatically injected by the optimizer based on their type annotation.
- The execute method allows you to implement the functionality. It may return data which can then be used by other tasks as a dependency.
- Modules combine tasks that belong together. Each module must contain a task for building the MIP and can additionally contain tasks for validation, pre-processing and solution extraction. The modules are what makes Optiframe so extendable: You can define extensions of a problem in a separate module and only include it if needed.
- The optimizer allows you to configure the packages that you need. Afterwards, you can initialize it with the instance data and then solve the optimization problem.
Installation & Usage
pip install optiframe
Take a look at the examples folder for examples on how to use Optiframe!
License
This project is available under the terms of the MIT license.
Metadata
Release files for optiframe 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| optiframe-0.5.0.tar.gz | 11.5 kB | Without provenance | Details for optiframe-0.5.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| optiframe-0.5.0-py3-none-any.whl | Python 3 | none | any | Details for optiframe-0.5.0-py3-none-any.whl |
Total release size: 26.2 kB
Release files / optiframe-0.5.0.tar.gz
| Download URL | optiframe-0.5.0.tar.gz |
|---|---|
| Size | 11.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d42a7277ca7184017da7a8ca2d658f1e46f7b2de66c3ee8e1683e4cfde422a90
|
|
BLAKE2b-256 checksum How to use checksums |
dd8cb7b57f0debafcfff7b6adec22cfc696dc7e5fc983e554641b34b1a356a14
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.3.2 CPython/3.10.6 Linux/6.2.6-76060206-generic
|
Release files / optiframe-0.5.0-py3-none-any.whl
| Download URL | optiframe-0.5.0-py3-none-any.whl |
|---|---|
| Size | 14.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b345eb113182d1a698d36378f8212983da913cee72bee38fb303ada5a6b6b61b
|
|
BLAKE2b-256 checksum How to use checksums |
6db418d3cfc81dbe88c9aa91146b10a37e816b58a3ed1434494fefddac8101b2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.3.2 CPython/3.10.6 Linux/6.2.6-76060206-generic
|
Security for optiframe 0.5.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.