Skip to content

Commit 50fc846

Browse files
committed
Add how to use docker for NVIDIA CUDA. 9cb8e18
1 parent bdaeb16 commit 50fc846

7 files changed

Lines changed: 160 additions & 97 deletions

File tree

_sources/nvidia/packages/jetpack_sdk/jetpack_sdk_install.rst.txt

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,38 +3,48 @@ Jetpack SDK Installation
33

44
Since NVIDIA L4T 32.4.x support L4T OTA, users can download NVIDIA JetPack from NVIDIA’s official APT
55
repository.
6-
For ROScube-X users, you can use apt to install NVIDIA JetPack compoments, e.g. tensorrt, cuda.
6+
For ROScube NVIDIA platform users, you can use apt to install NVIDIA JetPack compoments, e.g. CUDA, tensorrt.
77

8-
1. Install nvidia-l4t-jetson-multimedia-api
9-
-------------------------------------------
10-
Before installing JetPack SDK, you should install nvidia-l4t-jetson-multimedia-api in a proper ver-
11-
sion coresponding to L4T version.
8+
1. Install the whole JetPack SDK
9+
--------------------------------
10+
Assuming your Jetson developer kit has been flashed with and is running **L4T 32.4.x**,
11+
the following commands will install **all** ``JetPack``.
1212

1313
.. code-block:: bash
1414
1515
sudo apt update
16-
sudo apt install nvidia-l4t-jetson-multimedia-api
16+
sudo apt install nvidia-jetpack
1717
1818
.. warning::
1919

2020
| It's **not suggested** to install ``nvidia-jetpack`` directly, because nvidia-jetpack is a meta package which will install **all JetPack SDK** compoments which occupy **8GB**.
2121
| You can only install ``particular`` JetPack SDK compoment.
2222
23-
2. Install the whole JetPack SDK
24-
--------------------------------
25-
Assuming your Jetson developer kit has been flashed with and is running **L4T 32.3.1** or higher,
26-
the following commands will install **all** ``JetPack``.
23+
2. Install particular JetPack SDK compoment.
24+
--------------------------------------------
25+
If we only want to use parts of JetPack SDK (e.g. CUDA) instead the whole JetPack SDK,
26+
we can just install related library.
2727

2828
.. code-block:: bash
2929
30+
# If we just want to use CUDA library
3031
sudo apt update
31-
sudo apt install nvidia-jetpack
32+
sudo apt install nvidia-cuda nvidia-l4t-cuda
3233
33-
3. Install particular JetPack SDK compoment.
34-
--------------------------------------------
35-
(e.g. ``nvidia-tensorrt``)
34+
3. (Optional) Use CUDA in the container.
35+
----------------------------------------
36+
If you want to use CUDA in the container, follow the steps below.
37+
38+
a. Install CUDA library in the native host.
39+
b. Use `Neuron Startup Menu <https://adlink-ros.github.io/roscube-doc/neuronsdk/neuron_startup_menu/index.html>`_ to install containers, which already include necessary packages and docker arguments.
40+
c. Entering the containers and typing the following commands.
3641

3742
.. code-block:: bash
3843
44+
# CUDA 10.2 only supports gcc8 and g++8
3945
sudo apt update
40-
sudo apt install nvidia-tensorrt
46+
sudo apt install gcc-8 g++-8
47+
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 8
48+
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 8
49+
# Install libcudnn8-dev
50+
sudo apt install libcudnn8-dev

_sources/roscube-pico/nvidia/packages/jetpack_sdk/jetpack_sdk_install.rst.txt

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,38 +3,48 @@ Jetpack SDK Installation
33

44
Since NVIDIA L4T 32.4.x support L4T OTA, users can download NVIDIA JetPack from NVIDIA’s official APT
55
repository.
6-
For ROScube-X users, you can use apt to install NVIDIA JetPack compoments, e.g. tensorrt, cuda.
6+
For ROScube NVIDIA platform users, you can use apt to install NVIDIA JetPack compoments, e.g. CUDA, tensorrt.
77

8-
1. Install nvidia-l4t-jetson-multimedia-api
9-
-------------------------------------------
10-
Before installing JetPack SDK, you should install nvidia-l4t-jetson-multimedia-api in a proper ver-
11-
sion coresponding to L4T version.
8+
1. Install the whole JetPack SDK
9+
--------------------------------
10+
Assuming your Jetson developer kit has been flashed with and is running **L4T 32.4.x**,
11+
the following commands will install **all** ``JetPack``.
1212

1313
.. code-block:: bash
1414
1515
sudo apt update
16-
sudo apt install nvidia-l4t-jetson-multimedia-api
16+
sudo apt install nvidia-jetpack
1717
1818
.. warning::
1919

2020
| It's **not suggested** to install ``nvidia-jetpack`` directly, because nvidia-jetpack is a meta package which will install **all JetPack SDK** compoments which occupy **8GB**.
2121
| You can only install ``particular`` JetPack SDK compoment.
2222
23-
2. Install the whole JetPack SDK
24-
--------------------------------
25-
Assuming your Jetson developer kit has been flashed with and is running **L4T 32.3.1** or higher,
26-
the following commands will install **all** ``JetPack``.
23+
2. Install particular JetPack SDK compoment.
24+
--------------------------------------------
25+
If we only want to use parts of JetPack SDK (e.g. CUDA) instead the whole JetPack SDK,
26+
we can just install related library.
2727

2828
.. code-block:: bash
2929
30+
# If we just want to use CUDA library
3031
sudo apt update
31-
sudo apt install nvidia-jetpack
32+
sudo apt install nvidia-cuda nvidia-l4t-cuda
3233
33-
3. Install particular JetPack SDK compoment.
34-
--------------------------------------------
35-
(e.g. ``nvidia-tensorrt``)
34+
3. (Optional) Use CUDA in the container.
35+
----------------------------------------
36+
If you want to use CUDA in the container, follow the steps below.
37+
38+
a. Install CUDA library in the native host.
39+
b. Use `Neuron Startup Menu <https://adlink-ros.github.io/roscube-doc/neuronsdk/neuron_startup_menu/index.html>`_ to install containers, which already include necessary packages and docker arguments.
40+
c. Entering the containers and typing the following commands.
3641

3742
.. code-block:: bash
3843
44+
# CUDA 10.2 only supports gcc8 and g++8
3945
sudo apt update
40-
sudo apt install nvidia-tensorrt
46+
sudo apt install gcc-8 g++-8
47+
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 8
48+
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 8
49+
# Install libcudnn8-dev
50+
sudo apt install libcudnn8-dev

_sources/roscube-x/nvidia/packages/jetpack_sdk/jetpack_sdk_install.rst.txt

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,38 +3,48 @@ Jetpack SDK Installation
33

44
Since NVIDIA L4T 32.4.x support L4T OTA, users can download NVIDIA JetPack from NVIDIA’s official APT
55
repository.
6-
For ROScube-X users, you can use apt to install NVIDIA JetPack compoments, e.g. tensorrt, cuda.
6+
For ROScube NVIDIA platform users, you can use apt to install NVIDIA JetPack compoments, e.g. CUDA, tensorrt.
77

8-
1. Install nvidia-l4t-jetson-multimedia-api
9-
-------------------------------------------
10-
Before installing JetPack SDK, you should install nvidia-l4t-jetson-multimedia-api in a proper ver-
11-
sion coresponding to L4T version.
8+
1. Install the whole JetPack SDK
9+
--------------------------------
10+
Assuming your Jetson developer kit has been flashed with and is running **L4T 32.4.x**,
11+
the following commands will install **all** ``JetPack``.
1212

1313
.. code-block:: bash
1414
1515
sudo apt update
16-
sudo apt install nvidia-l4t-jetson-multimedia-api
16+
sudo apt install nvidia-jetpack
1717
1818
.. warning::
1919

2020
| It's **not suggested** to install ``nvidia-jetpack`` directly, because nvidia-jetpack is a meta package which will install **all JetPack SDK** compoments which occupy **8GB**.
2121
| You can only install ``particular`` JetPack SDK compoment.
2222
23-
2. Install the whole JetPack SDK
24-
--------------------------------
25-
Assuming your Jetson developer kit has been flashed with and is running **L4T 32.3.1** or higher,
26-
the following commands will install **all** ``JetPack``.
23+
2. Install particular JetPack SDK compoment.
24+
--------------------------------------------
25+
If we only want to use parts of JetPack SDK (e.g. CUDA) instead the whole JetPack SDK,
26+
we can just install related library.
2727

2828
.. code-block:: bash
2929
30+
# If we just want to use CUDA library
3031
sudo apt update
31-
sudo apt install nvidia-jetpack
32+
sudo apt install nvidia-cuda nvidia-l4t-cuda
3233
33-
3. Install particular JetPack SDK compoment.
34-
--------------------------------------------
35-
(e.g. ``nvidia-tensorrt``)
34+
3. (Optional) Use CUDA in the container.
35+
----------------------------------------
36+
If you want to use CUDA in the container, follow the steps below.
37+
38+
a. Install CUDA library in the native host.
39+
b. Use `Neuron Startup Menu <https://adlink-ros.github.io/roscube-doc/neuronsdk/neuron_startup_menu/index.html>`_ to install containers, which already include necessary packages and docker arguments.
40+
c. Entering the containers and typing the following commands.
3641

3742
.. code-block:: bash
3843
44+
# CUDA 10.2 only supports gcc8 and g++8
3945
sudo apt update
40-
sudo apt install nvidia-tensorrt
46+
sudo apt install gcc-8 g++-8
47+
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 8
48+
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 8
49+
# Install libcudnn8-dev
50+
sudo apt install libcudnn8-dev

nvidia/packages/jetpack_sdk/jetpack_sdk_install.html

Lines changed: 28 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -152,13 +152,13 @@
152152
<h1>Jetpack SDK Installation<a class="headerlink" href="#jetpack-sdk-installation" title="Permalink to this headline"></a></h1>
153153
<p>Since NVIDIA L4T 32.4.x support L4T OTA, users can download NVIDIA JetPack from NVIDIA’s official APT
154154
repository.
155-
For ROScube-X users, you can use apt to install NVIDIA JetPack compoments, e.g. tensorrt, cuda.</p>
156-
<div class="section" id="install-nvidia-l4t-jetson-multimedia-api">
157-
<h2>1. Install nvidia-l4t-jetson-multimedia-api<a class="headerlink" href="#install-nvidia-l4t-jetson-multimedia-api" title="Permalink to this headline"></a></h2>
158-
<p>Before installing JetPack SDK, you should install nvidia-l4t-jetson-multimedia-api in a proper ver-
159-
sion coresponding to L4T version.</p>
155+
For ROScube NVIDIA platform users, you can use apt to install NVIDIA JetPack compoments, e.g. CUDA, tensorrt.</p>
156+
<div class="section" id="install-the-whole-jetpack-sdk">
157+
<h2>1. Install the whole JetPack SDK<a class="headerlink" href="#install-the-whole-jetpack-sdk" title="Permalink to this headline"></a></h2>
158+
<p>Assuming your Jetson developer kit has been flashed with and is running <strong>L4T 32.4.x</strong>,
159+
the following commands will install <strong>all</strong> <code class="docutils literal notranslate"><span class="pre">JetPack</span></code>.</p>
160160
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>sudo apt update
161-
sudo apt install nvidia-l4t-jetson-multimedia-api
161+
sudo apt install nvidia-jetpack
162162
</pre></div>
163163
</div>
164164
<div class="admonition warning">
@@ -169,20 +169,31 @@ <h2>1. Install nvidia-l4t-jetson-multimedia-api<a class="headerlink" href="#inst
169169
</div>
170170
</div>
171171
</div>
172-
<div class="section" id="install-the-whole-jetpack-sdk">
173-
<h2>2. Install the whole JetPack SDK<a class="headerlink" href="#install-the-whole-jetpack-sdk" title="Permalink to this headline"></a></h2>
174-
<p>Assuming your Jetson developer kit has been flashed with and is running <strong>L4T 32.3.1</strong> or higher,
175-
the following commands will install <strong>all</strong> <code class="docutils literal notranslate"><span class="pre">JetPack</span></code>.</p>
176-
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>sudo apt update
177-
sudo apt install nvidia-jetpack
172+
<div class="section" id="install-particular-jetpack-sdk-compoment">
173+
<h2>2. Install particular JetPack SDK compoment.<a class="headerlink" href="#install-particular-jetpack-sdk-compoment" title="Permalink to this headline"></a></h2>
174+
<p>If we only want to use parts of JetPack SDK (e.g. CUDA) instead the whole JetPack SDK,
175+
we can just install related library.</p>
176+
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="c1"># If we just want to use CUDA library</span>
177+
sudo apt update
178+
sudo apt install nvidia-cuda nvidia-l4t-cuda
178179
</pre></div>
179180
</div>
180181
</div>
181-
<div class="section" id="install-particular-jetpack-sdk-compoment">
182-
<h2>3. Install particular JetPack SDK compoment.<a class="headerlink" href="#install-particular-jetpack-sdk-compoment" title="Permalink to this headline"></a></h2>
183-
<p>(e.g. <code class="docutils literal notranslate"><span class="pre">nvidia-tensorrt</span></code>)</p>
184-
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>sudo apt update
185-
sudo apt install nvidia-tensorrt
182+
<div class="section" id="optional-use-cuda-in-the-container">
183+
<h2>3. (Optional) Use CUDA in the container.<a class="headerlink" href="#optional-use-cuda-in-the-container" title="Permalink to this headline"></a></h2>
184+
<p>If you want to use CUDA in the container, follow the steps below.</p>
185+
<ol class="loweralpha simple">
186+
<li><p>Install CUDA library in the native host.</p></li>
187+
<li><p>Use <a class="reference external" href="https://adlink-ros.github.io/roscube-doc/neuronsdk/neuron_startup_menu/index.html">Neuron Startup Menu</a> to install containers, which already include necessary packages and docker arguments.</p></li>
188+
<li><p>Entering the containers and typing the following commands.</p></li>
189+
</ol>
190+
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="c1"># CUDA 10.2 only supports gcc8 and g++8</span>
191+
sudo apt update
192+
sudo apt install gcc-8 g++-8
193+
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 <span class="m">8</span>
194+
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 <span class="m">8</span>
195+
<span class="c1"># Install libcudnn8-dev</span>
196+
sudo apt install libcudnn8-dev
186197
</pre></div>
187198
</div>
188199
</div>

roscube-pico/nvidia/packages/jetpack_sdk/jetpack_sdk_install.html

Lines changed: 28 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -175,13 +175,13 @@
175175
<h1>Jetpack SDK Installation<a class="headerlink" href="#jetpack-sdk-installation" title="Permalink to this headline"></a></h1>
176176
<p>Since NVIDIA L4T 32.4.x support L4T OTA, users can download NVIDIA JetPack from NVIDIA’s official APT
177177
repository.
178-
For ROScube-X users, you can use apt to install NVIDIA JetPack compoments, e.g. tensorrt, cuda.</p>
179-
<div class="section" id="install-nvidia-l4t-jetson-multimedia-api">
180-
<h2>1. Install nvidia-l4t-jetson-multimedia-api<a class="headerlink" href="#install-nvidia-l4t-jetson-multimedia-api" title="Permalink to this headline"></a></h2>
181-
<p>Before installing JetPack SDK, you should install nvidia-l4t-jetson-multimedia-api in a proper ver-
182-
sion coresponding to L4T version.</p>
178+
For ROScube NVIDIA platform users, you can use apt to install NVIDIA JetPack compoments, e.g. CUDA, tensorrt.</p>
179+
<div class="section" id="install-the-whole-jetpack-sdk">
180+
<h2>1. Install the whole JetPack SDK<a class="headerlink" href="#install-the-whole-jetpack-sdk" title="Permalink to this headline"></a></h2>
181+
<p>Assuming your Jetson developer kit has been flashed with and is running <strong>L4T 32.4.x</strong>,
182+
the following commands will install <strong>all</strong> <code class="docutils literal notranslate"><span class="pre">JetPack</span></code>.</p>
183183
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>sudo apt update
184-
sudo apt install nvidia-l4t-jetson-multimedia-api
184+
sudo apt install nvidia-jetpack
185185
</pre></div>
186186
</div>
187187
<div class="admonition warning">
@@ -192,20 +192,31 @@ <h2>1. Install nvidia-l4t-jetson-multimedia-api<a class="headerlink" href="#inst
192192
</div>
193193
</div>
194194
</div>
195-
<div class="section" id="install-the-whole-jetpack-sdk">
196-
<h2>2. Install the whole JetPack SDK<a class="headerlink" href="#install-the-whole-jetpack-sdk" title="Permalink to this headline"></a></h2>
197-
<p>Assuming your Jetson developer kit has been flashed with and is running <strong>L4T 32.3.1</strong> or higher,
198-
the following commands will install <strong>all</strong> <code class="docutils literal notranslate"><span class="pre">JetPack</span></code>.</p>
199-
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>sudo apt update
200-
sudo apt install nvidia-jetpack
195+
<div class="section" id="install-particular-jetpack-sdk-compoment">
196+
<h2>2. Install particular JetPack SDK compoment.<a class="headerlink" href="#install-particular-jetpack-sdk-compoment" title="Permalink to this headline"></a></h2>
197+
<p>If we only want to use parts of JetPack SDK (e.g. CUDA) instead the whole JetPack SDK,
198+
we can just install related library.</p>
199+
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="c1"># If we just want to use CUDA library</span>
200+
sudo apt update
201+
sudo apt install nvidia-cuda nvidia-l4t-cuda
201202
</pre></div>
202203
</div>
203204
</div>
204-
<div class="section" id="install-particular-jetpack-sdk-compoment">
205-
<h2>3. Install particular JetPack SDK compoment.<a class="headerlink" href="#install-particular-jetpack-sdk-compoment" title="Permalink to this headline"></a></h2>
206-
<p>(e.g. <code class="docutils literal notranslate"><span class="pre">nvidia-tensorrt</span></code>)</p>
207-
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>sudo apt update
208-
sudo apt install nvidia-tensorrt
205+
<div class="section" id="optional-use-cuda-in-the-container">
206+
<h2>3. (Optional) Use CUDA in the container.<a class="headerlink" href="#optional-use-cuda-in-the-container" title="Permalink to this headline"></a></h2>
207+
<p>If you want to use CUDA in the container, follow the steps below.</p>
208+
<ol class="loweralpha simple">
209+
<li><p>Install CUDA library in the native host.</p></li>
210+
<li><p>Use <a class="reference external" href="https://adlink-ros.github.io/roscube-doc/neuronsdk/neuron_startup_menu/index.html">Neuron Startup Menu</a> to install containers, which already include necessary packages and docker arguments.</p></li>
211+
<li><p>Entering the containers and typing the following commands.</p></li>
212+
</ol>
213+
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="c1"># CUDA 10.2 only supports gcc8 and g++8</span>
214+
sudo apt update
215+
sudo apt install gcc-8 g++-8
216+
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 <span class="m">8</span>
217+
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 <span class="m">8</span>
218+
<span class="c1"># Install libcudnn8-dev</span>
219+
sudo apt install libcudnn8-dev
209220
</pre></div>
210221
</div>
211222
</div>

0 commit comments

Comments
 (0)