Skip to main content

A simple but handy Python library to save PyTorch datasets in safetensors format.

Project description

safetensors-dataset

safetensors-dataset is a very simple and tiny package adding support to efficiently load and store Pytorch datasets in the safetensors file format:

import torch
from safetensors_dataset import SafetensorsDataset

dataset = SafetensorsDataset.from_dict({
    "x": torch.randn(8, 12, 3),
    "y": torch.randint(12, (8,))
})
dataset.save_to_file("test.safetensors")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

safetensors_dataset-0.0.9.post2.tar.gz (15.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

safetensors_dataset-0.0.9.post2-py3-none-any.whl (16.3 kB view details)

Uploaded Python 3

File details

Details for the file safetensors_dataset-0.0.9.post2.tar.gz.

File metadata

File hashes

Hashes for safetensors_dataset-0.0.9.post2.tar.gz
Algorithm Hash digest
SHA256 fcba91ebfb1f93dd47905663f3f3ebda0fd9ece17cc78ca4832d18e8fc81b045
MD5 48258f3e7f16509a3ddcdb27e2443b6a
BLAKE2b-256 d7355e9c437eb609184d7d57e330bd2f6b4c6b543885df10fd7d99636274a392

See more details on using hashes here.

File details

Details for the file safetensors_dataset-0.0.9.post2-py3-none-any.whl.

File metadata

File hashes

Hashes for safetensors_dataset-0.0.9.post2-py3-none-any.whl
Algorithm Hash digest
SHA256 813ba66e24dfa92904fdd0114f73c130a3b94d6ed6e5ed647eb2ef9975c3f8a2
MD5 3dc4c824362bf56478e3551e43dafa89
BLAKE2b-256 c1e1f3ae000bc91536951fa7a2c455f8d7eaa4fe901834adbfafd3f8a31ede65

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page