Skip to main content

cobre

Python bindings for the Cobre power systems solver.

Cobre is a high-performance SDDP (Stochastic Dual Dynamic Programming) solver for hydrothermal dispatch, written in Rust. This package provides Python access to case loading, validation, training, simulation, and result inspection.

Installation

pip install cobre-python

Pre-built wheels are available for:

  • Linux x86_64 and aarch64 (manylinux_2_34), musl x86_64
  • macOS Apple Silicon (aarch64) and Intel (x86_64)
  • Windows x86_64
  • Python 3.12+

Quick Start

import cobre

# Load and validate a case
system = cobre.io.load_case("path/to/case")
print(f"System: {system.n_buses} buses, {system.n_hydros} hydros, {system.n_thermals} thermals")

# Run training + simulation
result = cobre.run.run("path/to/case", output_dir="output/")
print(f"Converged: {result['converged']}, LB: {result['lower_bound']:.2f}")

convergence = cobre.results.load_convergence("output/")
print(f"Iterations: {len(convergence)}")

simulation = cobre.results.load_simulation("output/")
print(f"Cost records: {len(simulation['costs'])}")

policy = cobre.results.load_policy("output/")
print(f"Iterations completed: {policy['metadata']['completed_iterations']}")

Modules

  • cobre.io — Load and validate case directories
  • cobre.model — Data model classes (System, Bus, Line, Thermal, Hydro, etc.)
  • cobre.run — Execute SDDP training and simulation
  • cobre.results — Load and inspect output artifacts, including convergence history, Parquet simulation outputs, and FlatBuffers policy (FCF) checkpoints

Requirements

  • Python >= 3.12
  • No runtime dependencies (the Rust solver is statically linked)

License

Apache-2.0 — see LICENSE.

Links

Metadata

Release files for cobre-python 0.14.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for cobre-python 0.14.1
File
cobre_python-0.14.1-cp312-abi3-win_amd64.whl CPython 3.12 abi3 Windows x86-64 Details
cobre_python-0.14.1-cp312-abi3-musllinux_1_2_x86_64.whl CPython 3.12 abi3 Linux musl 1.2+ x86-64 Details
cobre_python-0.14.1-cp312-abi3-manylinux_2_34_x86_64.whl CPython 3.12 abi3 Linux glibc 2.34+ x86-64 Details
cobre_python-0.14.1-cp312-abi3-manylinux_2_28_aarch64.whl CPython 3.12 abi3 Linux glibc 2.28+ ARM64 Details
cobre_python-0.14.1-cp312-abi3-macosx_11_0_arm64.whl CPython 3.12 abi3 macOS 11.0+ ARM64 Details
cobre_python-0.14.1-cp312-abi3-macosx_10_12_x86_64.whl CPython 3.12 abi3 macOS 10.12+ x86-64 Details

Total release size: 58.0 MB

Release files / cobre_python-0.14.1-cp312-abi3-win_amd64.whl

Download URL cobre_python-0.14.1-cp312-abi3-win_amd64.whl
Size 7.7 MB
Tags CPython 3.12 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
794896e3c6786218acc1f9d8d6c94a604e6320c1f977a4d730ba17a9772252c7
BLAKE2b-256 checksum
How to use checksums
28dcc6ef3c9038c791078c6dc4c254c3e1bda6c611a527339f78c6756a8a4514
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 18, 2026.

Transparency log

Release files / cobre_python-0.14.1-cp312-abi3-musllinux_1_2_x86_64.whl

Download URL cobre_python-0.14.1-cp312-abi3-musllinux_1_2_x86_64.whl
Size 15.7 MB
Tags CPython 3.12 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
34357f6a07e7e910b7ed30bfd53fcf146ab22498d6d77cc07f66d6d0eecedb12
BLAKE2b-256 checksum
How to use checksums
8ae30acc9be9e6c6aedbb990ac4a83e1989e58e8749e07648232de5ada7655ac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 18, 2026.

Transparency log

Release files / cobre_python-0.14.1-cp312-abi3-manylinux_2_34_x86_64.whl

Download URL cobre_python-0.14.1-cp312-abi3-manylinux_2_34_x86_64.whl
Size 9.4 MB
Tags CPython 3.12 Linux glibc 2.34+ x86-64 abi3
SHA-256 checksum
How to use checksums
4ee3931e6b4e612a1c2b90f627d65c1cb1e2d36b578bbf79683a5d9332908a34
BLAKE2b-256 checksum
How to use checksums
a085a5f5584fd57cf9d4696c7dfdd07aaae765d55fcb280f8bafe24cb251826a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 18, 2026.

Transparency log

Release files / cobre_python-0.14.1-cp312-abi3-manylinux_2_28_aarch64.whl

Download URL cobre_python-0.14.1-cp312-abi3-manylinux_2_28_aarch64.whl
Size 8.7 MB
Tags CPython 3.12 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
f90a95c40d4ac0cca505a04a35bf8cf3bfbcad3872e64969ed01ffcfa602af09
BLAKE2b-256 checksum
How to use checksums
3248242470e34a5332e182bac922b2a9f536c3bc5914a36dcfbd28fb254b83f2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 18, 2026.

Transparency log

Release files / cobre_python-0.14.1-cp312-abi3-macosx_11_0_arm64.whl

Download URL cobre_python-0.14.1-cp312-abi3-macosx_11_0_arm64.whl
Size 7.9 MB
Tags CPython 3.12 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
9398028405e2bd628e84d2514c1c45d43c4978c9b81d469f33f585f03b4da320
BLAKE2b-256 checksum
How to use checksums
3cd6e8cd91cf56f25e5e9b40208ecd2e33b27f5a0643aa753397682e6a6b2a7b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 18, 2026.

Transparency log

Release files / cobre_python-0.14.1-cp312-abi3-macosx_10_12_x86_64.whl

Download URL cobre_python-0.14.1-cp312-abi3-macosx_10_12_x86_64.whl
Size 8.6 MB
Tags CPython 3.12 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
39b8a4e86b01b1176769eba9d519f99ec56cddaf9b9f6949ee607ea9c854f3cc
BLAKE2b-256 checksum
How to use checksums
e2c8aa6046a6b11c5387b73e69832068aa25f2c391da1e6a96668ea84e4938e5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 18, 2026.

Transparency log

Release history Release notifications | RSS feed

0.16.0

6 release files

0.15.0

6 release files

0.14.3

6 release files

0.14.2

6 release files

This release

0.14.1 This release

6 release files

0.14.0

6 release files

0.13.0

6 release files

0.12.0

6 release files

0.11.1

6 release files

0.11.0

6 release files

0.10.0

6 release files

0.9.1

6 release files

0.9.0

6 release files

0.8.2

6 release files

0.8.1

6 release files

0.8.0

6 release files

0.7.0

6 release files

0.6.2

6 release files

0.6.1

6 release files

0.6.0

6 release files

0.5.1

6 release files

0.5.0

6 release files

0.4.4

6 release files

0.4.3

6 release files

0.4.2

6 release files

0.4.1

9 release files

0.4.0

9 release files

0.3.2

9 release files

0.3.1

9 release files

0.3.0

9 release files

0.2.2

9 release files

0.2.1

9 release files

0.2.0

9 release files

0.1.11

9 release files

0.1.10

9 release files

0.1.9

9 release files

0.1.8

9 release files

0.1.7

9 release files

0.1.6

9 release files

0.1.5

9 release files

0.1.4

9 release files

0.1.3

9 release files

0.1.2

9 release files

0.1.1

9 release files

0.1.0

9 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page