Skip to content

Commit

Permalink
[NVIDIA] CUDA version update (openvinotoolkit#652)
Browse files Browse the repository at this point in the history
* update the dockerfile to use cuda base image and correct apt nvidia packages

* Return cudnn into Dockerfile, adds drivers

* Update README.md

---------

Co-authored-by: Dariusz Trawinski <[email protected]>
  • Loading branch information
nkogteva and dtrawins authored May 8, 2023
1 parent 4c116a1 commit 032afce
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 14 deletions.
13 changes: 8 additions & 5 deletions modules/nvidia_plugin/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
FROM docker.io/library/ubuntu:focal
FROM nvidia/cuda:11.8.0-runtime-ubuntu20.04
ARG enable_tensorrt
ADD https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004.pin /etc/apt/preferences.d/cuda-repository-pin-600

# nv-tensorrt-repo-*.deb packages
COPY *.deb /

SHELL ["/bin/bash", "-c"]
Expand All @@ -24,7 +25,8 @@ RUN set -exuo pipefail ; \
build-essential \
ca-certificates \
clang-format-9 \
cuda \
cuda-runtime-11-8 \
cuda-11-8 \
curl \
g++-multilib \
gcc-multilib \
Expand All @@ -35,8 +37,8 @@ RUN set -exuo pipefail ; \
libavformat-dev \
libboost-regex-dev \
libcairo2-dev \
libcutensor1 \
libcutensor-dev \
libcutensor1=1.6.1.5-1 \
libcutensor-dev=1.6.1.5-1 \
libglib2.0-dev \
libgstreamer1.0-0 \
libgtk2.0-dev \
Expand All @@ -55,6 +57,7 @@ RUN set -exuo pipefail ; \
time \
unzip \
wget \
cuda-drivers=520.61.05-1\
; \
pip3 install cython ; \
curl -L https://github.com/Kitware/ninja/releases/download/v1.10.0.gfb670.kitware.jobserver-1/ninja-1.10.0.gfb670.kitware.jobserver-1_x86_64-linux-gnu.tar.gz | tar xzv --strip-components=1 -C /usr/local/bin ; \
Expand All @@ -71,4 +74,4 @@ RUN set -exuo pipefail ; \
rm -r *.deb ccache*

ENV CUDA_PATH=/usr/local/cuda
ENV PATH=${CUDA_PATH}/bin:$PATH
ENV PATH=${CUDA_PATH}/bin:$PATH
18 changes: 9 additions & 9 deletions modules/nvidia_plugin/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ The plugin uses custom kernels and [cuBLAS, cuDNN, cuTENSOR libraries\*] as a ba
## Supported Platforms
OpenVINO™ NVIDIA GPU plugin is supported and validated on the following platforms:

OS | GPU
---------------------- | ----------------------
Ubuntu* 20.04 (64-bit) | NVIDIA Quadro RTX 4000
OS | GPU | Driver |
---------------------- | --------------------- |--------------------- |
Ubuntu* 20.04 (64-bit) | NVIDIA Quadro RTX 4000| 520.61.05 |

## Distribution
OpenVINO™ NVIDIA GPU plugin is not included into Intel® Distribution of OpenVINO™. To use the plugin, it should be built from source code.
Expand All @@ -32,13 +32,13 @@ sudo apt-get update
sudo apt-get install clang-8 clang++8
```

2. Install **NVIDIA 460** version of driver from [NVIDIA download drivers](http://www.nvidia.com/Download/index.aspx?lang=en-us)
3. Install **CUDA 11.2** from [How to install CUDA](https://docs.nvidia.com/cuda/cuda-quick-start-guide/index.html)
2. Install suitable **NVIDIA driver** from [NVIDIA download drivers](http://www.nvidia.com/Download/index.aspx?lang=en-us)
3. Install **CUDA 11.8** from [How to install CUDA](https://docs.nvidia.com/cuda/cuda-quick-start-guide/index.html)

Do not forget to add `<path_to_cuda>/bin/` in **PATH** variable for example `export PATH="<path_to_cuda>/bin:$PATH"`

4. Install **cuDNN 8.1.0** from [How to install cuDNN](https://docs.nvidia.com/deeplearning/cudnn/install-guide/index.html)
5. Install **cuTENSOR 1.3.0** from [How to install cuTENSOR](https://docs.nvidia.com/cuda/cutensor/getting_started.html#installation-and-compilation)
4. Install **cuDNN 8.6.0** from [How to install cuDNN](https://docs.nvidia.com/deeplearning/cudnn/install-guide/index.html)
5. Install **cuTENSOR 1.6.1** from [How to install cuTENSOR](https://docs.nvidia.com/cuda/cutensor/getting_started.html#installation-and-compilation)

### Build with cmake

Expand Down Expand Up @@ -107,12 +107,12 @@ git checkout develop
```
3. Setup `CUDACXX` environment variable to point to the CUDA _nvcc_ compiler like the next (use yours path)
```bash
export CUDACXX=/usr/local/cuda-11.2/bin/nvcc
export CUDACXX=/usr/local/cuda-11.8/bin/nvcc
```

4. Add the path to the cuda libraries to the `LD_LIBRARY_PATH` environment variable like the next (use yours path)
```bash
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda-11.2/bin/nvcc
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda-11.8/bin/nvcc
```

5. Run setup.py build command as follows.
Expand Down

0 comments on commit 032afce

Please sign in to comment.