-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_demo.bash
executable file
·72 lines (68 loc) · 2.71 KB
/
run_demo.bash
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
#!/bin/bash
xhost +local:docker
is_x64=$(docker image ls dddmr_gtsam | grep x64)
is_cuda=$(docker image ls dddmr_gtsam | grep 12.4.1)
is_l4t_r36=$(docker image ls dddmr_gtsam | grep l4t_r36)
is_l4t_r35=$(docker image ls dddmr_gtsam | grep l4t_r35)
if [ "$is_cuda" != "" ] ;then
docker run -it \
--privileged \
--network=host \
--runtime=nvidia\
--env="DISPLAY" \
--env="QT_X11_NO_MITSHM=1" \
--env="NVIDIA_VISIBLE_DEVICES=all"\
--env="NVIDIA_DRIVER_CAPABILITIES=all"\
--volume="/tmp/.X11-unix:/tmp/.X11-unix:rw" \
--volume="${HOME}/dddmr_bags:/root/dddmr_bags" \
--volume="${HOME}/dddmr_navigation:/root/dddmr_navigation" \
--name="dddmr_ros2_dev" \
dddmr_gtsam:12.4.1-cudnn-devel-ubuntu22.04
elif [ "$is_x64" != "" ] ;then
docker run -it \
--privileged \
--network=host \
--env="DISPLAY" \
--env="QT_X11_NO_MITSHM=1" \
--volume="/tmp/.X11-unix:/tmp/.X11-unix:rw" \
--volume="${HOME}/dddmr_bags:/root/dddmr_bags" \
--volume="${HOME}/dddmr_navigation:/root/dddmr_navigation" \
--name="dddmr_ros2_dev" \
dddmr_gtsam:x64
elif [ "$is_l4t_r36" != "" ] ;then
docker run -it \
--privileged \
--network=host \
--runtime=nvidia\
--env="DISPLAY" \
--env="QT_X11_NO_MITSHM=1" \
--env="NVIDIA_VISIBLE_DEVICES=all"\
--env="NVIDIA_DRIVER_CAPABILITIES=all"\
--volume="/usr/bin/tegrastats:/usr/bin/tegrastats" \
--volume="/usr/local/cuda-12.2:/usr/local/cuda-12.2" \
--volume="/usr/lib/aarch64-linux-gnu/tegra:/usr/lib/aarch64-linux-gnu/tegra" \
--volume="/lib/modules:/lib/modules" \
--volume="/tmp/.X11-unix:/tmp/.X11-unix:rw" \
--volume="${HOME}/dddmr_bags:/root/dddmr_bags" \
--volume="${HOME}/dddmr_navigation:/root/dddmr_navigation" \
--name="dddmr_ros2_dev" \
dddmr_gtsam:l4t_r36
elif [ "$is_l4t_r35" != "" ] ;then
docker run -it \
--privileged \
--network=host \
--runtime=nvidia\
--env="DISPLAY" \
--env="QT_X11_NO_MITSHM=1" \
--env="NVIDIA_VISIBLE_DEVICES=all"\
--env="NVIDIA_DRIVER_CAPABILITIES=all"\
--volume="/usr/bin/tegrastats:/usr/bin/tegrastats" \
--volume="/usr/local/cuda-11.4:/usr/local/cuda-11.4" \
--volume="/usr/lib/aarch64-linux-gnu/tegra:/usr/lib/aarch64-linux-gnu/tegra" \
--volume="/lib/modules:/lib/modules" \
--volume="/tmp/.X11-unix:/tmp/.X11-unix:rw" \
--volume="${HOME}/dddmr_bags:/root/dddmr_bags" \
--volume="${HOME}/dddmr_navigation:/root/dddmr_navigation" \
--name="dddmr_ros2_dev" \
dddmr_gtsam:l4t_r35
fi