dusty-nv / jetson-containers

Machine Learning Containers for NVIDIA Jetson and JetPack-L4T
MIT License
2.14k stars 443 forks source link

Running CUDA 11.4 with Jetpack 6 #628

Closed dilerbatu closed 1 day ago

dilerbatu commented 1 week ago

Hey Jetson Containers Community,

Recently, I have created base image using Jetpack 5. This base image consists of ros:noetic-desktop, pytorch:1.12, torchvision, tensorflow and CUDA 11.4. After, with that base image, I have created my own docker image with faster-whisper inside. I have built CTranslate2 manually for faster-whisper. This docker image works in Jetpack 5 without any issues. I can import faster-whisper.

The issue is I need to upgrade my Jetpack 6 for another reasons. I have flashed it my Jetson Orin with Jetpack 6. After that I pulled my docker image that I built before but I can not import faster-whisper. When I type nvcc --version, it gives me CUDA 11.4 inside of docker container.

When I try to import faster-whisper, It gives me error like: RuntimeError: CUDA failed with error CUDA driver version is insufficient for CUDA runtime version".

This is how I built faster whisper manually: pip install faster-whisper==0.10.0 && pip uninstall -y ctranslate2 && \ git clone --recursive https://github.com/OpenNMT/CTranslate2.git && cd CTranslate2 && \ cmake -Bbuild_folder -DWITH_MKL=OFF -DOPENMP_RUNTIME=NONE -DWITH_CUDA=ON -DWITH_CUDNN=ON && \ cmake —build build_folder && cd build_folder && sudo make install && \ cd .. && cd python && pip3 install -r install_requirements.txt && \ python3 setup.py bdist_wheel && pip3 install dist/*.whl

Thanks.

dusty-nv commented 1 week ago

@dilerbatu yes, you need to rebuild containers for JP5->JP6, they are not compatible. jetson-containers already includes many of the packages you mentioned (like CTranslate, faster-whisper, and ROS) to build these containers across JetPack versions in an automated fashion. I would recommend moving from ROS Noetic to ROS2 Humble though, Noetic is EOL and has challenges building on 22.04.

dilerbatu commented 1 day ago

Thanks for quick answer !