any-gold
Have you ever been in a situation where you wanted to experiment with a new dataset and wasted a few hours of your time before even having access to the data? We did, and we truly believe that it should not be like that anymore.
Any Gold is thus a comprehensive collection of custom PyTorch Dataset implementations for publicly available datasets across various modalities.
Purpose
The goal of this repository is to provide custom PyTorch Dataset classes
that are compatible with PyTorch's DataLoader to facilitate experimentation
with publicly available datasets. Each dataset implementation includes
automated download functionality to locally cache the data before use. Instead of spending time to access the data,
you can focus on experimenting with it.
Features
- PyTorch Integration: All datasets implement the PyTorch
Datasetinterface - Automatic Downloads: Built-in functionality to download and cache datasets locally
- Multimodal Support: Datasets spanning various data types and domains
- Consistent API: Uniform interface across different dataset implementations
- Minimal Dependencies: Core dependencies are managed with
uv
Available Datasets
Image Datasets
PlantSeg: Large-scale in-the-wild dataset for plant disease segmentation (Paper, Zenodo)MVTecADDataset: Anomaly detection dataset for industrial inspection (Paper, Hugging Face)KPITask1PatchLevel: A dataset for kidney disease segmentation (Paper, Synapse)DeepGlobeRoadExtraction: Road extraction from satellite images (Paper, Kaggle)ISIC2018SkinLesionDataset: A dataset for skin lesion segmentation(Paper, Hugging Face)PascalVOC2012Segmentation: A dataset for semantic segmentation (Website, Kaggle)
Usage
import any_gold as ag
from torch.utils.data import DataLoader
# Initialize dataset (downloads data if not already present)
dataset = ag.AnyDataset()
# Create DataLoader
dataloader = DataLoader(dataset, batch_size=32, shuffle=True)
# Iterate through batches
for batch in dataloader:
# Your training/evaluation code here
pass
Contributing
Process
Contributions are welcome! To contribute to this project:
- Fork the repository on GitHub
- Clone your fork:
git clone https://github.com/yourusername/any-gold.git - Create a new branch for your feature:
git checkout -b feature-name - Install development dependencies (see below)
- Set up pre-commit hooks:
uv run pre-commit install - Implement a new class that inherits from
AnyDataset - Include download functionality for the dataset
- Add appropriate documentation and tests (pytest) for your dataset class
- Ensure code passes all pre-commit checks
- Submit a pull request to the main repository
We use pre-commit hooks to maintain code quality:
- Ruff for linting and formatting
- MyPy for type checking
Installation
Dependencies in this repository are managed with uv,
a fast Python package installer and resolver. The dependencies are defined in the
pyproject.toml file.
# Clone the repository
git clone https://github.com/yourusername/any-gold.git
cd any-gold
# Install dependencies with uv
uv sync --all-extras
source .venv/bin/activate
Release Process
To release a new version of the any-gold package:
- Create a new branch for the release:
git checkout -b release-vX.Y.Z - Update the version
vX.Y.Zinpyproject.toml - Run
uv syncto update the lock file - Commit the changes with a message like
release vX.Y.Z - Merge the branch into
main - trigger a new release on GitHub with the tag
vX.Y.Z
Metadata
Release files for any-gold 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| any_gold-0.3.0.tar.gz | 22.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| any_gold-0.3.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 52.6 kB
Release files / any_gold-0.3.0.tar.gz
| Download URL | any_gold-0.3.0.tar.gz |
|---|---|
| Size | 22.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
31d121d9b69e30686dddfc1f8f54bfac2c3894ff3bb572b383c7670b488452a3
|
|
BLAKE2b-256 checksum How to use checksums |
8f6d03b8c8dd18ce134c1a05d83f15288a9a6548954fc79c6fa3eee40918a1e5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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 Feb 20, 2026.
Transparency logRelease files / any_gold-0.3.0-py3-none-any.whl
| Download URL | any_gold-0.3.0-py3-none-any.whl |
|---|---|
| Size | 30.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
af4997ded2cab3e7fb092f9afae65cb61aaaa7267976a79eeb43737ebcd5949e
|
|
BLAKE2b-256 checksum How to use checksums |
3d54bbf21fce74560089586809e18805d35c0f37e6c1daf61029fd7eb2e858a2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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 Feb 20, 2026.
Transparency log