Deep Reinforcement Learning algorithm on Jetson TX2

Hi All,

Has anyone got some reference on how to deploy a Deep Reinforcement Learning algorithm on Jetson TX2? I work in Deep Learning and have been able to get the Jetson TX2 set up and run examples.

I have also been able to run my own custom Tensorflow model on Jetson.

Now, I am really interested in getting into Deep Reinforcement Learning on Jetson TX2.

Are there any pointers in this direction please?

Thanks

Hi abhisheksgumadi, we have an upcoming webinar on the topic that you may be interested in, see https://devtalk.nvidia.com/default/topic/1035407/jetson-tx2/nvidia-webinar-mdash-deep-reinforcement-learning-in-robotics-with-nvidia-jetson/

Here is the accompanying GitHub repo & tutorial — https://github.com/dusty-nv/jetson-reinforcement

I am using PyTorch with a C++ wrapper, DQN, and A3C/A3G algorithms. You can accomplish similar with TensorFlow, I prefer the performance of PyTorch on ARM architecture. For TensorFlow, take a look at running OpenAI Baselines repo.

Thanks @dusty_nv. I will take a look at the repo and also register for the webinar.

Hello @dusty_nv,
Currently, I’m working with Jetson TX2 and OpenAI baselines repo in pycharm. Unfortunately, when I try to install baselines package in virtual environment. It always tell to me:

Using cached https://files.pythonhosted.org/packages/fc/87/7b7ef3038b4783911e3fdecb5c566e3a817ce3e890e164fc174c088edb1e/cloudpickle-0.6.1-py2.py3-none-any.whl
Collecting tensorflow>=1.4.0 (from baselines)
Could not find a version that satisfies the requirement tensorflow>=1.4.0 (from baselines) (from versions: )
No matching distribution found for tensorflow>=1.4.0 (from baselines)

While I installed tensorflow-gpu in Jetson TX2. Do you know how to fix this issue?
Thank you so much,

Hi 517503, I’m not familiar with running OpenAI Baselines on Jetson, but have you tried installing this TF pip wheel?

http://developer.download.nvidia.com/compute/redist/jp33/tensorflow-gpu/
https://docs.nvidia.com/deeplearning/dgx/install-tf-jetsontx2/index.html

Thanks @dusty_nv for your feedback. I tried to re-install tensorflow in Jetson TX2. However, when I check with command of python2, it have issue as below:

nvidia@tegra-ubuntu:~$ python2
Python 2.7.11+ (default, Apr 17 2016, 14:00:29)
[GCC 5.3.1 20160413] on linux2
Type “help”, “copyright”, “credits” or “license” for more information.

import tensorflow
Traceback (most recent call last):
File “”, line 1, in
ImportError: No module named tensorflow

With python3 it is work as normal:

nvidia@tegra-ubuntu:~$ python3
Python 3.5.2 (default, Nov 12 2018, 13:43:14)
[GCC 5.4.0 20160609] on linux
Type “help”, “copyright”, “credits” or “license” for more information.

import tensorflow

Moreover, when I follow instruction of installling baselines in link:
https://github.com/openai/baselines

When I install, it appear with this issue:
nvidia@tegra-ubuntu:~/baselines$ pip install -e .
Obtaining file:///home/nvidia/baselines
Complete output from command python setup.py egg_info:
running egg_info
creating baselines.egg-info
writing top-level names to baselines.egg-info/top_level.txt
writing dependency_links to baselines.egg-info/dependency_links.txt
writing requirements to baselines.egg-info/requires.txt
writing baselines.egg-info/PKG-INFO
writing manifest file ‘baselines.egg-info/SOURCES.txt’
warning: manifest_maker: standard file ‘-c’ not found

reading manifest file 'baselines.egg-info/SOURCES.txt'
writing manifest file 'baselines.egg-info/SOURCES.txt'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/nvidia/baselines/setup.py", line 63, in <module>
    assert StrictVersion(re.sub(r'-?rc\d+$', '', tf_pkg.version)) >= StrictVersion('1.4.0')
  File "/usr/lib/python3.5/distutils/version.py", line 40, in __init__
    self.parse(vstring)
  File "/usr/lib/python3.5/distutils/version.py", line 137, in parse
    raise ValueError("invalid version number '%s'" % vstring)
ValueError: invalid version number '1.9.0+nv18.8'

----------------------------------------

Command “python setup.py egg_info” failed with error code 1 in /home/nvidia/baselines/

nvidia@tegra-ubuntu:~/baselines$

Could you please take a look and give me your advice?
I’m really thank you so much!

Dear @dusty_nv,

I checked again with baselines package and the code. I think the issue can come from version number “1.9.0+nv18.8”. It can lead to baselines package cannot find the version satisfy with Jetson TX. Therefore, is this possible to you to change the version from “1.9.0+nv18.8” to “1.9.0”

I’m looking forward to hear your advice!
Thank you so much~

Hi 517503, would you mind posting this request in a new topic, so our TensorFlow experts can take a look at the issue? Thanks.

hi Dusty_nv,
Thank you so much, I posted my question as a new topic in this:
https://devtalk.nvidia.com/default/topic/1044858/jetson-tx2/tensorflow-integrate-with-baselines-package-in-openai-gym/
I’m looking forward to receive support from Nvidia team~
Thank you so much,

hi Dusty,

Quick question…i am following along your instructions from https://github.com/dusty-nv/jetson-reinforcement
to install the project on the jetson tx2. However the installation doesn’t complete, instead it keeps ended with errors.
Do you know if it only runs on a certain version of linux? I installed the latest one 18.04 and its not working? Any insight would be
much appreciated. Also i am using jetpack 4.2. Does the project only work on jetpack 3.3?