Skip to main content

PIHM-utils

Library for reading MM-PIHM input and output files.

Installation

To install:

pip install PIHM-utils

Usage

The read_grid function reads domain setup from MM-PIHM .mesh and .riv input files:

from pihm import read_grid

element_df, river_df, node_df = read_grid(pihm_dir, simulation)

pihm_dir is the path to the MM-PIHM directory, which should contain input and output directories, and simulation is the name of the simulation. element_df, river_df, and node_df are pandas.DataFrames that contain grid elements, river segments, and grid nodes information.

The read_output function reads MM-PIHM simulation output files:

from pihm import read_output

desc, df = read_output(pihm_dir, simulation, outputdir, var)

desc is strings containing description and unit of the specific output variable, df is a pandas.DataFrame containing the simulation output. outputdir is the name of the output directory, and var is name of output variable. For a complete list of available output variables, please refer to the MM-PIHM User's Guide.

Examples

Please check out the Python notebook for a visualization example.

Metadata

Release files for PIHM-utils 2.0.3

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

Source distribution (sdist)

Source distribution for PIHM-utils 2.0.3
File Size Uploaded Provenance Actions
pihm_utils-2.0.3.tar.gz 5.3 kB Without provenance Details for pihm_utils-2.0.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for PIHM-utils 2.0.3
File Interpreter ABI Platform Actions
PIHM_utils-2.0.3-py3-none-any.whl Python 3 none any Details for PIHM_utils-2.0.3-py3-none-any.whl

Total release size: 11.0 kB

Release files / pihm_utils-2.0.3.tar.gz

Download URL pihm_utils-2.0.3.tar.gz
Size 5.3 kB
Tags Source
SHA-256 checksum
How to use checksums
3f1277cc1d1af506831cd0f41f4ca6d4c6a705fde2527ae62176723458dc6cc1
BLAKE2b-256 checksum
How to use checksums
e225e755cc40b97d8fc07960b7f37e834f666b147cc0dba129446a92473cb8ff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.4

Release files / PIHM_utils-2.0.3-py3-none-any.whl

Download URL PIHM_utils-2.0.3-py3-none-any.whl
Size 5.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b713615ee0bf4defffcc174878d158900d3aadeb231d573d65ff399f2047f22e
BLAKE2b-256 checksum
How to use checksums
2310abe1041e99d0e4d41f147f20623a875fd26dbd210a0fe2eddbdd69eae8d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.4

Security for PIHM-utils 2.0.3

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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