Commit 8b808377 authored by dengjb's avatar dengjb
Browse files

Update README.md

parent e1f74834
# FastSAM_pytorch _# FastSAM_pytorch
## 论文 ## 论文
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
``` ```
docker pull image.sourcefind.cn:5000/dcu/admin/base/pytorch:1.13.1-centos7.6-dtk23.10-py38 docker pull image.sourcefind.cn:5000/dcu/admin/base/pytorch:1.13.1-centos7.6-dtk23.10-py38
# <your IMAGE ID>为以上拉取的docker的镜像ID替换 # <your IMAGE ID>为以上拉取的docker的镜像ID替换
docker run -it -v /path/your_code_data/:/path/your_code_data/ --shm-size=32G --privileged=true --device=/dev/kfd --device=/dev/dri/ --group-add video --name docker_name imageID bash docker run -it -v /path/your_code_data/:/path/your_code_data/ -v /opt/hyhal:/opt/hyhal --shm-size=32G --privileged=true --device=/dev/kfd --device=/dev/dri/ --group-add video --name docker_name imageID bash
cd /path/workspace/ cd /path/workspace/
pip3 install -r requirements.txt pip3 install -r requirements.txt
pip3 install git+https://github.com/openai/CLIP.git pip3 install git+https://github.com/openai/CLIP.git
...@@ -34,7 +34,7 @@ pip3 install git+https://github.com/openai/CLIP.git ...@@ -34,7 +34,7 @@ pip3 install git+https://github.com/openai/CLIP.git
cd ./docker cd ./docker
docker build --no-cache -t crnn_pytorch:last . docker build --no-cache -t crnn_pytorch:last .
# <your IMAGE ID>为以上拉取的docker的镜像ID替换 # <your IMAGE ID>为以上拉取的docker的镜像ID替换
docker run -it -v /path/your_code_data/:/path/your_code_data/ --shm-size=32G --privileged=true --device=/dev/kfd --device=/dev/dri/ --group-add video --name docker_name imageID bash docker run -it -v /path/your_code_data/:/path/your_code_data/ -v /opt/hyhal:/opt/hyhal --shm-size=32G --privileged=true --device=/dev/kfd --device=/dev/dri/ --group-add video --name docker_name imageID bash
``` ```
### Anaconda (方法三) ### Anaconda (方法三)
...@@ -42,10 +42,10 @@ docker run -it -v /path/your_code_data/:/path/your_code_data/ --shm-size=32G --p ...@@ -42,10 +42,10 @@ docker run -it -v /path/your_code_data/:/path/your_code_data/ --shm-size=32G --p
1、关于本项目DCU显卡所需的特殊深度学习库可从光合开发者社区下载安装: https://developer.hpccube.com/tool/ 1、关于本项目DCU显卡所需的特殊深度学习库可从光合开发者社区下载安装: https://developer.hpccube.com/tool/
``` ```
DTK软件栈:dtk22.10 DTK软件栈:dtk23.10
python:python3.8 python:python3.8
pytorch:1.10.0 pytorch:1.13.1
torchvision:0.10.0 torchvision:0.14.0
``` ```
Tips:以上dtk软件栈、python、pytorch等DCU相关工具版本需要严格一一对应 Tips:以上dtk软件栈、python、pytorch等DCU相关工具版本需要严格一一对应
...@@ -75,7 +75,7 @@ pip3 install git+https://github.com/openai/CLIP.git ...@@ -75,7 +75,7 @@ pip3 install git+https://github.com/openai/CLIP.git
#### 单卡推理 #### 单卡推理
[权重下载地址](https://pan.baidu.com/s/18KzBmOTENjByoWWR17zdiQ?pwd=0000) [权重下载地址](https://pan.baidu.com/s/18KzBmOTENjByoWWR17zdiQ?pwd=0000)
``` ```
HIP_VISIBLE_DEVICES=1 python Inference.py --model_path ./weights/FastSAM-x.pt --img_path ./images/dogs.jpg HIP_VISIBLE_DEVICES=1 python Inference.py --model_path ./weights/FastSAM_X.pt --img_path ./images/dogs.jpg
``` ```
## result ## result
此处以Fast-SAM-x模型进行推理测试<br> 此处以Fast-SAM-x模型进行推理测试<br>
...@@ -107,4 +107,4 @@ https://developer.hpccube.com/codes/modelzoo/fastsam_pytorch ...@@ -107,4 +107,4 @@ https://developer.hpccube.com/codes/modelzoo/fastsam_pytorch
## 参考资料 ## 参考资料
[GitHub - Fast-SAM](https://github.com/CASIA-IVA-Lab/FastSAM?tab=readme-ov-file) [GitHub - Fast-SAM](https://github.com/CASIA-IVA-Lab/FastSAM?tab=readme-ov-file)_
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment