---
title: 环境要求
description: "本文档以openEuler 24.03 LTS SP3系统下编译构建Safetensors 0.7.0版本为例。除此之外，本节介绍了源码构建验证可支持的其他环境信息。"
url: https://www.hikunpeng.com/document/detail/zh/kunpengai/ecosystemEnable/safetensors/kunpengsafetensors_16_0003.html
sourcePath: /source/zh/kunpengai/ecosystemEnable/safetensors/kunpengsafetensors_16_0003.html
indexId: 7babe34e3ee26f12d1c2ff7c2e8c8c69b2ab0a78e5a01e01c91e9d07a5ec9b5180
---
# 环境要求

本文档以openEuler 24.03 LTS SP3系统下编译构建Safetensors 0.7.0版本为例。除此之外，本节介绍了源码构建验证可支持的其他环境信息。

#### 可支持的版本


**表1 版本范围**

| OS版本 | Python版本 | 支持的Safetensors版本范围 |
| --- | --- | --- |
| openEuler 24.03 LTS SP3 | Python 3.11.6 | Safetensors 0.7.x；建议Safetensors 0.7.0 |
| openEuler 22.03 LTS SP4 | Python 3.9.9 | Safetensors 0.7.x；建议Safetensors 0.7.0 |


#### 依赖组件要求


**表2 依赖组件要求对应的版本**

| 组件 | 版本 |
| --- | --- |
| python3 | 3.11.6\-20.oe2403sp3 |
| python3\-pip | 23.3.1\-7.oe2403sp3 |
| python3\-devel | 3.11.6\-20.oe2403sp3 |
| GCC | 12.3.1\-105.oe2403sp3 |
| GCC\-C++ | 12.3.1\-105.oe2403sp3 |
| make | 4.4.1\-2.oe2403sp3 |
| Git | 2.43.0\-10.oe2403sp3 |
| rust | 1.90.0\-2.oe2403sp3 |
| cargo | 1.90.0\-2.oe2403sp3 |
| pip | 26.1.1 |
| setuptools | 82.0.1 |
| wheel | 0.47.0 |
| maturin | 1.13.3 |
| packaging | 26.2 |
| NumPy | 2.4.4 |


Safetensors 0.7.0的源码构建后端为maturin，要求Python >=3.9，并需要Rust工具链。openEuler 22.03 LTS SP4默认Python 3.9.9满足Safetensors 0.7.0的Python版本要求。
