Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Inference] FP8 gemm auto-tune #9094

Merged
merged 4 commits into from
Sep 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,6 @@ FETCH_HEAD
./ppdiffusers/ppdiffusers/version.py

# third party
csrc/gpu/cutlass_kernels/cutlass
csrc/third_party/
dataset/
output/
13 changes: 12 additions & 1 deletion csrc/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ pip install -r requirements.txt

## 编译 Cuda 算子

生成 FP8的 cutlass 算子(编译耗时较长)
```shell
python generate_code_gemm_fused_kernels.py
```

编译
```shell
python setup_cuda.py install
```
Expand All @@ -20,9 +26,14 @@ python setup_cuda.py install
2. 拉取代码:
git clone -b v3.5.0 --single-branch https://github.com/NVIDIA/cutlass.git

3. 将下载的 `cutlass` 目录放在 `csrc/gpu/cutlass_kernels/cutlass`下
3. 将下载的 `cutlass` 目录放在 `csrc/third_party/cutlass`下

4. 重新编译 Cuda 算子
```shell
python setup_cuda.py install
```

### FP8 GEMM 自动调优
```shell
sh tune_fp8_gemm.sh
```
Loading
Loading