Issue with DLI dock container

I was following the course for Jetson nano, and found the below issue:
xxxx@xxxx-desktop : ~ $ ./docker_dli_run.sh
“docker run” requires at least 1 argument.
See ‘docker run --help’.
Usage: docker run [OPTIONS] IMAGE [COMMAND] [ARG…]
Run a command in a new container
./docker_dli_run.sh: line 2: --device: command not found

I guess it should jump into the nano. Did I miss anything?

I removed the docker and reinstall, got something below:
xxxxx@xxxxx-desktop : ~ $ echo “sudo docker run --runtime nvidia -it --rm --network host --volume ~/nvdli-data:/nvdli-nano/data --volume /tmp/argus_socket:/tmp/argus_socket --device /dev/video0 nvcr.io/nvidia/dli/dli-nano-ai:v2.0.1-r32.4.4” > docker_dli_run.sh

xxxxx@xxxxx-desktop : ~ $ chmod +x docker_dli_run.sh

xxxxx@xxxxx-desktop : ~ $ ./docker_dli_run.sh

docker: Error response from daemon: error gathering device information while adding custom device “/dev/video0”: no such file or directory.

ERRO[0000] error waiting for container: context canceled

Hi,

/dev/video0 is usually used for a USB camera.
The error indicates you don’t have a camera connected to the device.

You can launch the docker without using --device /dev/video0 but this will limit you from the live camera demo.

Thanks.

I received the same error,

“docker run” requires at least 1 argument.
See ‘docker run --help’.
Usage: docker run [OPTIONS] IMAGE [COMMAND] [ARG…]
Run a command in a new container
./docker_dli_run.sh: line 2: --device: command not found

However, I am using a CSI camera (Raspberry Pi) and reinstalling gives the same error. My camera does connect and work on other files. I don’t know why this error is given. Any possible reasons? @AastaLLL

Following the course [Getting Started with AI on Jetson Nano].
https://courses.nvidia.com/courses/course-v1:DLI+S-RX-02+V2/courseware/b2e02e999d9247eb8e33e893ca052206/63a4dee75f2e4624afbc33bce7811a9b/?activate_block_id=block-v1%3ADLI%2BS-RX-02%2BV2%2Btype%40sequential%2Bblock%4063a4dee75f2e4624afbc33bce7811a9b

Can you try running this command directly as opposed to putting it in a script?

sudo docker run --runtime nvidia -it --rm --network host --volume ~/nvdli-data:/nvdli-nano/data --volume /tmp/argus_socket:/tmp/argus_socket --device /dev/video0 nvcr.io/nvidia/dli/dli-nano-ai:v2.0.1-r32.4.4
2 Likes

The command worked running it directly. Thank you.

There appears to be a missing “\” after the line that ends with socket in the example shown. Adding the missing “\” allows the script to run as expected.

Ex:

echo "sudo docker run --runtime nvidia -it --rm --network host \
    --volume ~/nvdli-data:/nvdli-nano/data \
    --volume /tmp/argus_socket:/tmp/argus_socket \
    --device /dev/video0 \
    nvcr.io/nvidia/dli/dli-nano-ai:v2.0.1-r32.4.4" > docker_dli_run.sh

Cheers,

Jon

1 Like

Thanks for point that out, @jonnymovo - we have corrected that missing backslash in the DLI course documentation.

1 Like

I had similar issue, but this doesn’t work for me.

I use 12 MP IMX477 from Arducam B0249.

I have error like this:
docker: Error response from daemon: error gathering device information while adding custom device “/dev/video0”: no such file or directory.

marek@jetson-marek:~$ ./docker_dli_run.sh
“docker run” requires at least 1 argument.
See ‘docker run --help’.

Usage: docker run [OPTIONS] IMAGE [COMMAND] [ARG…]

Run a command in a new container
marek@jetson-marek:~ marek@jetson-marek:~
sumarek@jetson-marek:~$ sudo docker run --runtime nvidia -it --rm --network host --volume ~/nvdli-data:/nvdli-no/data --volume /tmp/argus_socket:/tmp/argus_socket --device /dev/video0 nvcr.io/nvidia/dli/dli-nano-ai:v2.0.1-r32.4.4
docker: Error response from daemon: error gathering device information while adding custom device “/dev/video0”: no such file or directory.

Hi @mar.kalemba, since you are using MIPI CSI camera, remove the --device /dev/video0 option from your command line when you run the container.

Thank you! Unfortunately i have still problem with:

I tried other programs, but their also show “no device found”.
Do you know simply method to check connection with camera?

Outside of the container, try running nvgstcapture-1.0
It should show the camera feed if it is working.

Had you installed a driver for the IMX477 camera?