NGC failed to download the pre-trained weights in tlt model training

I am trying to implement a dockerized version of the transfer learning toolkit where I pull the NGC Nvidia docker into my own docker env and try to run the training in the form of a .py script.
Command to pull NGC docker :
But I am not able to download the pre-trained weights model inside the directory which I can use for further training steps.

I have converted the jupyter notebook used for trainig into a python script(which I am attaching for your reference). (26.0 KB)

getting error like :

Any help will be really appreciable.

There is ngc bin file inside 2.0_py3 docker.
Please see details below.

$ docker run --runtime=nvidia -it -v ~/demo_2.0:/workspace/tlt-experiments -p 8888:8888
–2021-01-07 09:00:18--
Resolving (…,,, …
Connecting to (||:443… connected.
HTTP request sent, awaiting response… 200 OK
Length: 20110328 (19M) [application/zip]
Saving to: ‘/opt/ngccli/’ 100%[====================================================================================================>] 19.18M 23.3MB/s in 0.8s

2021-01-07 09:00:19 (23.3 MB/s) - ‘/opt/ngccli/’ saved [20110328/20110328]

Archive: /opt/ngccli/
inflating: /opt/ngccli/ngc
extracting: /opt/ngccli/ngc.md5
root@02c4f89b270d:/workspace# which ngc
root@02c4f89b270d:/workspace# ngc --version
NGC Registry CLI 1.24.0

his Morganh … thanks for your reply. so what you told is happening correctly when I pulled the docker and start training on Jupiter notebook like this.

But in my case I am creating my own docker and inside docker I am pulling tlt-stream like this:
and calling all the files inside the docker and running that docker.
At that time I am not getting pre-trained models.
Any solution for this really appreciable.

According to your original attached screenshot, seems that the ngc is not found.

/bin/sh: 1:ngc: not found

See the log in my previous comment.
You can try to download the ngc tool when you generate your own docker.

$ wget

@Morganh hii
I have done that but still getting the error:
/bin/sh: 1:ngc:not found.
I am sharing the logs

mkdir -p /opt/ngccli &&
wget “” -P /opt/ngccli &&
unzip -u “/opt/ngccli/” -d /opt/ngccli/ &&
rm /opt/ngccli/*.zip &&
chmod u+x /opt/ngccli/ngc

@Morganh hii
if I am not wrong

this is how my docker looks.

my terminal.
at the time of unzipping getting this error?

Please change



One tip, please verify in your local pc before writing the command in the dockerfile.

1 Like

@Morganh what I can see here is there is no change in both the commands which you have mentioned . what I need to replace exactly with what ?



Please check the quotation.
Please use " instead of “

1 Like

@Morganh Hey thanks a lot… now I am able to run it successfully.
thanks for your efforts.