Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
0d79683
Update 2025 deps
KristijanFaust-OET Feb 18, 2026
a6c437c
Switch to the testing private bucket
KristijanFaust-OET Feb 18, 2026
c963bf0
Implement support for commercial solvers
KristijanFaust-OET Feb 19, 2026
6b31612
Switch to commercial solvers brnahc on startup
KristijanFaust-OET Feb 19, 2026
c0e2092
Fix license environment propagation
KristijanFaust-OET Feb 19, 2026
8d36009
Fix knitro param input
KristijanFaust-OET Feb 19, 2026
13ba1b0
Utils: add years to allocate_benchmark, cleanup
siddharth-krishna Feb 19, 2026
1dd4a1d
Ignore solver-benchmarks-private/
siddharth-krishna Feb 19, 2026
3d31cce
Add some extra pypsa sizes to benchmark
siddharth-krishna Feb 19, 2026
ffac816
Turn off crossover for newly added commercial solvers
KristijanFaust-OET Feb 20, 2026
17ab6de
Turn off crossover for gurobi
KristijanFaust-OET Feb 20, 2026
2eb9ca1
Fix for CPLEX trail license
KristijanFaust-OET Feb 20, 2026
2a86a2a
Debug CPLEX installer
KristijanFaust-OET Feb 20, 2026
6345cc5
Add JRE for CPLEX
KristijanFaust-OET Feb 20, 2026
8c1f954
Fix cplex runtime report
KristijanFaust-OET Feb 20, 2026
8bc4bb6
use SolutionTarget instead of Crossover for gurobi
siddharth-krishna Feb 25, 2026
7dc6562
Merge branch 'main' into commercial-solvers-run
siddharth-krishna Mar 16, 2026
855cf23
Set uniform LP tolerances, don't ask for basic solutions
siddharth-krishna Mar 17, 2026
b1d4bae
Merge branch 'main' into commercial-solvers-run
siddharth-krishna Mar 22, 2026
306ed6d
Add comm. solver colors; fix plot fn modifying df
siddharth-krishna Mar 23, 2026
3cf1daf
Add pypsa-eur-elec-uc-50-168h and categorize
siddharth-krishna Mar 28, 2026
e6b3c0c
Add pypsa-de-elec-uc-2-24h
siddharth-krishna Mar 28, 2026
63e2aed
Add all pypsa-de-elec-uc sizes we have so far
siddharth-krishna Apr 5, 2026
6c70e4d
Run pre-commit
danielelerede-oet Apr 15, 2026
7038ead
Expose Mosek solver time
danielelerede-oet Apr 15, 2026
5efa8f5
Merge branch 'main' into commercial-solvers-run
danielelerede-oet Apr 15, 2026
e273927
Add pypsa-de-uc benchmarks
danielelerede-oet Apr 15, 2026
c647501
Run pre-commit
danielelerede-oet Apr 15, 2026
0291e0b
Pre-commit
danielelerede-oet Apr 22, 2026
1419706
Fix handling of invalid solver runs: mark unknown termination as ER a…
danielelerede-oet Apr 22, 2026
31677d2
Modify mosek notebook
danielelerede-oet May 5, 2026
e2049bb
Add pypsa-de-sec scaling benchmarks
danielelerede-oet May 6, 2026
5bdf255
Categorize new pypsa benchmarks
danielelerede-oet May 6, 2026
acb819f
Fix is_mip_problem
danielelerede-oet May 26, 2026
ab3b076
Update pypsa metadata
danielelerede-oet May 27, 2026
b7ec85a
Add pypsa_de_sec_scaling results
danielelerede-oet May 27, 2026
2f82022
Add metadata snippet for pypsa-de-sec
danielelerede-oet May 27, 2026
237a674
Update run_commercial_solvers notebook
danielelerede-oet May 27, 2026
e4715ae
Add CPLEX results for pypsa-de-sec
danielelerede-oet May 28, 2026
65bc512
Add cplex run for pypsa-de-elec
danielelerede-oet May 28, 2026
57e0c6c
Remove results
danielelerede-oet May 31, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,8 @@ cython_debug/
/results/gcp-results/
/results/partial-results/

/solver-benchmark-private/

# NextJs
node_modules
.next
1,609 changes: 1,318 additions & 291 deletions benchmarks/pypsa/metadata.yaml

Large diffs are not rendered by default.

21 changes: 11 additions & 10 deletions benchmarks/spineopt/metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,14 @@ benchmarks:
Time horizon: Multi-stage (12 representative days)
MILP features: None
Sizes:
- Name: 30-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/spineopt-eu-pathway-planning-30-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 30 nodes
Realistic: true
Realistic motivation: Highly detailed sector, spatial, and temporal resolution over the considered three milestone years to allow the benchmark to be defined as Realistic.
Num. constraints: 18422757
Num. variables: 13134385
Num. non-zeros: 41956094
- Name: 30-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/spineopt-eu-pathway-planning-30-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 30 nodes
Realistic: true
Realistic motivation: Highly detailed sector, spatial, and temporal resolution over the considered three milestone years to allow the benchmark to be defined as Realistic.
Num. constraints: 18422757
Num. variables: 13134385
Num. nonzeros: 41956094
Num. non-zeros: 41956094
2 changes: 1 addition & 1 deletion infrastructure/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ variable "enable_gcs_upload" {
variable "gcs_bucket_name" {
description = "Name of the GCS bucket to upload benchmark results"
type = string
default = "solver-benchmarks"
default = "solver-benchmarks-testing"
}

variable "auto_destroy_vm" {
Expand Down
74 changes: 66 additions & 8 deletions infrastructure/startup-script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ fi
# Update and install packages
echo "Updating packages..."
apt-get -qq update
apt-get -qq install -y tmux git time curl jq build-essential cmake htop
apt-get -qq install -y tmux git time curl jq build-essential cmake htop libnuma1

# Install BLAS dependency
echo "Installing BLAS..."
Expand All @@ -43,9 +43,65 @@ chmod a+x /usr/local/bin/yq
mkdir -p /opt/gurobi
gsutil cp gs://solver-benchmarks-restricted/gurobi-benchmark-40-session.lic /opt/gurobi/gurobi.lic

# Download MOSEK license
echo "Downloading MOSEK license..."
mkdir -p /opt/mosek
gsutil cp gs://solver-benchmarks-restricted/mosek_evaluation_unrestricted.lic /opt/mosek/mosek.lic
chmod 644 /opt/mosek/mosek.lic

# Download Knitro license
echo "Downloading Knitro license..."
mkdir -p /opt/knitro
gsutil cp gs://solver-benchmarks-testing/knitro-license.txt /opt/knitro/knitro-license.txt

# Download Xpress license
echo "Downloading Xpress license..."
mkdir -p /opt/xpress
gsutil cp gs://solver-benchmarks-testing/license.xpr /opt/xpress/license.xpr

# Download and install CPLEX
# The CPLEX installer is Java/InstallAnywhere-based and requires X11 libs even in silent mode
echo "Installing dependencies for CPLEX installer..."
apt-get -qq install -y libx11-6 libxext6 libxrender1 libxtst6 libxi6 libfreetype6 libfontconfig1 default-jre-headless

echo "Downloading CPLEX installer..."
gsutil cp gs://solver-benchmarks-testing/cplex_studio2212.linux_x86_64.bin /tmp/cplex_studio2212.linux_x86_64.bin
chmod +x /tmp/cplex_studio2212.linux_x86_64.bin

echo "Installing CPLEX..."
cat > /tmp/cplex_response.properties << 'EOF'
INSTALLER_UI=silent
LICENSE_ACCEPTED=true
USER_INSTALL_DIR=/opt/ibm/ILOG/CPLEX_Studio2212
INSTALLER_LOCALE=en
USER_INPUT_SEGMENT_FALSE=1
EOF
/tmp/cplex_studio2212.linux_x86_64.bin -f /tmp/cplex_response.properties 2>&1
CPLEX_INSTALL_EXIT=$?
rm /tmp/cplex_studio2212.linux_x86_64.bin /tmp/cplex_response.properties

echo "--- CPLEX installer log ---"
cat /tmp/cplex_install.log 2>/dev/null || echo "No installer log found at /tmp/cplex_install.log"
# Also check the default InstallAnywhere log location
find /tmp -maxdepth 1 -name "*.log" -newer /tmp/cplex_response.properties 2>/dev/null -exec echo "--- {} ---" \; -exec cat {} \;
echo "--- End CPLEX installer log ---"

if [ $CPLEX_INSTALL_EXIT -ne 0 ]; then
echo "ERROR: CPLEX installer exited with code $CPLEX_INSTALL_EXIT"
fi

echo "Verifying CPLEX installation..."
if [ -f /opt/ibm/ILOG/CPLEX_Studio2212/cplex/bin/x86-64_linux/cplex ]; then
/opt/ibm/ILOG/CPLEX_Studio2212/cplex/bin/x86-64_linux/cplex -c "quit"
echo "CPLEX installation completed successfully"
else
echo "ERROR: CPLEX binary not found - installation failed"
ls -la /opt/ibm/ILOG/CPLEX_Studio2212/ 2>/dev/null || echo "CPLEX install directory does not exist"
fi

# Clone the repository
echo "Cloning repository..."
git clone --depth=1 -b main https://github.com/open-energy-transition/solver-benchmark.git
git clone --depth=1 -b commercial-solvers-run https://github.com/open-energy-transition/solver-benchmark.git

# Install a global highs binary for reference runs
echo "Installing reference Highs..."
Expand Down Expand Up @@ -175,6 +231,13 @@ else
echo "No solver field in benchmark YAML, using default solver list for year"
fi

# Set environment variables for commercial solvers
export ARTELYS_LICENSE=/opt/knitro/knitro-license.txt
export XPRESS=/opt/xpress/license.xpr
export CPLEX_STUDIO_DIR2212=/opt/ibm/ILOG/CPLEX_Studio2212
export LD_LIBRARY_PATH=/root/miniconda3/envs/benchmark-2025/lib/python3.12/site-packages/knitro/lib:/opt/ibm/ILOG/CPLEX_Studio2212/cplex/bin/x86-64_linux${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
export MOSEKLM_LICENSE_FILE=/opt/mosek/mosek.lic

# Run the benchmark_all.sh script with our years and the run_id
echo "Starting benchmarks for years: ${BENCHMARK_YEARS_STR} with run_id: ${RUN_ID}"
source ~/miniconda3/bin/activate
Expand Down Expand Up @@ -264,12 +327,7 @@ if [ "${ENABLE_GCS_UPLOAD}" == "true" ]; then
echo "Uploading ${compressed_file} to GCS bucket..."

# Check if file contains "gurobi" in the name
if [[ "${filename}" == *"gurobi"* ]]; then
echo "File contains 'gurobi' in name, storing in restricted folder..."
gsutil cp "${compressed_file}" "gs://${GCS_BUCKET_NAME}-restricted/logs/${RUN_ID}/${filename}.gz"
else
gsutil cp "${compressed_file}" "gs://${GCS_BUCKET_NAME}/logs/${RUN_ID}/${filename}.gz"
fi
gsutil cp "${compressed_file}" "gs://${GCS_BUCKET_NAME}/logs/${RUN_ID}/${filename}.gz"

if [ $? -eq 0 ]; then
echo "Successfully uploaded ${filename}.gz"
Expand Down
146 changes: 146 additions & 0 deletions notebooks/metadata-pypsa-de-sec.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
benchmarks:
pypsa-de-sec:
Short description: Sector-coupled PyPSA-Eur runs for Germany without transmission
expansion.
Modelling framework: PyPSA
Model name: PyPSA-Eur
Version:
Contributor(s)/Source: Daniele Lerede, Open Energy Transition; Fabrizio Finozzi,
Open Energy Transition
License: CC BY 4.0
Problem class: LP
Application: Infrastructure & Capacity Expansion
Sectoral focus: Sector-coupled
Sectors: Electric, Heating, Transport, Industry, Hydrogen, Biomass
Time horizon: Single period (2050)
MILP features: None
Sizes:
- Name: 10-168h
Size: M
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-10-168h.mps.gz
Temporal resolution: 168 hours
Spatial resolution: 10 nodes
Realistic: false
Num. constraints: 142147
Num. variables: 67416
Num. nonzeros: 332009
- Name: 20-12h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-20-12h.mps.gz
Temporal resolution: 12 hours
Spatial resolution: 20 nodes
Realistic: false
Num. constraints: 3797984
Num. variables: 1791010
Num. nonzeros: 8932707
- Name: 50-168h
Size: M
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-50-168h.mps.gz
Temporal resolution: 168 hours
Spatial resolution: 50 nodes
Realistic: false
Num. constraints: 677039
Num. variables: 321282
Num. nonzeros: 1603304
- Name: 2-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-2-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 2 nodes
Realistic: false
Num. constraints: 4678043
Num. variables: 2216368
Num. nonzeros: 10513074
- Name: 4-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-4-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 4 nodes
Realistic: false
Num. constraints: 9636397
Num. variables: 4564134
Num. nonzeros: 21900007
- Name: 6-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-6-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 6 nodes
Realistic: false
Num. constraints: 14568486
Num. variables: 6903154
Num. nonzeros: 33460003
- Name: 8-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-8-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 8 nodes
Realistic: false
Num. constraints: 19123880
Num. variables: 9058202
Num. nonzeros: 44092966
- Name: 10-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-10-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 10 nodes
Realistic: true
Realistic motivation: Sufficient spatial and temporal resolution over the considered
time horizon to allow the benchmark to be defined as Realistic.
Num. constraints: 23328888
Num. variables: 10994701
Num. nonzeros: 54427819
- Name: 12-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-12-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 12 nodes
Realistic: true
Realistic motivation: Sufficient spatial and temporal resolution over the considered
time horizon to allow the benchmark to be defined as Realistic.
Num. constraints: 28234681
Num. variables: 13359680
Num. nonzeros: 65628075
- Name: 14-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-14-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 14 nodes
Realistic: true
Realistic motivation: Sufficient spatial and temporal resolution over the considered
time horizon to allow the benchmark to be defined as Realistic.
Num. constraints: 33087928
Num. variables: 15663702
Num. nonzeros: 77091272
- Name: 16-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-16-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 16 nodes
Realistic: true
Realistic motivation: Sufficient spatial and temporal resolution over the considered
time horizon to allow the benchmark to be defined as Realistic.
Num. constraints: 37529441
Num. variables: 17766232
Num. nonzeros: 87486821
- Name: 18-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-18-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 18 nodes
Realistic: true
Realistic motivation: Sufficient spatial and temporal resolution over the considered
time horizon to allow the benchmark to be defined as Realistic.
Num. constraints: 42172440
Num. variables: 19956324
Num. nonzeros: 98370872
- Name: 20-1h
Size: L
URL: https://storage.googleapis.com/solver-benchmarks/instances/pypsa-de-sec-20-1h.mps.gz
Temporal resolution: 1 hour
Spatial resolution: 20 nodes
Realistic: true
Realistic motivation: Sufficient spatial and temporal resolution over the considered
time horizon to allow the benchmark to be defined as Realistic.
Num. constraints: 45553984
Num. variables: 21472540
Num. nonzeros: 106717276
Loading