ISMR 2023 --AMBF(四)

ambf在2023-04-19,美国办了半天workshop,在模拟上有提供colab上跑,但这是影像segmentation,而不是CRTK自动化

在Ubuntu 20.04上先装好ROS Noetic,如果有自己的GPU,依序装ambf,他提供的data,以及跑影像segmentation.

首先是(A)装ambf(其实跟之前一样)

# Install ambf dependenciessudo apt-get install libasound2-dev libgl1-mesa-dev xorg-devsudo apt-get install ros-noetic-cv-bridge ros-noetic-image-transportsource /opt/ros/noetic/setup.bash #source ros librariesgit clone https://github.com/WPI-AIM/ambfcd ambfmkdir build cd buildcmake ..make -j7

之后修改.bashrc档

gedit ~/.bashrc #open bashrc

插入

activate_ros_env(){
source /opt/ros/noetic/setup.bash #ROS
export PATH=$PATH:~/ambf/bin/lin-x86_64 #AMBF
source ~/ambf/build/devel/setup.bash #AMBF
}
alias ros="activate_ros_env"

记得source一次

. ~/.bashrc

然后开2个terminal,一个执行

ros && roscore

另一个执行

ros && ambf_simulator

之后(B)下载他提供的data

ros ##Assuming you setup the alias in the previous step cd ~git clone https://github.com/jabarragann/surgical_robotics_challenge.gitcd surgical_robotics_challenge/scriptspip install -e .python -c "import surgical_robotics_challenge; print(surgical_robotics_challenge.__file__)"cd ~/surgical_robotics_challenge  #cd <path-surgical-robotics-challenge>./run_environment_3d_med.sh

最后(C)跑影像segmentation

cd ~git clone https://github.com/Accelnet-project-repositories/dVRK-segmentation-models.gitcd dVRK-segmentation-modelspip install -e . -r requirements_basic.txt --userecho 'export PATH=$PATH:$HOME/.local/bin' >> ~/.bashrc # Add your local bin to path

记得再source一次

. ~/.bashrc
surg_seg_ros_video_record --help
git clone https://github.com/dayon95/AMBFSegmentation.git

然后跑程式http://img2.58codes.com/2024/emoticon28.gif

不过最后的这个colab的python的Jupyiter notebook档案,好像可以直接在Colab跑,完全不须Ubuntu 20.04+ROS Noetic耶,结果前面(A)(B)(C)似乎都是多余http://img2.58codes.com/2024/emoticon03.gif

原本程式是使用training 40 epoches再多2次,我把它加到100,观察大概要50 epochesr就会收敛
http://img2.58codes.com/2024/201572745MyETnQ2Fv.png


关于作者: 网站小编

码农网专注IT技术教程资源分享平台,学习资源下载网站,58码农网包含计算机技术、网站程序源码下载、编程技术论坛、互联网资源下载等产品服务,提供原创、优质、完整内容的专业码农交流分享平台。

热门文章