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 3.1.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 3.1.0
File Size Uploaded Provenance Actions
zen_creator-3.1.0.tar.gz 66.7 kB With provenance Details for zen_creator-3.1.0.tar.gz

Built distribution (wheel)

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

Total release size: 160.0 kB

Release files / zen_creator-3.1.0.tar.gz

Download URL zen_creator-3.1.0.tar.gz
Size 66.7 kB
Tags Source
SHA-256 checksum
How to use checksums
1fffedf1fd54c104bf3a78fefd0aa3ecdab2bbcfdba410c932ae64b912a3cff1
BLAKE2b-256 checksum
How to use checksums
f5ce45cdc79ffccf26046f6fbe284b5ea53b4965303cf7d3cb2034e44d7d1e48
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 23, 2026.

Transparency log

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

Download URL zen_creator-3.1.0-py3-none-any.whl
Size 93.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c473b191bf60348816fa90dc594da76bd3f6142da77b04592965d40dd8cf1018
BLAKE2b-256 checksum
How to use checksums
1cf20bf6e44d982a689583ee51cb6ad8e0171e76ce0573405b5336805f93cdc4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 23, 2026.

Transparency log

Security for zen-creator 3.1.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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for zen_creator-3.1.0.tar.gz

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 Nov 23, 2026.

Transparency log

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.

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