conda install -c huggingface safetensors
```
-## Load tensors
+## Usage
+
+### Load tensors
```python
from safetensors import safe_open
tensor = tensor_slice[:, :hidden_dim]
```
-## Save tensors
+### Save tensors
```python
import torch
save_file(tensors, "model.safetensors")
```
+## Format
+
+Let's say you have safetensors file named `model.safetensors`, then `model.safetensors` will have the following internal format:
+
+<div class="flex justify-center">
+ <img src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/safetensors/safetensors-format.svg"/>
+</div>
+
## Featured Projects
Safetensors is being used widely at leading AI enterprises, such as [Hugging Face](https://huggingface.co/), [EleutherAI](https://www.eleuther.ai/), and [StabilityAI](https://stability.ai/). Here is a non-exhaustive list of projects that are using safetensors:
* [AIGC-Audio/AudioGPT](https://github.com/AIGC-Audio/AudioGPT)
* [brycedrennan/imaginAIry](https://github.com/brycedrennan/imaginAIry)
* [comfyanonymous/ComfyUI](https://github.com/comfyanonymous/ComfyUI)
-* [LianjiaTech/BELLE](https://github.com/LianjiaTech/BELLE)
\ No newline at end of file
+* [LianjiaTech/BELLE](https://github.com/LianjiaTech/BELLE)