Skip to main content

fastsafetensors

fastsafetensors is an efficient safetensors loader. If you develop your own code that loads large safetensors files, you can try fastsafetensors APIs (see docs). For example, vLLM and SGLang have --load-format fastsafetensors command-line argument to speed up their initialization.

This library supports Linux/CUDA, ROCm, Windows, 3FS, unified-memory systems such as DGX Spark, and so on. We welcome more platform/storage-specific optimizations like them by adding new copier backends. Our CI tests Python 3.10-3.14 with PyTorch 2.11.0.

Performance Highlights

Performance highlights from the CLOUD 2025 paper and benchmark docs:

  • Standalone model loading was 4.8x-7.5x faster than the default safetensors deserializer on Llama, Falcon, and Bloom models, and reached 26.4 GB/s NVMe read throughput for Llama-70B on four GPUs with GDS.
  • In the paper's vLLM integration experiment, startup time dropped from 12.39s to 4.74s for Llama-2-13B on 4x L40S GPUs, and from 16.04s to 6.88s on 1x A100.
  • On AMD ROCm without GDS, the documented nogds path reached 6.02 GB/s for GPT-2 Medium versus 1.28 GB/s with mmap (4.7x throughput), and 2.62 GB/s for GPT-2 versus 1.01 GB/s with mmap (2.6x throughput). See the report for more details.

Quick Start

pip install fastsafetensors
pip install vllm # for quick demo
vllm serve Qwen/Qwen3-0.6B --load-format fastsafetensors
...
Loading safetensors using Fastsafetensor loader:   0% Completed | 0/1 [00:00<?, ?it/s]
Loading safetensors using Fastsafetensor loader: 100% Completed | 1/1 [00:00<00:00,  1.23it/s]

Design Details

See Overview for features, basic API usage, and configuration.

Code of Conduct

Please refer to Foundation Model Stack Community Code of Conduct.

Development

See Development.

Publication

Takeshi Yoshimura, Tatsuhiro Chiba, Manish Sethi, Daniel Waddington, Swaminathan Sundararaman. (2025) Speeding up Model Loading with fastsafetensors arXiv:2505.23072 and IEEE CLOUD 2025.

Metadata

Release files for fastsafetensors 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fastsafetensors 0.4.0
File Size Uploaded
fastsafetensors-0.4.0.tar.gz 96.3 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for fastsafetensors 0.4.0
File
fastsafetensors-0.4.0-cp314-cp314-win_arm64.whl CPython 3.14 CPython 3.14 Windows ARM64 Details
fastsafetensors-0.4.0-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
fastsafetensors-0.4.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.27+ x86-64, Linux glibc 2.28+ x86-64 Details
fastsafetensors-0.4.0-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.14 CPython 3.14 Linux glibc 2.28+ ARM64, Linux glibc 2.26+ ARM64 Details
fastsafetensors-0.4.0-cp313-cp313-win_arm64.whl CPython 3.13 CPython 3.13 Windows ARM64 Details
fastsafetensors-0.4.0-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
fastsafetensors-0.4.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.27+ x86-64, Linux glibc 2.28+ x86-64 Details
fastsafetensors-0.4.0-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ ARM64, Linux glibc 2.26+ ARM64 Details
fastsafetensors-0.4.0-cp312-cp312-win_arm64.whl CPython 3.12 CPython 3.12 Windows ARM64 Details
fastsafetensors-0.4.0-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
fastsafetensors-0.4.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.27+ x86-64, Linux glibc 2.28+ x86-64 Details
fastsafetensors-0.4.0-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.12 CPython 3.12 Linux glibc 2.28+ ARM64, Linux glibc 2.26+ ARM64 Details
fastsafetensors-0.4.0-cp311-cp311-win_arm64.whl CPython 3.11 CPython 3.11 Windows ARM64 Details
fastsafetensors-0.4.0-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
fastsafetensors-0.4.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.28+ x86-64, Linux glibc 2.27+ x86-64 Details
fastsafetensors-0.4.0-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.11 CPython 3.11 Linux glibc 2.28+ ARM64, Linux glibc 2.26+ ARM64 Details
fastsafetensors-0.4.0-cp310-cp310-win_arm64.whl CPython 3.10 CPython 3.10 Windows ARM64 Details
fastsafetensors-0.4.0-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
fastsafetensors-0.4.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.28+ x86-64, Linux glibc 2.27+ x86-64 Details
fastsafetensors-0.4.0-cp310-cp310-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl CPython 3.10 CPython 3.10 Linux glibc 2.28+ ARM64, Linux glibc 2.26+ ARM64 Details

Total release size: 26.2 MB

Release files / fastsafetensors-0.4.0.tar.gz

Download URL fastsafetensors-0.4.0.tar.gz
Size 96.3 kB
Tags Source
SHA-256 checksum
How to use checksums
d53e72d456de8b0ea953ebe17b75f6f222b90aae3d4343cf5a28f405eb24e67b
BLAKE2b-256 checksum
How to use checksums
f90c1d4fbbdaa9ca128e007aff629695a7477bbcfdc23326e0103a80d290c500
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp314-cp314-win_arm64.whl

Download URL fastsafetensors-0.4.0-cp314-cp314-win_arm64.whl
Size 652.9 kB
Tags CPython 3.14 Windows ARM64
SHA-256 checksum
How to use checksums
3ddf4edcf0c6e424099aa18094d65c417ed49e8726f102ce9ee2b77cacd2256d
BLAKE2b-256 checksum
How to use checksums
5e37d12a4632c7368a4a07f46e4eb0e2289e53778baa375b6aaf1023e7c82efd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp314-cp314-win_amd64.whl

Download URL fastsafetensors-0.4.0-cp314-cp314-win_amd64.whl
Size 460.2 kB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
891e75cddd59bdbabd4e710b136cd1c629cc2036eecc1c5ce0cc369048c30445
BLAKE2b-256 checksum
How to use checksums
874de9fd9d5c22e8397919ccbc078cf90ba5f538846035bf8c6ad4e12470a27d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL fastsafetensors-0.4.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 2.1 MB
Tags CPython 3.14 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
0b41cc718d31741238cea3a813be35d5a755b517306a179bf244dd15fced63e4
BLAKE2b-256 checksum
How to use checksums
2640da51e6a90762d1fd637c3146ece228518b4392bb86019362805537faf8dd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL fastsafetensors-0.4.0-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 2.1 MB
Tags CPython 3.14 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
0e7d0e0aabb7bdcaab4604f7493c5dfc0273700611490e6a47fc61836940f2be
BLAKE2b-256 checksum
How to use checksums
cfe43dc89c08a06300bc962a4d226bc9c4fc4d2af3bcc12184d9cbbb6e7b3302
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp313-cp313-win_arm64.whl

Download URL fastsafetensors-0.4.0-cp313-cp313-win_arm64.whl
Size 634.9 kB
Tags CPython 3.13 Windows ARM64
SHA-256 checksum
How to use checksums
b9201c0bf8f5a8099deec67150951d274a0dcc696aff5f246abdf8ac363901e9
BLAKE2b-256 checksum
How to use checksums
b6dd40a5851d124e090b142dc9baba6bcdcafcbef7c8e90d1f103ff0756d05c2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp313-cp313-win_amd64.whl

Download URL fastsafetensors-0.4.0-cp313-cp313-win_amd64.whl
Size 449.5 kB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
9d430d2123ce0a7266ad2303c6cfea98650584a87bea19246c1aa09f61bac321
BLAKE2b-256 checksum
How to use checksums
b5e48440cc0b0d673de2de622f06d793728b3ce08109929cdc1506c0366b55f8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL fastsafetensors-0.4.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 2.1 MB
Tags CPython 3.13 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
df8966a556aa56fc2536efb86f32b5e8b44012f71430a4d99aab1cce16bd2852
BLAKE2b-256 checksum
How to use checksums
9e8cf09af129f9f6e72d3db55cccfdb2804f98eb50437f6f42c5f4b993671ec8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL fastsafetensors-0.4.0-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 2.1 MB
Tags CPython 3.13 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
2ce238466938cb8fab5026fcaa156c74be59d4b1c1f56db89c6b0ed863824a5a
BLAKE2b-256 checksum
How to use checksums
b1e9ba5ce63b9a7f411fac32cf1b6940c3d8bdb2a297a44cee1d400a287d96c1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp312-cp312-win_arm64.whl

Download URL fastsafetensors-0.4.0-cp312-cp312-win_arm64.whl
Size 634.9 kB
Tags CPython 3.12 Windows ARM64
SHA-256 checksum
How to use checksums
42464a5db5969defc6c809e12baa52d7f2964c2bbc58acddc53251fc9b699a56
BLAKE2b-256 checksum
How to use checksums
b9005e9b3aa4b92baab9d3002bbcd02e77831e792e0d5477645e85fcbb047c78
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp312-cp312-win_amd64.whl

Download URL fastsafetensors-0.4.0-cp312-cp312-win_amd64.whl
Size 449.5 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
0a178417cdea34308148c25062eb5382067491847862715b2928f2e0de1310ac
BLAKE2b-256 checksum
How to use checksums
28cf3da1704aa92f635e53cc012dc2b188da55363268386da9671d9dd79181fb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL fastsafetensors-0.4.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 2.1 MB
Tags CPython 3.12 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
d1ecbb199d98d222c827ae1cc9c7b09dd9ef2d34aa0eb01baa8f81f70345dc0a
BLAKE2b-256 checksum
How to use checksums
4b4711e52808c8974a38046e2c4edc64041c2f8790e3c58765f6cdcc15e6a39b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL fastsafetensors-0.4.0-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 2.1 MB
Tags CPython 3.12 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
7a6d6c2658566b03d1d29bda8f0c52ea0ee9d686851c79c3643bda3751d583d2
BLAKE2b-256 checksum
How to use checksums
9de254084a553158302dd890aab9009fdf5a2b81dd704062b991ca7d7c2c50f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp311-cp311-win_arm64.whl

Download URL fastsafetensors-0.4.0-cp311-cp311-win_arm64.whl
Size 635.8 kB
Tags CPython 3.11 Windows ARM64
SHA-256 checksum
How to use checksums
b0efe9bc9603d25590736ce742987ccc3d516e08359245ebb215248f2899e2f5
BLAKE2b-256 checksum
How to use checksums
77d37b3c20e5be07463ecafdde871c5c21afb8ca4f61f23b359aaf5edb45ad15
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp311-cp311-win_amd64.whl

Download URL fastsafetensors-0.4.0-cp311-cp311-win_amd64.whl
Size 448.2 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
cc91a5298286ad491ceda483bc879c09cbf4ca5deefc858ef4809f8bf6f70365
BLAKE2b-256 checksum
How to use checksums
4d3f2b41867b37ee7d9e85b7185f0e0ce12cd6bc93442dca71537e8fe7fbaded
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL fastsafetensors-0.4.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 2.1 MB
Tags CPython 3.11 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
92aa2c043943b5d52f9531f4a49d136b2ba32b01cd43ca3153477b5433994b40
BLAKE2b-256 checksum
How to use checksums
4930eb87254cfa0ba643923507ac506a5841f36232b7c651d01c4d802fc97751
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL fastsafetensors-0.4.0-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 2.0 MB
Tags CPython 3.11 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
7a474f110c5448e73cc6e3bd1d1776f88956b99bd226efcf2ba8cba7ffa91727
BLAKE2b-256 checksum
How to use checksums
15b0c00663ee4a78b1086d53b1ea03d3a085631f0bb19c61da5ff7c5f76cf698
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp310-cp310-win_arm64.whl

Download URL fastsafetensors-0.4.0-cp310-cp310-win_arm64.whl
Size 634.9 kB
Tags CPython 3.10 Windows ARM64
SHA-256 checksum
How to use checksums
15c779a83f8aa6255a950beaa3237f3da7cb2ef6c0534cffea6ac8be75c5725a
BLAKE2b-256 checksum
How to use checksums
c4a6393d313ed7503bc38c27b1537b9da39aad32a9c67da72c9b043d16a93c83
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp310-cp310-win_amd64.whl

Download URL fastsafetensors-0.4.0-cp310-cp310-win_amd64.whl
Size 446.7 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
7c4a784cc3f49b50484ed069d74470aedbbcd26b6549a885fcb758aa8c4a6803
BLAKE2b-256 checksum
How to use checksums
c5d098574ef44fd49db281d456640fb4203408e2cca49305b98ba6b612780316
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl

Download URL fastsafetensors-0.4.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Size 2.0 MB
Tags CPython 3.10 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
8ccfe43f3d66147f009975ed5d58e16a89715ba441917c0577083d3efb1ed704
BLAKE2b-256 checksum
How to use checksums
d7820d02b4063776dff29617c71d8b7055ae57d57087a61963909b6df24e35a7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release files / fastsafetensors-0.4.0-cp310-cp310-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl

Download URL fastsafetensors-0.4.0-cp310-cp310-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Size 2.0 MB
Tags CPython 3.10 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64
SHA-256 checksum
How to use checksums
b577a1bc098277bcd33633455483bb01ba0dd4caf285216d75bd64d341807750
BLAKE2b-256 checksum
How to use checksums
e147f6b1ee5a851d464c5f8e27f71bd12b8c08d1fdeeaf28ae7188c6bde2dfb2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

0.4.0 This release

21 release files

0.3.2

16 release files

0.3.1

6 release files

0.3

5 release files

0.2.2

6 release files

0.2.0

6 release files

0.1.15

6 release files

0.1.14

6 release files

0.1.13

6 release files

0.1.10

5 release files

0.1.9

4 release files

0.1.8

4 release files

0.1.7

4 release files

0.1.5

3 release files

0.1.4

3 release files

0.1.3

3 release files

0.1.2

3 release files

0.1.1

3 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page