Qengineering / Jetson-Nano-image

Jetson Nano image with deep learning frameworks

Home Page:https://qengineering.eu/install-tensorflow-2.4.0-on-jetson-nano.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Jetson Nano DNN image

output image

A Jetson Nano image with OpenCV, TensorFlow and Pytorch

License


Installation.

  • Get a 32 GB (minimal) SD-card which will hold the image.
  • Download the JetsonNano.img.xz image (7.2 GByte!) from our Sync site.
  • Flash the image on the SD card with the Imager or balenaEtcher.
  • According to issue #17 only flash the xz directly, not an unzipped img image.
  • Insert the SD card in your Jetson Nano 4 GB RAM and enjoy.
  • Username: jetson
  • Password: jetson
  • JetsonNano.zip md5sum: d186a59a0b4d95a3bb9a327feabbfa25

Tips.

  • If you are in need of extra space, you can delete the opencv and the opencv_contrib folder from the SD card. There are no longer needed since all libraries are placed in the /usr/ directory.
  • Use a tool like GParted sudo apt-get install gparted to expand the image to larger SD cards. We recommend a minimum of 64 GB. Deep learning simply requires a lot of space.


Pre-installed frameworks.

Tensorflow 2.5 and above require CUDA 11. CUDA version 11 cannot be installed on a Jetson Nano due to incompatibility between the GPU and low-level software at this time, hence Tensorflow 2.4.1. Only when NVIDIA releases a JetPack with CUDA 11 will we be able to upgrade Tensorflow.

output image

output image


OpenCV + TensorFlow.

Importing both TensorFlow and OpenCV in Python can throw the error: cannot allocate memory in static TLS block.
This behaviour only occurs on an aarch64 system and is caused by the OpenMP memory requirements not being met.
For more information, see GitHub ticket #14884.

output image

There are a few solutions. The easiest is to import OpenCV at the beginning, as shown above.
The other is disabling OpenMP by setting the -DBUILD_OPENMP and -DWITH_OPENMP flags OFF.
Where possible, OpenCV will now use the default pthread or the TBB engine for parallelization.
We don't recommend it. Not all OpenCV algorithms automatically switch to pthread.
Our advice is to import OpenCV into Python first before anything else.


paypal