Does nano support keras-gpu?

Does nano support keras-gpu. If yes, then how to install it?

Hi,

TensorFlow-based Keras is supported on Jetson Nano.

1. Please install our official TensorFlow package here:
https://devtalk.nvidia.com/default/topic/1048776/jetson-nano/official-tensorflow-for-jetson-nano-/

2. Install Keras via pip:

sudo pip install keras

Thanks.

Hello both,

Installation of official Tensorflow was pretty quick.

But I am struggling since yesterday while pip installing Keras. Particularly, scipy is taking ages and Nano freezed multiple times.
I also tried installing scipy with apt-get method. But Keras is unable to find that installation.

Any additional tips/hints for installing keras?

Successfully installed Keras after several attempts.
Individual installations of required modules like scipy and h5py did help.
Kept an eye on installation activities with

pip3 install -v keras

I tried the same and failed. It failed building wheel for scipy and pyyaml. Manually install pyyaml but didn’t work for scipy.

What else can I do for installing scipy. Note same error happened when trying to install scikit-image.

Can anybody help?

Try running sudo apt-get install python3-scipy and sudo apt-get install python3-keras

For those that want to install scikit-image and are having problems, here is the sequence for the Jetson Nano installation (from Installing scikit-image — skimage v0.20.0.dev0 docs):

Install the required dependencies

$ sudo apt-get install python3-matplotlib python3-numpy python3-pil python3-scipy python3-tk

Install suitable compilers:

$ sudo apt-get install build-essential cython3

clone scikit-image on your jetson-nano

$ git clone GitHub - scikit-image/scikit-image: Image processing in Python

$ cd scikit-image

$ pip3 install -e .

This sequence worked for me and hopefully will go smooth for you, too

I had to increase the swap size to install scipy.

What I did wrong? It not work for my device.

(deep_learning) thee@jetsonNn:~/scikit-image$ pip3 install -e .
WARNING: The directory ‘/home/thee/.cache/pip/http’ or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo’s -H flag.
WARNING: The directory ‘/home/thee/.cache/pip’ or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo’s -H flag.
Obtaining file:///home/thee/scikit-image
ERROR: Complete output from command python setup.py egg_info:
ERROR: Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/_shared/geometry.c /home/thee/scikit-image/skimage/_shared/transform.c /home/thee/scikit-image/skimage/_shared/interpolation.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/draw/_draw.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/feature/corner_cy.c /home/thee/scikit-image/skimage/feature/censure_cy.c /home/thee/scikit-image/skimage/feature/orb_cy.c /home/thee/scikit-image/skimage/feature/brief_cy.c /home/thee/scikit-image/skimage/feature/_texture.c /home/thee/scikit-image/skimage/feature/_hessian_det_appx.c /home/thee/scikit-image/skimage/feature/_hoghistogram.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/feature/_cascade.cpp /home/thee/scikit-image/skimage/feature/_haar.cpp
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/restoration/_unwrap_1d.c /home/thee/scikit-image/skimage/restoration/_unwrap_2d.c /home/thee/scikit-image/skimage/restoration/_unwrap_3d.c /home/thee/scikit-image/skimage/restoration/_denoise_cy.c /home/thee/scikit-image/skimage/restoration/_nl_means_denoising.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/filters/rank/core_cy.c /home/thee/scikit-image/skimage/filters/rank/generic_cy.c /home/thee/scikit-image/skimage/filters/rank/percentile_cy.c /home/thee/scikit-image/skimage/filters/rank/bilateral_cy.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/future/graph/_ncut_cy.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/graph/_spath.c /home/thee/scikit-image/skimage/graph/_mcp.c /home/thee/scikit-image/skimage/graph/heap.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/io/_plugins/_colormixer.c /home/thee/scikit-image/skimage/io/_plugins/_histograms.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/measure/_ccomp.c /home/thee/scikit-image/skimage/measure/_find_contours_cy.c /home/thee/scikit-image/skimage/measure/_moments_cy.c /home/thee/scikit-image/skimage/measure/_marching_cubes_classic_cy.c /home/thee/scikit-image/skimage/measure/_marching_cubes_lewiner_cy.c /home/thee/scikit-image/skimage/measure/_pnpoly.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/morphology/_watershed.c /home/thee/scikit-image/skimage/morphology/_skeletonize_cy.c /home/thee/scikit-image/skimage/morphology/_convex_hull.c /home/thee/scikit-image/skimage/morphology/_greyreconstruct.c /home/thee/scikit-image/skimage/morphology/_extrema_cy.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/morphology/_skeletonize_3d_cy.cpp
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/morphology/_extrema_cy.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/morphology/_flood_fill_cy.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/morphology/_max_tree.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/transform/_hough_transform.c /home/thee/scikit-image/skimage/transform/_warps_cy.c /home/thee/scikit-image/skimage/transform/_radon_transform.c
Cython >= 0.23.4 not found; falling back to pre-built /home/thee/scikit-image/skimage/segmentation/_felzenszwalb_cy.c /home/thee/scikit-image/skimage/segmentation/_quickshift_cy.c /home/thee/scikit-image/skimage/segmentation/_slic.c
running egg_info
running build_src
build_src
building extension “skimage._shared.geometry” sources
building extension “skimage._shared.transform” sources
building extension “skimage._shared.interpolation” sources
building extension “skimage.draw._draw” sources
building extension “skimage.feature._cascade” sources
building extension “skimage.feature.corner_cy” sources
building extension “skimage.feature.censure_cy” sources
building extension “skimage.feature.orb_cy” sources
building extension “skimage.feature.brief_cy” sources
building extension “skimage.feature._texture” sources
building extension “skimage.feature._hessian_det_appx” sources
building extension “skimage.feature._hoghistogram” sources
building extension “skimage.feature._haar” sources
building extension “skimage.restoration._unwrap_1d” sources
building extension “skimage.restoration._unwrap_2d” sources
building extension “skimage.restoration._unwrap_3d” sources
building extension “skimage.restoration._denoise_cy” sources
building extension “skimage.restoration._nl_means_denoising” sources
building extension “skimage.filters.rank.core_cy” sources
building extension “skimage.filters.rank.generic_cy” sources
building extension “skimage.filters.rank.percentile_cy” sources
building extension “skimage.filters.rank.bilateral_cy” sources
building extension “skimage.future.graph._ncut_cy” sources
building extension “skimage.graph._spath” sources
building extension “skimage.graph._mcp” sources
building extension “skimage.graph.heap” sources
building extension “skimage.io._plugins._colormixer” sources
building extension “skimage.io._plugins._histograms” sources
building extension “skimage.measure._ccomp” sources
building extension “skimage.measure._find_contours_cy” sources
building extension “skimage.measure._moments_cy” sources
building extension “skimage.measure._marching_cubes_classic_cy” sources
building extension “skimage.measure._marching_cubes_lewiner_cy” sources
building extension “skimage.measure._pnpoly” sources
building extension “skimage.morphology._watershed” sources
building extension “skimage.morphology._skeletonize_cy” sources
building extension “skimage.morphology._convex_hull” sources
building extension “skimage.morphology._greyreconstruct” sources
building extension “skimage.morphology._max_tree” sources
building extension “skimage.morphology._skeletonize_3d_cy” sources
building extension “skimage.morphology._extrema_cy” sources
building extension “skimage.morphology._flood_fill_cy” sources
building extension “skimage.transform._hough_transform” sources
building extension “skimage.transform._warps_cy” sources
building extension “skimage.transform._radon_transform” sources
building extension “skimage.segmentation._felzenszwalb_cy” sources
building extension “skimage.segmentation._quickshift_cy” sources
building extension “skimage.segmentation._slic” sources
building extension “skimage.external.tifffile._tifffile” sources
building data_files sources
build_src: building npy-pkg config files
Partial import of skimage during the build process.
error: [Errno 13] Permission denied
----------------------------------------
ERROR: Command “python setup.py egg_info” failed with error code 1 in /home/thee/scikit-image/

It is not work for my device. After “pip3 install -v keras” Python do not recognize keras module.

(deep_learning) thee@jetsonNn:~$ python
Python 3.6.7 (default, Oct 22 2018, 11:32:17)
[GCC 8.2.0] on linux
Type “help”, “copyright”, “credits” or “license” for more information.

import keras
Traceback (most recent call last):
File “”, line 1, in
ModuleNotFoundError: No module named ‘keras’

My solution recently is look good.

$ python3 -m pip install --no-use-pep517 keras
.
.
.
Installing collected packages: pyyaml, scipy, keras
Running setup.py install for pyyaml … done
Running setup.py install for scipy … done
Successfully installed keras-2.2.4 pyyaml-5.1 scipy-1.3.0

Python 3.6.7 (default, Oct 22 2018, 11:32:17)
[GCC 8.2.0] on linux
Type “help”, “copyright”, “credits” or “license” for more information.

import scipy
import keras
Using TensorFlow backend.
exit()

I faced a bug with Keras 2.1.1 that is what i got when i ran the commands and you’ve just saved me a lot of time and pain. Merci beaucoup!