xyzpy is python library for efficiently
generating, manipulating and plotting data with a lot of dimensions, of the
type that often occurs in numerical simulations. It stands wholly atop the
labelled N-dimensional array library xarray. The
project's documentation is hosted on readthedocs.
The aim is to take the pain and errors out of generating and exploring data with a high number of possible parameters. This means:
- you don't have to write super nested for loops
- you don't have to remember which arrays/dimensions belong to which variables/parameters
- you don't have to parallelize over or distribute runs yourself
- you don't have to worry about loading, saving and merging disjoint data
- you don't have to guess when a set of runs is going to finish
- you don't have to write batch submission scripts or leave the notebook to use SLURM, PBS or SGE
- you don't have to lose progress if your run is interrupted
- you don't have to fiddle with
CUDA_VISIBLE_DEVICESortasksetto assign GPU devices or CPU cores to different runs
To this data generation functionality, xyzpy adds a simple plotting
interface accessed via ds.xyz.plot()
that automatically maps dataset dimensions to visual elements including color,
marker, marker size, line style, line width, subplot rows and columns, and text
annotations. It also adds various other utilities for timing and tracking
memory usage, and for visualizing matrices and high dimensional tensors.
Quick-start
Here's a simple example of generating and plotting a 5D function that uses the
high level driver xyz.cultivate()
to handle a full cycle of data generation:
import xyzpy as xyz
def foo(x, delta, p, amp=1.0, C=0.0):
return {"fx": amp * (x - delta) ** p + C}
# cultivate!
# 0. annotate the function
# 1. write missing parameters combinations to disk ('sow')
# 2. compute those, with results stored persistenly to disk ('grow')
# 3. load results into a xarray.Dataset, merging with existing ('reap')
ds = xyz.cultivate(
foo,
# this specifies we'll return a dict of named data_vars ourselves
var_names=None,
# this specifies we'll harvest results to the file "foo.h5"
data_name="foo.h5",
# compute the outer product of these parameter combinations
combos=dict(
x=[-2 + i * 0.25 for i in range(17)],
p=[1, 2, 3],
delta=[0.0, 0.2, 0.4, 0.6, 0.8, 1.0],
C=[-2.0, 1.0, 4.0],
amp=[-1.0, 1.0],
),
)
# plot!
# - we can map pretty much any coordinate to any visual property
# - we can map to a palette ("hue") as well as position within that ("color")
fig, axs = ds.xyz.plot(
x="x",
y="fx",
yscale="symlog",
ylabel="$f(x)$",
hue="C",
markeredgecolor="C",
color="delta",
marker="delta",
col="p",
row="amp",
markersize=3,
)
# clean up!
# - if we didn't delete the dataset, next run will only compute missing data
!rm foo.h5
Please see the docs for more information.
Metadata
Release files for xyzpy 1.3.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| xyzpy-1.3.5.tar.gz | 3.4 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| xyzpy-1.3.5-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 3.5 MB
Release files / xyzpy-1.3.5.tar.gz
| Download URL | xyzpy-1.3.5.tar.gz |
|---|---|
| Size | 3.4 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4ba0aa08af546a8cdb66cc5bb96dea010ca0e2d36b5d8338e30d6e4f44201b89
|
|
BLAKE2b-256 checksum How to use checksums |
d66eb34270679f5d05f88554cae43903f78e197f7636b61214439004b9b24e97
|
| 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 Sep 1, 2026.
Transparency logRelease files / xyzpy-1.3.5-py3-none-any.whl
| Download URL | xyzpy-1.3.5-py3-none-any.whl |
|---|---|
| Size | 129.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
20b29f532bebb1b7ac7a49a81848b5a568ddac10acc201e8d83c1091e7d5edd2
|
|
BLAKE2b-256 checksum How to use checksums |
1cf2d77ded6e166756bbc9423aec35b75efec9405ac7315227ad194475ebf79f
|
| 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 Sep 1, 2026.
Transparency log