Skip to main content

graphed

Deferred awkward-array analysis with a plan you can save, ship, and debug — dask-awkward's shape, without the giant task graph.

You write ordinary awkward code. Nothing runs yet — graphed records it, and collapses the redundancy as you go, so the cut you wrote twice and the helper that multiplies by 1.0 are gone before they ever cost you anything. When you're ready, you hand the result to a runner. What you get for it:

  • The same analysis produces byte-identical results every run, on 1 worker or 100.
  • A failure on a remote worker comes back pointing at the line you wrote, not an opaque string from another process.
  • Only the columns your analysis touches are read off disk — a file with 400 branches costs you the six you used.
  • The recorded plan is a durable artifact: checkpoint it, resume it after a crash, or bundle it so a colleague reproduces your histograms exactly.

Install

pip install "graphed[awkward]"      # the HEP default: ragged arrays via awkward

Other extras, all opt-in:

pip install graphed                 # frontend + compiled core only (light)
pip install "graphed[numpy]"        # rectilinear numpy backend
pip install "graphed[parquet]"      # Parquet reading/writing (pyarrow)
pip install "graphed[dashboard]"    # live run dashboard
pip install "graphed[preserve]"     # preservation bundles (correctionlib/ONNX)
pip install "graphed[all]"          # everything except the heavy ML frameworks

Wheels ship for Linux, macOS, and Windows; installing from source needs a Rust toolchain (the optimizer is a compiled extension).

Your first analysis

import awkward as ak

import graphed
from graphed import Session
from graphed.awkward import AwkwardBackend, from_awkward, gak

events = ak.Array(
    [
        {"Jet": [{"pt": 40.0, "eta": 0.1}, {"pt": 12.0, "eta": 2.3}]},
        {"Jet": [{"pt": 55.0, "eta": -1.2}]},
        {"Jet": [{"pt": 8.0, "eta": 0.5}]},
    ]
)

session = Session(AwkwardBackend())
evts = from_awkward(session, "events", events)

good = evts.Jet[evts.Jet.pt > 30.0]  # records, doesn't run
leading_pt = gak.max(good.pt, axis=1)  # gak mirrors ak.* signatures

compiled = graphed.compile_ir(session, leading_pt)
(result,) = graphed.evaluate_ir(compiled, AwkwardBackend(), {"events": events})
print(ak.to_list(result))
# [40.0, 55.0, None]

gak is the function surface: it carries the ak.* signatures you already know (gak.num, gak.zip, gak.with_field, …), but each call records a step instead of computing one.

The one thing that's different

There is no .compute(). There are two ways to make the recording happen, and which one you want depends on where the work should run.

In this process, as above: graphed.compile_ir(session, output) reduces the recording, and graphed.evaluate_ir(...) evaluates it right here, on arrays you hand it. Good for a notebook and for small data.

Across partitions of a dataset, which is what you want for a real run: build a plan and hand it to a runner. graphed.aggregate_plan(out1, out2, reduce=..., combine=..., empty=...) compiles every output into one recording and produces one task per partition of the dataset you read from — so it needs a partitioned source such as from_parquet. For histograms, graphed_histogram.plan({"name": h}) builds the same thing for you. Then: SequentialRunner from graphed.core runs it in-process, and a graphed-executors runner runs it on a process pool, a dask cluster, or a parsl HTEX pool. Your first real analysis does exactly this, end to end.

The plan — not a pickle of your Python objects — is what travels, which is why it can be saved, resumed, and reproduced.

Which pieces do I need?

You want Install / import
Ragged HEP analysis (the default) graphed[awkward] → graphed.awkward, gak
Read/write Parquet, skims add graphed[parquet] → graphed.awkward.from_parquet, to_parquet
Run on a pool or cluster graphed-executors
Deferred hist-style histograms graphed-histogram
Watch a run live add graphed[dashboard] → graphed.debug
Hand your analysis to a colleague, exactly add graphed[preserve] → graphed.preserve

Everything under one import path, and what each part does for you:

Import path What it does for you Extra
graphed Session, Array, vary (systematic variations), compile/evaluate (base)
graphed.core the compiled optimizer, the plan types runners consume, and SequentialRunner (base)
graphed.awkward ragged backend: gak functions, corrections/ONNX calls [awkward] (+ [parquet] for I/O)
graphed.numpy deferred numpy for rectilinear data [numpy]
graphed.debug errors mapped back to your source line; the live dashboard (base); [dashboard] for the live view
graphed.checkpoint cache results by content; restart a crashed run where it left off (base)
graphed.preserve a self-contained bundle that reproduces your histograms elsewhere (base); [preserve] for correctionlib/ONNX payloads

Next

  • Your first real analysis — a parquet dataset, a jet cut, a systematic variation and a histogram, end to end.
  • How the frontend works — what gets recorded, how duplicate expressions collapse as you build, and the full graphed.vary grammar for systematics.
  • How the awkward backend works — column reading, corrections, ML models, and writing varied skims.
  • API reference.
  • Build the docs locally: pip install -e ".[docs]" && sphinx-build -W -b html docs docs/_build/html

To hack on graphed itself, see CONTRIBUTING.md.

Release files for graphed 0.0.4

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

Source distribution (sdist)

Source distribution for graphed 0.0.4
File Size Uploaded
graphed-0.0.4.tar.gz 6.0 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for graphed 0.0.4
File
graphed-0.0.4-cp314-cp314t-win_amd64.whl CPython 3.14 CPython 3.14 free-threading Windows x86-64 Details
graphed-0.0.4-cp314-cp314t-musllinux_1_2_x86_64.whl CPython 3.14 CPython 3.14 free-threading Linux musl 1.2+ x86-64 Details
graphed-0.0.4-cp314-cp314t-musllinux_1_2_aarch64.whl CPython 3.14 CPython 3.14 free-threading Linux musl 1.2+ ARM64 Details
graphed-0.0.4-cp314-cp314t-manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ x86-64 Details
graphed-0.0.4-cp314-cp314t-manylinux_2_28_aarch64.whl CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ ARM64 Details
graphed-0.0.4-cp314-cp314t-macosx_11_0_arm64.whl CPython 3.14 CPython 3.14 free-threading macOS 11.0+ ARM64 Details
graphed-0.0.4-cp314-cp314t-macosx_10_15_x86_64.whl CPython 3.14 CPython 3.14 free-threading macOS 10.15+ x86-64 Details
graphed-0.0.4-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details
graphed-0.0.4-cp311-abi3-musllinux_1_2_x86_64.whl CPython 3.11 abi3 Linux musl 1.2+ x86-64 Details
graphed-0.0.4-cp311-abi3-musllinux_1_2_aarch64.whl CPython 3.11 abi3 Linux musl 1.2+ ARM64 Details
graphed-0.0.4-cp311-abi3-manylinux_2_28_x86_64.whl CPython 3.11 abi3 Linux glibc 2.28+ x86-64 Details
graphed-0.0.4-cp311-abi3-manylinux_2_28_aarch64.whl CPython 3.11 abi3 Linux glibc 2.28+ ARM64 Details
graphed-0.0.4-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details
graphed-0.0.4-cp311-abi3-macosx_10_12_x86_64.whl CPython 3.11 abi3 macOS 10.12+ x86-64 Details

Total release size: 83.1 MB

Release files / graphed-0.0.4.tar.gz

Download URL graphed-0.0.4.tar.gz
Size 6.0 MB
Tags Source
SHA-256 checksum
How to use checksums
0b665cb16ab97c4fa80b915db711aa20ad51b41217786bc53b5d3dd10b41c29f
BLAKE2b-256 checksum
How to use checksums
b272ffc6edd5357364ca1575ec581a5fd98dd51fe2c0ea0a489c10c67bff4fe5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp314-cp314t-win_amd64.whl

Download URL graphed-0.0.4-cp314-cp314t-win_amd64.whl
Size 5.4 MB
Tags CPython 3.14 CPython 3.14 free-threading Windows x86-64
SHA-256 checksum
How to use checksums
4cea202a0cb51c544ea0906889a01acc328824c70b55111ecefaf5ab61e88456
BLAKE2b-256 checksum
How to use checksums
3537835a4472f8840da4d4970aed6d00675e699a4b17c0aa7c18a4000675d4fa
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp314-cp314t-musllinux_1_2_x86_64.whl

Download URL graphed-0.0.4-cp314-cp314t-musllinux_1_2_x86_64.whl
Size 5.6 MB
Tags CPython 3.14 CPython 3.14 free-threading Linux musl 1.2+ x86-64
SHA-256 checksum
How to use checksums
5cb369810bf61a0bc70ff97ea1df9c05438960be6e0fdcf7dfa67a791e249876
BLAKE2b-256 checksum
How to use checksums
5341d4735588cb9844774337b6139f525f39ea3592aa6e019caa92495ff829c0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp314-cp314t-musllinux_1_2_aarch64.whl

Download URL graphed-0.0.4-cp314-cp314t-musllinux_1_2_aarch64.whl
Size 5.6 MB
Tags CPython 3.14 CPython 3.14 free-threading Linux musl 1.2+ ARM64
SHA-256 checksum
How to use checksums
08eb7cad9c81e3d9706f200ceb172c876097b5d5edb23b765d34d7ac68b198fa
BLAKE2b-256 checksum
How to use checksums
ce8eec203237fb5b4d0fc235b3474d4522a3023dc48ce6a565a3b2d4fc9bf819
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp314-cp314t-manylinux_2_28_x86_64.whl

Download URL graphed-0.0.4-cp314-cp314t-manylinux_2_28_x86_64.whl
Size 5.5 MB
Tags CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
845db6f5fa70625d03a49f68ae7a485bbe9402cdea0021f33e302341155c5294
BLAKE2b-256 checksum
How to use checksums
c6c713e6a211c4d0c29e1637ba51b7b018b454cdee6f0ec359848206ca7c8c38
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp314-cp314t-manylinux_2_28_aarch64.whl

Download URL graphed-0.0.4-cp314-cp314t-manylinux_2_28_aarch64.whl
Size 5.5 MB
Tags CPython 3.14 CPython 3.14 free-threading Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
4a436b56fedf1d0abb14d99fa6e7edcffe476287b82ce2349b15925d36a3cde9
BLAKE2b-256 checksum
How to use checksums
546101c39cc016f93dfb927c66f3062b8e1dd3cfd846113c23accdbadb4153c4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp314-cp314t-macosx_11_0_arm64.whl

Download URL graphed-0.0.4-cp314-cp314t-macosx_11_0_arm64.whl
Size 5.5 MB
Tags CPython 3.14 CPython 3.14 free-threading macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
8b067f524ce9bc41d6fc6ef4ac812acbf4fe219cc98e625c8da0dec4ad5552ff
BLAKE2b-256 checksum
How to use checksums
6f43a5062b203a96a8f97a2eaf6c296435cc1b0daef715b6f682f261a8c96940
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp314-cp314t-macosx_10_15_x86_64.whl

Download URL graphed-0.0.4-cp314-cp314t-macosx_10_15_x86_64.whl
Size 5.5 MB
Tags CPython 3.14 CPython 3.14 free-threading macOS 10.15+ x86-64
SHA-256 checksum
How to use checksums
57bc2edbdcb8d268983a56d4ebe06d4392ebc89afa196d49fd12c8ed0af43622
BLAKE2b-256 checksum
How to use checksums
916444bdecbd873dd257d47167613c4e6f72c9a9339ba6263d8499ddcba59dc9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp311-abi3-win_amd64.whl

Download URL graphed-0.0.4-cp311-abi3-win_amd64.whl
Size 5.4 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
9fa1f531d2c905e028398b86ec967a572476793d160984a2b227e6b367fb6b41
BLAKE2b-256 checksum
How to use checksums
d13e36652436d5a364de2d4e261ccc2ff19582414db0f734e1565f9633da58a2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp311-abi3-musllinux_1_2_x86_64.whl

Download URL graphed-0.0.4-cp311-abi3-musllinux_1_2_x86_64.whl
Size 5.6 MB
Tags CPython 3.11 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
6367b0cfbaee8de8f785a8ff137d8f8761ab7fb271e02e97bca6cb4779cff76b
BLAKE2b-256 checksum
How to use checksums
fdeac2b88155e53749193fe1bf0bd130b259ef48f8bc0d27a17379f66f772a5a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp311-abi3-musllinux_1_2_aarch64.whl

Download URL graphed-0.0.4-cp311-abi3-musllinux_1_2_aarch64.whl
Size 5.6 MB
Tags CPython 3.11 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
930778ed4fd3bd38a48e6b89d0f17de9d5bcbae5282b7d987d2f9e2ba179fec0
BLAKE2b-256 checksum
How to use checksums
e4fc6414de77e770c4940572b9c471dd3c0c7070ac2f1c9c0b91ba8a9b8cbc3c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp311-abi3-manylinux_2_28_x86_64.whl

Download URL graphed-0.0.4-cp311-abi3-manylinux_2_28_x86_64.whl
Size 5.5 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
5c1b7be194aa7e3c2c62b06ba2952f817734c4a44c2ef853c9c68039a7fd1579
BLAKE2b-256 checksum
How to use checksums
f34250de6c198c09d101a68c7bfe5ee6fd175e569d5622040f36d1afec577598
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp311-abi3-manylinux_2_28_aarch64.whl

Download URL graphed-0.0.4-cp311-abi3-manylinux_2_28_aarch64.whl
Size 5.5 MB
Tags CPython 3.11 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
628c95afca7ef7f815385959664fc787eaf58102a1fe323ba87f5203b2eb89e7
BLAKE2b-256 checksum
How to use checksums
2c0d8fd22cc7b6ca150e54327162d91ccbf3752285ca9c0ae6c85ed85bb44a25
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp311-abi3-macosx_11_0_arm64.whl

Download URL graphed-0.0.4-cp311-abi3-macosx_11_0_arm64.whl
Size 5.5 MB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
ec68883371337f331e58ba8850cfb9c6fd286b9c1b4b3d4f73d20736def7bb6e
BLAKE2b-256 checksum
How to use checksums
b9e7365cbb6737324b6c72db6d4050101b2c4d6e060477e5028fe2e701787c6f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / graphed-0.0.4-cp311-abi3-macosx_10_12_x86_64.whl

Download URL graphed-0.0.4-cp311-abi3-macosx_10_12_x86_64.whl
Size 5.5 MB
Tags CPython 3.11 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
53bfe574412699676c3be5585b5d83c588829995b92e2357c3753a4e345b3e4e
BLAKE2b-256 checksum
How to use checksums
7b952ca5af0e53d66d690d419b96ba7c69522983b0b877052d9b8e320cc64c31
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

0.0.6

25 release files

0.0.5

22 release files

This release

0.0.4 This release

15 release files

0.0.3

15 release files

0.0.2

15 release files

0.0.1

21 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