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.tar.gz (15.4 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-py3-none-any.whl (15.9 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: safetensors_dataset-0.0.9.tar.gz
  • Upload date:
  • Size: 15.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.11.2

File hashes

Hashes for safetensors_dataset-0.0.9.tar.gz
Algorithm Hash digest
SHA256 f5c7053fd9097293f0121019d3c2edfdc019d9ab21a33e639e8f84e97d9bf8e8
MD5 8e2402aae3b255355c341bae6bb0a88c
BLAKE2b-256 b8f59e131c5c3601cc7f444f7dec6c7bb010994ae3ad794ad296e043a61ec3a9

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for safetensors_dataset-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 03933a390a8e605b14262dbc37fa4e18f7766f6ae5190c6827bccd06c9ec1703
MD5 3ff9d51551e1aaba012c7d80136fbcc0
BLAKE2b-256 d0050937b46b50a84eb0f88677093a77d3b4b9ffda1e7da6ae81e7edbc365fcf

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