TAO classification /bin/sh: 1: pip3: not found

Please provide the following information when requesting support.

• Hardware: dual boot ASUS ROG laptop (GTX 3080)
• Network Type: Classification
• TLT Version: TAO toolkit 3.22.05.
• Training spec file(If have, please share here)
• How to reproduce the issue ? (This is for errors. Please share the command line and the detailed log here.)

CUDA Version 11.6 with Ubuntu 18.04

Hi, I am working on the Pascal VOC tutorial jupyter notebook and have downloaded and unpacked the VOCdevkit package.
The next cell is:
install pip requirements
!pip3 install tqdm
!pip3 install matplotlib==3. 3. 3

when the cell is run it returns:
/bin/sh: 1: pip3: not found
/bin/sh: 1: pip3: not found

I have tried
$ sudo apt-get remove python3-pip
(from outside the notebook) and then
$ sudo apt-get install python3-pip
which confirmed pip3 was there, then removed, then reinstalled

I suspect that pip3 may need to be made visible to docker via an entry point but there do not seem to be any instructions on how to do this in the user guide or the docker post-installation steps.

I haven’t found any other mention of this on the forum.

Could someone offer some advice please?

Could you please share the link where you download this notebook?

I no longer have the command on my Terminal shell, but I believe it was:

wget --content-disposition https://api.ngc.nvidia.com/v2/resources/nvidia/tao/cv_samples/versions/v1.4.0/zip -O cv_samples_v1.4.0.zip

from the Quick start guide ‘Downloading Jupyter Notebooks and Resources’

I cannot reproduce above error.
Please try to follow TAO Toolkit Quick Start Guide — TAO Toolkit 3.22.05 documentation to setup new environment.
And then trigger notebook again.
$ jupyter notebook --ip 0.0.0.0 --allow-root --port 8888

Thank you for the pointer.

As I think you surmised there was a problem with the installation of conda/Miniconda vs virtualenv.
The new installation is exactly as in the documentation.

However the new notebook instance still returns the same alert:
/bin/sh: 1: pip3: not found
/bin/sh: 1: pip3: not found

I have noticed that I am also running pip 21.2.4 which is in the python3.8/site packages
whereas tao and the jupyter notebook are Python 3.6.
pip3 is in my Home directory, as well as /usr/bin
Where does the notebook/tao expect to find pip3?

tqdm is needed in two cells time

Could you share the log or some screenshots?
I suggest you to trigger notebook under virtual environment. For virtual environment setup, please refer to TAO Toolkit Quick Start Guide — TAO Toolkit 3.22.02 documentation or TAO Toolkit Quick Start Guide — TAO Toolkit 3.22.05 documentation or Running TAO Toolkit on an AWS VM — TAO Toolkit 3.22.05 documentation

After you have set up virtual environment, for example, the name is “launcher”, you will see something similar to below. Then you can trigger notebook.
(launcher) localhost@dl:~/demo$
(launcher) localhost@dl:~/demo$ jupyter notebook --ip 0.0.0.0 --allow-root --port 8888

Here is the screenshot.

On the left the notebook with the alert.
On the right the shell with the expected
(launcher) etc

You can also see that I was checking permissions to run the notebook and that I have saved and checkpointed (after executing each cell.
Everything seems to be running correctly except for this single alert

I need tqdm to split the data into train/val/test sets

I have also replied to your email because the screenshot doesn’t appear to upload here

Here is the screenshot.

On the left the notebook with the alert.
On the right the shell with the expected
(launcher) etc

You can also see that I was checking permissions to run the notebook and that I have saved and checkpointed (after executing each cell.
Everything seems to be running correctly except for this single alert

I need tqdm to split the data into train/val/test sets

Could you please share below result?

(launcher) peter@peter-ROG-Strix-G733QSA-G733QSA:~/cv_samples_v1.4.0/classification/tao_voc$ which pip3

(launcher) peter@peter-ROG-Strix-G733QSA-G733QSA:~/cv_samples_v1.4.0/classification/tao_voc$ pip3 --version

Here they are (pip3 version is a python 3.8 version, I thought pip3 was version agnostic(?))

Could you share the full log?


I have switched computers as there seems to have been an upload issue (did it?/didn’t it?)

This is the full log

You can click “upload” button when you reply the topic. Then upload the screenshot.

On my side,
(venv_3.0) morganh@dl:~$ which pip3
/home/morganh/venv_3.0/bin/pip3
(venv_3.0) morganh@dl:~$ pip3 --version
pip 21.0.1 from /home/morganh/venv_3.0/lib/python3.6/site-packages/pip (python 3.6)

Then,
(venv_3.0) morganh@dl:~/demo_3.0$ jupyter notebook --ip 0.0.0.0 --allow-root --port 8888

Then, inside the notebook, I can also see the similar result.

Please check if Running TAO Toolkit on an AWS VM — TAO Toolkit 3.22.05 documentation can help you.

Blockquote

Yes, I think it’s a OS or browser no longer supported issue. It has worked in the past and stuttered/stopped today. All good on my Ubuntu laptop.

I read the documentation (even though I am not using AWS) and I cannot see anything that helps there.

When I try to replicate what you did inside the notebook it ignores the commands and I get nothing back (or I am doing something wrong)::


The only thing that I can see is that you are using pip 21.0.1, which is python 3.6 and I am using 21.2.4, which is python 3.8. If that is the issue then I could change the conda installer to a python 3.6-based one (but the instructions do not say which one to use). Or I could simply remove pip 21.2.4 from /miniconda3/lib and replace it with the one in the python3.6/site-packages.
Do you have any advice?

I did not see the log of running in the notebook.
The command “! which pip3” should be running inside a cell of notebook.

Can you run inside the notebook and share the screenshot?

Which pip3 returns nothing
I tried with and without a space after ‘!’

Please share your .ipynb with me.

Click “file” → “Download as” , select .ipynb.
Then upload this .ipynb file.

On your side, to narrow down, please try to run in terminal instead of notebook.

(launcher) peter@peter-ROG-Strix-G733QSA-G733QSA:~/cv_samples_v1.4.0/classification/tao_voc$ tao classification run /bin/bash

Then, inside the docker, run below.
# which pip3
# pip3 --version

Blockquote

classification.ipynb (2.3 MB)

Blockquote

I believe there is an issue with permissions here: you asked me to:

Blockquote
but I am denied permission. To proceed - as Peter, not root - I changed the permissions for .docker and for config.json. Running
(launcher) peter@peter-ROG-Strix-G733QSA-G733QSA:~/cv_samples_v1.4.0/classification/tao_voc$ tao classification run /bin/bash gives the error
listen tcp4 0.0.0.0:8888: bind: address already in use")

Please let me know what you want me to do next.

What is the latest full log when you run below?
$ tao classification run /bin/bash

Before running above, firstly, make sure you can run below command successfully.
$ docker login nvcr.io