Dataloaders for multi-channel graphics datasets
Project description
Graphics Datasets in Rust (gfxds)
This Rust/Python package provides dataloaders for mult-channel image datasets,
particularly related to material estimation and intrinsic image decomposition.
Writing it in Rust was a little silly, but I've gotten so tired of working with
torch.utils.data.DataLoader.
This library does as much as possible to make different datasets consistent,
mapping all RGB color data as gamma=2.2 (not quite sRGB) and all non-color data
as linear. Images should have reasonable exposure. Shading and albedo maps are
computed so that image = albedo * shading / (1 - shading). Any flipped normals
are corrected. Depth maps are rescaled (but not offset) to have a maximum of
depth of 1. All pixel values are dequantized appropriately with random noise.
All default datasets can be found in datasets.toml. If you would like to add
support for a new dataset, consider opening a PR with a new
src/dataset/[whatever dataset].rs file and entry in the datasets.toml config.
Regardless I would recommend forking this repo if you want to use it in your
own research, since configuration is limited and most decisions are hard-coded.
Example
After downloading interiorverse (https://interiorverse.github.io/#download) to a datasets folder, you can use the dataloader like so:
from gfxds import Loader
loader = Loader('/path/to/the/datasets', 'train/interiorverse/85')
loader.start() # starts background worker threads
for sample in loader:
sample.name # identifier for the element of the dataset
sample.caption # text description
for component, raster in sample.images.items():
component # the name of the image (eg roughness, normals, image)
raster # the usual float32 h*w*c numpy array
For the full API, see gfxds.pyi.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gfxds-0.1.0.tar.gz.
File metadata
- Download URL: gfxds-0.1.0.tar.gz
- Upload date:
- Size: 113.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
06a7c369cfa470004fd0cb3785fd5ca1181ffb8da3f77800c7fa06c51e09e0f6
|
|
| MD5 |
1f2df358887db00b534caecb2160f095
|
|
| BLAKE2b-256 |
2508765ebefb6965aab2394d31cff2a9f1b5997975ab9a436fe091bf3a06f3bb
|
File details
Details for the file gfxds-0.1.0-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: PyPy, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d3c292b85a50b98eb897a9ba20b7ae0f7c03371fc89d3eb6aa13e4bec40426f4
|
|
| MD5 |
f995591649980cfdc246f6d826f947c3
|
|
| BLAKE2b-256 |
5ba23183326427aecec55ae56b7f66f0a934cee7fd91b4d11123ef24d42b040c
|
File details
Details for the file gfxds-0.1.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: CPython 3.14, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5d1795cf400d4da3b1faf236395cde7e05364409ec46a808aafec69ca996a38c
|
|
| MD5 |
8fd7c835a7db04728f3a05960138d42c
|
|
| BLAKE2b-256 |
544ca5ccc0a94079a9e5a79f31fea8ede778652fe61e6c89e0025b0cfcbe8976
|
File details
Details for the file gfxds-0.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: CPython 3.13, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4ffc21aee5c96375752a98af2b918e77ce6c977151266217553751268bf48721
|
|
| MD5 |
50263208b35d90b09bc050fd1a79e673
|
|
| BLAKE2b-256 |
6fdc9f1c567041d72cdfb5769c3be68215f495a68a23596ea20769d855e2e339
|
File details
Details for the file gfxds-0.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: CPython 3.12, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2fb151ba0d5da746718f132356e635b58ef3f7bf3b55cd483c2fe531e3999bfc
|
|
| MD5 |
65b8ede371d8e9ec0facd938cd7b3bd8
|
|
| BLAKE2b-256 |
b92cca4aa2d72bcea027219f0be2d251d778589f0fca1374c1887215368e8745
|
File details
Details for the file gfxds-0.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: CPython 3.11, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7fa4fa9b557a50c7afcde29a96e88508bec9fb8e944d500ab44b638743968b8f
|
|
| MD5 |
df21d7e9bb40b7641deec7e53343137c
|
|
| BLAKE2b-256 |
319c6dd09c3b62c81105d989e13997f8fa54460e12fa24a62a1714f0c97e7df6
|
File details
Details for the file gfxds-0.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: CPython 3.10, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
40e1afc0e9e2039b1f2d42a64e8bb723e18334b6267401bde29e3f918e63b7d6
|
|
| MD5 |
82518b70bad295b069c1d32463285615
|
|
| BLAKE2b-256 |
bc21b30d5d72275a314be4fb0e0e0c7cc93462e94ca29062351c26608db5adb6
|
File details
Details for the file gfxds-0.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7dd73c08c90af1dac2f37bfa9c884e6dcd4791fad0d264eac066462c93e6f1b4
|
|
| MD5 |
73d57d83648bb7d875648002e9e6fbfe
|
|
| BLAKE2b-256 |
ace1c9ab36464b4a43f50130364fae0d87b7fea92b57d80236e54e3f914da1d6
|
File details
Details for the file gfxds-0.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: gfxds-0.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 6.9 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
24b67bcce4bf257e7f3c677b9102cad59e2b4a1216df28a2368a5c7e8f71a280
|
|
| MD5 |
cad9ec367cc4c799813e6f60f180369e
|
|
| BLAKE2b-256 |
4b861b5de57113a2b9c46d4e84830b170ee37ad4617f06565ee66bd91a3e2ffd
|