Tensorflow ModuleNotFound

Hello, I am trying to install tensorflow in my virtual environment. I used the jetson Documentation for installation step by step, even followed a few videos. The installation starts but then I get this error:

ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directory: '/usr/local/lib/python3.6/dist-packages/gast-0.4.0.dist-info/METADATA'

Any fixes for this?

Hi,

Have you installed the gast library?
Would you mind running the following command and trying it again?

$ sudo pip3 install -U gast==0.4.0

Thanks.

Sorry, I don’t know what happened but my OS seems to have been destroyed and I am starting with a fresh OS image now. I will run that command as soon as I get the nano running again.

Okay, so now I have tensorflow installed, but I can not import it. I am working in a virtual environment (TF) if that makes any difference. Here is my terminal message:

Successfully installed gast-0.3.3 grpcio-1.32.0 six-1.15.0 tensorflow-2.4.1 tensorflow-estimator-2.4.0
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
(TF) daniel@daniel-desktop:~$ python3
Python 3.6.9 (default, Dec  8 2021, 21:08:43) 
[GCC 8.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'tensorflow'
>>> 

Hi,

Thanks for your update.

Please help to run the following command and share the output with us.

$  pip3 show tensorflow

Thanks.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.