README.md 890 Bytes
Newer Older
zhaoying1's avatar
zhaoying1 committed
1
2
# bitsandbytes

yingzhao27's avatar
yingzhao27 committed
3
4
5
6
7
8
9
10
11
12
13
14
## 安装
bitsandbytes支持
+ Python 3.7+
+ DTK 22.10.1

### 下载DTK并配置其环境变量:
```bash
# DTK tar包下载目录:光合社区/资源工具/DCU Toolkit/DTK23.10.1(https://cancon.hpccube.com:65024/1/main/DTK-22.10.1),根据系统选择对应DTK的tar包,并解压至/opt目录。

export ROCM_PATH=/opt/dtk-22.10.1
source /opt/dtk-22.10.1/env.sh
```
zhaoying1's avatar
zhaoying1 committed
15
16
注意:上述ROCM_PATH和Makefile中的ROCM_PATH请根据自己的环境作相应更改,此处仅供参考。

yingzhao27's avatar
yingzhao27 committed
17
18
19
### 编译bitsandbytes
```bash
#下载源码
zhaoying1's avatar
zhaoying1 committed
20
git clone http://developer.hpccube.com/codes/aicomponent/bitsandbytes.git
yingzhao27's avatar
yingzhao27 committed
21
cd bitsandbytes
zhaoying1's avatar
zhaoying1 committed
22
23
24
25
export CUDA_VERSION=gfx906
make hip
```

yingzhao27's avatar
yingzhao27 committed
26
27
28
29
### 安装bitsandbytes
```bash
python setup.py install
python3 -m bitsandbytes #安装测试
zhaoying1's avatar
zhaoying1 committed
30
31
```

yingzhao27's avatar
yingzhao27 committed
32
## Note
zhaoying1's avatar
zhaoying1 committed
33
当前版本仅支持优化器相关的功能,其余功能正在开发中,完成后会及时更新。