This project provides a unified containerized environment for running multiple optimization approaches — CP (Constraint Programming), MIP (Mixed Integer Programming), and SMT (Satisfiability Modulo Theories) — using MiniZinc and Python.
Each approach runs its own solver logic and saves results to a corresponding folder under /res.
project/
│
├── source/ # Source code for each approach
│ ├── CP/
│ ├── SAT/
│ ├── SMT/
│ └── MIP/
│
├── res/ # Output directory (results stored here)
│ ├── CP/
│ ├── SAT/
│ ├── SMT/
│ └── MIP/
│
├── entrypoint.sh # Main entrypoint controlling which approach to run
└── Dockerfile # Docker build configuration
- Docker installed on your system
- (Optional)
gitif you’re cloning the repository
From the root of the project, run:
docker build -t sts .This will:
- Install Python 3.11 and MiniZinc 2.9.4 inside the container
- Copy the project files
- Make entrypoint.sh the container’s default entrypoint
To run the container:
docker run --rm -v "$(pwd)/source:/sports_tournament_scheduling/source" -v "$(pwd)/res:/sports_tournament_scheduling/res" -it stsThis will run the Approach wizard, which will let you choose which approach you want to run and the number of the instance size
### 2. Run specific approach
```bash
docker run --rm -v "$(pwd)/source:/sports_tournament_scheduling/source" -v "$(pwd)/res:/sports_tournament_scheduling/res" -it sts --approach CP
```
### 3. Run specific approach with instance size
```bash
docker run --rm -v "$(pwd)/source:/sports_tournament_scheduling/source" -v "$(pwd)/res:/sports_tournament_scheduling/res" -it sts --approach CP --instance 10
```
sudo docker run --rm -v "$(pwd)/source:/sports_tournament_scheduling/source" -v "$(pwd)/res:/sports_tournament_scheduling/res" -it --entrypoint python3 sts source/CP/run.py -n 18 --sb 1 --solver chuffed
### Run solution checker:
```bash
python "$(pwd)/soulution_checker.py" 'res/CP'
```