Skip to main content

ZEN-creator

Lightweight utilities for creating and managing ZEN energy-system models and associated datasets. Full developer and user documentation is available online.

Quick start

  • Create the conda environment included with the repository:
conda env create -f zen_creator_env.yml
conda activate zen-creator-env
  • Or install in editable mode with pip:
python -m pip install -e .

Basic usage

Programmatic usage is the recommended way to build and manipulate ZEN models. The central entry point is the Model class which can be constructed in several ways: directly, from a configuration file, or by loading an existing ZEN-garden input folder.

from pathlib import Path
from zen_creator.model import Model

# 1) Create a model from a configuration file
model = Model.from_config(Path("config.yaml"))
model.build()
model.validate()
model.write()

# 2) Load an existing ZEN-garden input folder and update
existing = Path("existing_model")
model2 = Model.from_existing(existing)
model2.name = "updated_model"
model2.build()
model2.write()

# 3) Create an empty model and add sectors/elements programmatically
m = Model()
m.add_sector_by_name("electricity")
m.add_element_by_name("electricity", generic="carrier")
m.build()

Settings, variants and scenarios

  • Projects define typed settings as SettingsCategory subclasses, set in the settings: block of the configuration file and available as model.settings.<category>.<field>.
  • A models file declares named variants of a dataset as sparse patches of the settings, read with ModelSet.
  • Scenarios for ZEN-garden's scenario analysis are attached to attributes via Attribute.set_data(scenarios=...) or added with model.scenarios.add() and model.scenarios.add_set(), and written to scenarios.yaml.

Useful properties

  • model.carriers, model.technologies: dictionaries of elements
  • model.output_path: path where the model will be written

Documentation

The full documentation (API reference, developer guide and examples) is hosted online: ZEN-creator documentation

Contributing

project Contribution Guide.

Metadata

Release files for zen-creator 2.0.0

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

Source distribution (sdist)

Source distribution for zen-creator 2.0.0
File Size Uploaded
zen_creator-2.0.0.tar.gz 61.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for zen-creator 2.0.0
File Interpreter ABI Platform
zen_creator-2.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 149.6 kB

Release files / zen_creator-2.0.0.tar.gz

Download URL zen_creator-2.0.0.tar.gz
Size 61.7 kB
Tags Source
SHA-256 checksum
How to use checksums
7fa817d013e28a933b294aef2890f2e56b535d2f42d7371a050fd547e8593b82
BLAKE2b-256 checksum
How to use checksums
32fec4372d0dce15794c233371f2ee32d8b2dffd616871aec9d63f7aad48113b
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 Oct 12, 2026.

Transparency log

Release files / zen_creator-2.0.0-py3-none-any.whl

Download URL zen_creator-2.0.0-py3-none-any.whl
Size 87.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
58e8dd991a0bc20f717361552de8c2a13f22dd44da8fb4c1fbc5f797cb62dd4f
BLAKE2b-256 checksum
How to use checksums
1338bf9e5f8d668f02f64bc921aa1072797daaf16aae0e966ea91828790d1678
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 Oct 12, 2026.

Transparency log

Release history Release notifications | RSS feed

2.1.0

2 release files

This release

2.0.0 This release

2 release files

1.5.0

2 release files

1.4.0

2 release files

1.3.1

2 release files

1.3.0

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 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