Skip to main content

Python API for accessing demand-side grid model (dsgrid) datasets

Project description

dsgrid

Documentation codecov

Python API for contributing to and accessing demand-side grid model (dsgrid) projects and datasets.

⚠️ dsgrid is under active development and does not yet have a formal package release. Details listed here are subject to change. Please reach out to the dsgrid coordination team with any questions or other feedback. ⚠️

Install | Usage | Uninstall

Install

Virtual environment | Dependencies | from PIPY/pip | from pip+git | from cloned repository

Virtual environment

Create a virtual environment in which to install dsgrid. Anaconda or miniconda is recommended.

conda create -n dsgrid python=3.11
conda activate dsgrid

Dependencies

dsgrid uses Apache Spark to manage big data. There are no separate installation steps for Apache Spark beyond installing the dsgrid package and installing:

pip install "dsgrid-toolkit[spark]"

Otherwise installing the pyspark Python dependency handles it.

However, you should be aware that Apache Spark's Microsoft Windows support is poor and essentially limited to local mode. That is, if you use dsgrid on a Windows machine you should not attempt to install a full version of Spark nor expect to run on a Spark cluster. As such, we recommend limiting dsgrid use on Windows to browsing the registry, registering and submitting small- to medium-sized datasets, or development work with small test projects. Full dsgrid functionality with large projects requires additional computational resources, e.g., high performance or cloud computing, typically on a Linux operating system.

Additional Notes

  • If pyspark complains about not finding Python, you may need to locate your python executable file (python.exe on Windows), copy it, and rename the copy to python3 (python3.exe on Windows)

Spark requires Java 8 or later with the JAVA_HOME environment variable set to the Java installation directory.

On Linux you can install OpenJDK with conda:

conda install openjdk

Windows install instructions are below.

Windows

To install Apache Spark on Windows, follow these instructions.

From PIPY/pip

pip install dsgrid-toolkit

or

pip install "dsgrid-toolkit[spark]"

From pip+git

With ssh keys:

pip install git+ssh://git@github.com/dsgrid/dsgrid.git@main

# or

pip install git+ssh://git@github.com/dsgrid/dsgrid.git@develop

From http:

pip install git+https://github.com/dsgrid/dsgrid.git@main

# or

pip install git+https://github.com/dsgrid/dsgrid.git@develop

From Cloned Repository

First, clone the repository and change into the dsgrid directory. For example:

cd ~                                       # or other directory where you put repositories
git clone git@github.com:dsgrid/dsgrid.git # or the http address
cd dsgrid

Then install the pacakge using the pip -e flag to directly use the files in the cloned repository.

Users:

pip install -e .

Developers:

pip install -e '.[dev,spark]'

Usage

dsgrid is primarily a command-line interface (CLI) tool. To see the available commands:

dsgrid --help

Uninstall

pip uninstall dsgrid

If you are using a conda environment

conda deactivate

Software Record

dsgrid is developed under NREL Software Record SWR-21-52, "demand-side grid model".

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dsgrid_toolkit-0.3.1.tar.gz (263.6 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

dsgrid_toolkit-0.3.1-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.6 MB view details)

Uploaded PyPymanylinux: glibc 2.17+ x86-64

dsgrid_toolkit-0.3.1-cp314-cp314-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.14Windows x86-64

dsgrid_toolkit-0.3.1-cp313-cp313-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.13Windows x86-64

dsgrid_toolkit-0.3.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

dsgrid_toolkit-0.3.1-cp313-cp313-macosx_11_0_arm64.whl (2.4 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

dsgrid_toolkit-0.3.1-cp313-cp313-macosx_10_12_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.13macOS 10.12+ x86-64

dsgrid_toolkit-0.3.1-cp312-cp312-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.12Windows x86-64

dsgrid_toolkit-0.3.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

dsgrid_toolkit-0.3.1-cp312-cp312-macosx_11_0_arm64.whl (2.4 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

dsgrid_toolkit-0.3.1-cp312-cp312-macosx_10_12_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.12macOS 10.12+ x86-64

dsgrid_toolkit-0.3.1-cp311-cp311-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.11Windows x86-64

dsgrid_toolkit-0.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

dsgrid_toolkit-0.3.1-cp311-cp311-macosx_11_0_arm64.whl (2.4 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

dsgrid_toolkit-0.3.1-cp311-cp311-macosx_10_12_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.11macOS 10.12+ x86-64

File details

Details for the file dsgrid_toolkit-0.3.1.tar.gz.

File metadata

  • Download URL: dsgrid_toolkit-0.3.1.tar.gz
  • Upload date:
  • Size: 263.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for dsgrid_toolkit-0.3.1.tar.gz
Algorithm Hash digest
SHA256 b77c1342fee0fb4098eaa5b88064cfe1cffb51bfa582cf4098c88a2e5b03f732
MD5 c41d9b9fb0fd26a4a72fb11103721529
BLAKE2b-256 81be0b31ea3ed81a4abe95d90e095defd604aeaf007c871c8277207e4e7b6fed

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1.tar.gz:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 860f1dd1c6b2d4ece75756e5d286cea7a6f9416352257cc2bd42bb58834a6658
MD5 fc091a568358b957ec30754c321823b3
BLAKE2b-256 68cdb751ec35e85df1a0937446d8599194c72a52c00060755f6e5e3b66bacfa6

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp314-cp314-win_amd64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 4d8e2091771a0f1eecd5fb007629d6c8937976e0d7c5ce6dedb5a6a3a8060233
MD5 73a0932ec76e2e7d6ac2abd2bca7c133
BLAKE2b-256 0a6eae65bb35f0b74a4995536265a2f166f32a7374cf21a3cb157a212a803e72

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp314-cp314-win_amd64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 c23713d03ecb44a721bcfa138e806db49de5923651a7a14d44b5188e5dcbe87b
MD5 e8bd663b320a92b10f0b0a613a3af014
BLAKE2b-256 92f6b9df923084c78c82abc3fb9123c705568b417662984f78b6c4e528054ade

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp313-cp313-win_amd64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 43859d88605f80b99689290935984fa6882c610bdf5608c6f69e0bcdd8da022c
MD5 10387b28db7a5295e5aac1919d2790e2
BLAKE2b-256 0fcc625fa9dae3c949408c07e0c4db41d0a456e0f6cefececb2c0b2dec16e19a

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 6cbda29dd2a3134c92584ea99a4bc31d9844e5c2b9e24db746ee9c1c5bded5d5
MD5 6daa256a2e1eb5e5ff19efef776fcf79
BLAKE2b-256 9f2111e5c6742a83c89fb1ef35aab1d94e070ef2d06d69b29794570592463f08

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp313-cp313-macosx_11_0_arm64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp313-cp313-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp313-cp313-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 7ac3b87f79e521b8a9f39a39af15f185ee309b981244b88cc71d0368a5dbd0ce
MD5 a80d1fe3ca0cee3b69b64b1a4ef0b595
BLAKE2b-256 f6805a191a4d292813a506c9b1608c3d824ed6a9e52533af00d067bb762cb01a

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp313-cp313-macosx_10_12_x86_64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 6a78548f928ad899af3d5e7ff206c52e7561c833d227d82125e8b831b78dbda7
MD5 58de0494fc1846b5b921293cc30395a9
BLAKE2b-256 a2f3cc214a7c876049c7246794a972b89e64373ac453758991e7674f8d1646e1

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp312-cp312-win_amd64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 95bd105f8e34103ddc809310ba86a0519ecdaefa4b82a9348006e0e144b79717
MD5 b806405603c61a44747895dba67c659f
BLAKE2b-256 bcc981896a5e30ef2b06fb6fc92aba2848fa48e0faf0d4cba67920ef4ab2fbe5

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 fef35b1b6cd4f5695f43378e63e14de2d1a59ffc95e2123c61836c5dd3bd5282
MD5 e03cf8f44cee37ad9ebe8c3aaac45334
BLAKE2b-256 0a05b818324145dcdcaf04b168743b8f150fb812fea75f53d559ea5407448718

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp312-cp312-macosx_11_0_arm64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp312-cp312-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp312-cp312-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 aef805a1ab3c7d8a6b0c36eef24620cb94e290c39baa9e5653db310f32837fe8
MD5 6ec08d08a9f96bdf68064e66b3354755
BLAKE2b-256 9c6cbca2bacfedcaaae993162851ea8c8bd546900293f467275762d2f9834c0c

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp312-cp312-macosx_10_12_x86_64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 dea3017a2b2c293ea4fad9f8f190bb4fa1d4af2e9fcb510e04743c355a08397d
MD5 981bd5ab3c8e12ea37b42f759c1cf803
BLAKE2b-256 e6704e80e89488d69f9d9c9cc47c1ea4df7fa37fc2a264f3032a79f7ebb6b017

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp311-cp311-win_amd64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 32fe66ac1a9c19c1ed6d62aff54e352b5b1dde068ec09586d6396148492658d4
MD5 137374dba8bdb08c489602b6cd0a0bf7
BLAKE2b-256 e54d1447db9ca5ac6f414fa8f1bd13cc8a0814e0df386f202f9121abc716f24f

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b208f488690148d906a257585c1404cea7fcf8b0b7844c4c3b3f5fc6e873c71c
MD5 1c742fb95a50655ab997cc5c733426c9
BLAKE2b-256 73b11bb4eafc43b2aefc968169306a849ba26f7327a737fcba09f036b89bee37

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp311-cp311-macosx_11_0_arm64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dsgrid_toolkit-0.3.1-cp311-cp311-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for dsgrid_toolkit-0.3.1-cp311-cp311-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 e42b7517d1d8518bf2a46fd14e33161f815033cd24b8df566910d0e601b75bd9
MD5 01ea4f99ffdb408946c5e46ed8137b2c
BLAKE2b-256 2928f949c0db843a47817c878d493c29f1d52ba8851cec3f8283642e53819130

See more details on using hashes here.

Provenance

The following attestation bundles were made for dsgrid_toolkit-0.3.1-cp311-cp311-macosx_10_12_x86_64.whl:

Publisher: publish_to_pypi.yml on dsgrid/dsgrid

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page