NVIDIA-AI-IOT / jetbot

An educational AI robot based on NVIDIA Jetson Nano.
MIT License
3k stars 1.02k forks source link

Jetbot breaks with JetPack 4.3/TensorFlow 2.0 #173

Closed skarlekar closed 2 years ago

skarlekar commented 4 years ago

I recently upgraded my Jetbot to JetPack 4.3 using the instructions at https://github.com/NVIDIA-AI-IOT/jetbot/wiki/Create-SD-Card-Image-From-Scratch to use TensorFlow 2.0 for a project.

Unfortunately after a long installation process, I find that jetbot is broken in JetPack 4.3. When I try to use any classes in jetbot, it internally imports tensorflow.NodeDef which does not seem to work in TensorFlow 2.0 and fails with the error message:

ImportError: cannot import name 'NodeDef'

Note that, JetPack 4.3 comes with TensorFlow 2.0

Please see the snapshot of error message below. My TensorFlow and JetPack environment is as follows.

Does any solution exist to resolve this issue? When is Jetbot going to be upgraded to JetPack 4.3?

Any thoughts or solutions will be much appreciated. I cannot drop the TensorFlow to previous version as I have to use version 2.0 for my project.

JetPack version:

jetbot@jetbot-desktop:~/Notebooks/my_collision_avoidance$ JETSON_L4T_STRING=$(head -n 1 /etc/nv_tegra_release)
jetbot@jetbot-desktop:~/Notebooks/my_collision_avoidance$ JETSON_L4T_RELEASE=$(echo $JETSON_L4T_STRING | cut -f 2 -d ' ' | grep -Po '(?<=R)[^;]+')
jetbot@jetbot-desktop:~/Notebooks/my_collision_avoidance$ JETSON_L4T_REVISION=$(echo $JETSON_L4T_STRING | cut -f 2 -d ',' | grep -Po '(?<=REVISION: )[^;]+')
jetbot@jetbot-desktop:~/Notebooks/my_collision_avoidance$ JETSON_L4T_VERSION="$JETSON_L4T_RELEASE.$JETSON_L4T_REVISION"
jetbot@jetbot-desktop:~/Notebooks/my_collision_avoidance$ echo "$LOG Jetson BSP Version:  L4T R$JETSON_L4T_VERSION"
 Jetson BSP Version:  L4T R32.3.1
jetbot@jetbot-desktop:~/Notebooks/my_collision_avoidance$

Error screenshot:

image

Xin20 commented 4 years ago

don't import Camera from jetbot, just import Camera. Same to bgr8_to_jpeg