README.md 759 Bytes
Newer Older
songlinfeng's avatar
songlinfeng committed
1
# cupy
songlinfeng's avatar
songlinfeng committed
2
该仓库克隆自官方仓库,并整合了依赖的第三方依赖
songlinfeng's avatar
songlinfeng committed
3

songlinfeng's avatar
songlinfeng committed
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#编译方法
```sh
export CUPY_INSTALL_USE_HIP=1
export ROCM_HOME=/opt/dtk
export HCC_AMDGPU_TARGET=gfx936
export CXXFLAGS="-fpermissive"
export CFLAGS="-fpermissive"

pip install wheel
pip install fastrlock==0.8.3 numpy==1.26.4
git clone http://developer.sourcefind.cn/codes/songlinfeng/cupy.git

cd cupy
python setup.py bdist_wheel
```
如果使用dtk-2604以上版本需要修改/opt/dtk/include/thrust/version.h,添加#define THRUST_DEVICE_SYSTEM THRUST_DEVICE_SYSTEM_HIP
```sh
#pragma once

#include <thrust/detail/config/config.h>
#define THRUST_DEVICE_SYSTEM THRUST_DEVICE_SYSTEM_HIP
#if THRUST_DEVICE_SYSTEM == THRUST_DEVICE_SYSTEM_CUDA
#include <cuda/version>
#endif
```