Files
enginex-r200-vc-cnn/README.md
zhousha 6756e0f47f update
2025-09-19 14:32:49 +08:00

36 lines
1001 B
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-r200-vc-cnn
运行于昆仑芯 R200 算力卡的【视觉分类】引擎,基于 CNN 架构,支持 BEiT、MobileViT 等流行模型
## QuickStart
1、从 modelscope上下载视觉分类的模型例如 microsoft/beit-base-patch16-224
```python
modelscope download --model microsoft/beit-base-patch16-224
```
2、使用Dockerfile生成镜像
使用 Dockerfile 生成 镜像
```python
docker build -f Dockerfile_kunlunxin -t kunlunxin-my:v1 .
```
其中基础镜像 r200-8f_xmlir-ubuntu_2004_x86_64:v0.27 通过联系昆仑芯厂商技术支持可获取
注意 Dockerfile 中已预先将模型 microsoft_beit_base_patch16_224_pt22k_ft22k 放在了 /model 下面
3、启动docker
```python
docker run -it --rm \
--privileged \
-p 10086:80 \
--device /dev/xpu0 \
--device /dev/xpuctrl \
--name kunlun-my-v4 \
kunlunxin-my:v1
```
4、测试服务
```python
curl -X POST http://localhost:10086/v1/private/s782b4996 \
> -F "image=@/home/zhoushasha/models/026_0010.jpg"
```