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.10.post1.tar.gz (18.6 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.10.post1-py3-none-any.whl (19.3 kB view details)

Uploaded Python 3

File details

Details for the file safetensors_dataset-0.0.10.post1.tar.gz.

File metadata

File hashes

Hashes for safetensors_dataset-0.0.10.post1.tar.gz
Algorithm Hash digest
SHA256 1bae9127cfb9f01f8ac19dcc16ed8d4128b9aed2485250a2825a7bb6c2cd5b2b
MD5 4f653f1518dfa22c418c73554678d295
BLAKE2b-256 cbc857234a3f9712e181bcc35f3f3633fea97a76d361ccf8446a8e4a068f8d89

See more details on using hashes here.

File details

Details for the file safetensors_dataset-0.0.10.post1-py3-none-any.whl.

File metadata

File hashes

Hashes for safetensors_dataset-0.0.10.post1-py3-none-any.whl
Algorithm Hash digest
SHA256 8c2723d0727e62e88e50d0d3b4a2ea83b1580614cf1665c99902d0731ccf462c
MD5 45006efd142e9e7a64fcdec6d450d636
BLAKE2b-256 7d2c6e3caf12c510b2307d0700a10a3f64f31f3a8ee0f3e208e684a84307b823

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