Files
2025-09-19 14:49:10 +08:00

32 lines
1.2 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# enginex-r_series-diffusers
运行于【昆仑芯 R200】系列算力卡的【文本生成图片】引擎基于 diffusion 架构,支持 Stable Diffusion 等最新流行模型
## Quickstart
### 构建镜像
需要xpytorch-cp38-torch201-ubuntu2004-x64-socket.run文件请前往[此处](https://git.modelhub.org.cn:9443/EngineX-Kunlunxin/r200_8f_xpytorch)下载
```bash
docker build -t r200_8f-diffuser:v0.21.4 .
```
其中基础镜像 r200-8f_xmlir-ubuntu_2004_x86_64:v0.27 通过联系昆仑芯厂商技术支持可获取
### 模型下载
模型地址https://modelscope.cn/models/AI-ModelScope/stable-diffusion-v1-5
并放到目录:`/mnt/data/models/stable-diffusion-v1-5`(如更改目录,请修改后面的执行脚本中的模型路径)
### 测试程序
1. 准备输入数据集,可以参考示例`dataset.json`
2. 在docker镜像里运行测试程序会根据`dataset.json`内容,在`output`目录下生成图片文件。
```bash
./run_in_docker.sh
```
## 测试结果
### stable-diffusion-v1-5模型
| | A100 平均生成时间(秒) | R200_8F 平均生成时间(秒) |
|------|-------------------------|----------------------------|
| 时间 | 3.0721 | 4.6615 |