Grain

Grain is a Python library for reading and processing data used to train and evaluate JAX machine-learning models.

  • AI
  • Databases
  • Tools & Utilities
Grain is a Python library for reading and processing data used to train and evaluate JAX machine-learning models. It defines data pipelines with declarative operations such as shuffling, mapping, and batching, making preprocessing faster and deterministic. It is useful for machine-learning engineers who need reliable data feeds for JAX training workflows.

Platform availability

Available on 0 of 10 platforms

  • Unraid (not listed)
  • TrueNAS (not listed)
  • Umbrel (not listed)
  • ZimaOS (not listed)
  • Proxmox (not listed)
  • Helm (not listed)
  • Mac (not listed)
  • Windows (not listed)
  • Linux (not listed)
  • Any server (not listed)

Health score?A 0-100 score computed nightly from four factors: maintained (40%: recent commits and steady activity), popular (25%: GitHub stars, log scale), easy to install (20%: platforms, install notes, setup guides, Docker image) and light to run (15%: minimum RAM, ARM support). When the source code has been checked, a fifth factor, security check (20%: automated scan for committed secrets, unsafe desktop-app settings, known-vulnerable dependencies and project hygiene; any serious finding caps it at 20), is added. Factors without data are left out and the rest are rescaled.

68/100 Good

Maintained
100last commit 3 days ago
Popular
58810 GitHub stars
Easy to install
250 install platforms, install notes, Docker image
Light to run
208 GB minimum RAM, runs on ARM
Security check
95no serious findings, CI, tests
GitHub stars
810
Open issues
167
Last commit
2026-11-17
Latest release
v0.2.19
License
Apache-2.0
Activity
rising

Checked 3 days ago - source: GitHub (google/grain)

Resources & Compatibility

Minimum requirements: 8 GB RAM, 10 GB disk. ARM (e.g. Raspberry Pi) is supported.

Checked 54 days ago - source: Docker Hub image tags and published docs

First-install notes

  • Install Grain with pip In your Python environment, run `pip install grain` to add the Grain library. Without it, Python won't recognize `import grain` and your program will stop at the first import. source
  • Install extra packages for your framework Grain often needs the model-training library you are using, so for JAX examples run `pip install jax tensorflow_datasets` (or the packages listed in your tutorial). If these are missing, the code fails before any data loading happens. source
  • Set up AWS for S3 data Only if you read data from AWS S3, install AWS CLI with `pip install awscli` and configure your credentials. Without valid credentials, S3 examples can't find your files and fail with access errors. source

Fetched 42 days ago - each note links to its source

Alternatives

No alternatives collected yet.

Common questions

What did Grain v0.7 Farro improve?

The v0.7 Farro release brought improved language and standard library ergonomics.

Does Grain compile to WebAssembly?

Yes, Grain compiles directly to WebAssembly and uses that runtime's speed and efficiency.

Are type annotations required in Grain?

No, the language checks code for type errors without requiring type annotations.

Can Grain be used with programming styles other than functional programming?

Yes, it has functional programming roots but can accommodate different programming styles.

Answers sourced from grain-lang.org

Community

Collected 48 days ago - public community threads