bodyposeNet FileNotFoundError: [Errno 2] No such file or directory: '/workspace/tlt_cv_samples/bpnet/data_pose_config/coco_spec.json'

@Morganh

I am trying to train bodyposeNet using the jupyter notebook.
I amusing the following commands:
docker run --runtime=nvidia -it -v /home/dipesh/tlt_cv_samples:/workspace/tlt_cv_samples -v /var/run/docker.sock:/var/run/docker.sock -p 8889:8888 nvcr.io/nvidia/tlt-streamanalytics:v3.0-py3
I am stuck at the following step:
Generate segmentation masks and tfrecords from annotations
I am getting the following error:
FileNotFoundError: [Errno 2] No such file or directory: ‘/workspace/tlt_cv_samples/bpnet/data_pose_config/coco_spec.json’

but when I try to iterate from inside the docker this file is present at workspace/tlt-cv_samples/bpnet/data_pose_config.


![image|665x279]

even os.path.exists(“/workspace/tlt_cv_samples/bpnet/data_pose_config/coco_spec.json”) returns True
this is what is present in the tlt.mounts.json.
Screenshot from 2021-07-07 09-16-40

Moving this topic from Cuda-Developer-Tools-Compute-Sanitizer-API forum to TLT forum.

When you login the docker, you use " -v /home/dipesh/tlt_cv_samples:/workspace/tlt_cv_samples".
It may conflict with your ~/.tlt_mounts.json.

Please login the docker with below command instead.
$ tlt bpnet

I am inside the tlt_cv_samples folder where bpnet folder is present and I am using the following command:
“tlt bpnet”

But I am getting the following error:
ValueError: Mount point source path doesn’t exist. /home/dipesh/tlt_cv_samples_vv1.1.0/bpnet

What is your ~/.tlt_mounts.json file?

this is my tlt_mounts.json
Screenshot from 2021-07-08 11-05-24

Can you run below command in terminal instead of notebook?
$ tlt bpnet run ls /workspace/tlt_cv_samples/bpnet/data_pose_config/coco_spec.json

Share the screenshot, thanks.

I ran the following command on terminal:
tlt bpnet run ls /workspace/tlt_cv_samples/bpnet/data_pose_config/coco_spec.json
and getting the following error

This is what is inside my coco.json:
Screenshot from 2021-07-08 11-14-19

on the machine this is the local path where bpnet is present:
“/home/dipesh/tlt_cv_samples/bpnet”

Can you run below command in terminal instead of notebook?
$ cat ~/.tlt_mounts.json

Share the screenshot too, thanks.

ok, the paths are different is that creating the problem??
Screenshot from 2021-07-08 11-21-12

what should I do?

Is below folder empty?
$ls /home/dipesh/tlt_cv_samples_vv1.1.0/bpnet

This is no such folder with the name: “tlt_cv_samples_vv1.1.0”
I had renamed it to tlt_cv_samples.
inside tlt_cv_samples bpnet and its spec files are present.

ok, so you can modify your ~/.tlt_mounts.json.
Then everything should be ok.

After modifying, you can check
$ tlt bpnet run ls /workspace/tlt-experiments

According to your ~/.tlt_mounts.json file, there should be the files in bpnet folder.

I encounter the same error:


Traceback (most recent call last):
File “/opt/tlt/.cache/dazel/_dazel_tlt/2b81a5aac84a1d3b7a324f2a7a6f400b/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/driveix/build_wheel.runfiles/ai_infra/driveix/bpnet/scripts/dataset_convert.py”, line 119, in
File “/opt/tlt/.cache/dazel/_dazel_tlt/2b81a5aac84a1d3b7a324f2a7a6f400b/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/driveix/build_wheel.runfiles/ai_infra/driveix/bpnet/scripts/dataset_convert.py”, line 101, in main
FileNotFoundError: [Errno 2] No such file or directory: ‘/coco_spec.json’
Traceback (most recent call last):
File “/usr/local/bin/bpnet”, line 8, in
sys.exit(main())
File “/opt/tlt/.cache/dazel/_dazel_tlt/2b81a5aac84a1d3b7a324f2a7a6f400b/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/driveix/build_wheel.runfiles/ai_infra/driveix/bpnet/entrypoint/bpnet.py”, line 12, in main
File “/opt/tlt/.cache/dazel/_dazel_tlt/2b81a5aac84a1d3b7a324f2a7a6f400b/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/driveix/build_wheel.runfiles/ai_infra/driveix/common/entrypoint/entrypoint.py”, line 300, in launch_job
AssertionError: Process run failed.
2021-07-28 21:01:02,029 [INFO] tlt.components.docker_handler.docker_handler: Stopping container.


Following the upper advice, I run the below command:


tlt bpnet run ls /workspace/tlt_cv_samples/bpnet/data_pose_config/coco_spec.json
2021-07-28 21:29:30,398 [INFO] root: Registry: [‘nvcr.io’]
2021-07-28 21:29:30,450 [WARNING] tlt.components.docker_handler.docker_handler:
Docker will run the commands as root. If you would like to retain your
local host permissions, please add the “user”:“UID:GID” in the
DockerOptions portion of the ~/.tlt_mounts.json file. You can obtain your
users UID and GID by using the “id -u” and “id -g” commands on the
terminal.
ls: cannot access ‘/workspace/tlt_cv_samples/bpnet/data_pose_config/coco_spec.json’: No such file or directory
2021-07-28 21:29:31,198 [INFO] tlt.components.docker_handler.docker_handler: Stopping container.


In fact the file coco_spec.json is there.
I run this command:


cat ~/.tlt_mounts.json
{
“Mounts”: [
{
“source”: “/mnt/a478b327-1a7f-4a07-8d94-90d724dee801/ls/tlt-experiments/bpnet”,
“destination”: “/workspace/tlt-experiments”
},
{
“source”: “/mnt/a478b327-1a7f-4a07-8d94-90d724dee801/ls/tlt-experiments/tlt_cv_samples_v1.1.0/bpnet/specs”,
“destination”: “/workspace/tlt-experiments/tlt_cv_samples_v1.1.0/bpnet/specs”
},
{
“source”: “/mnt/a478b327-1a7f-4a07-8d94-90d724dee801/ls/tlt-experiments/tlt_cv_samples_v1.1.0/bpnet/data_pose_config”,
“destination”: “/workspace/tlt-experiments/tlt_cv_samples_v1.1.0/bpnet/data_pose_config”
},
{
“source”: “/mnt/a478b327-1a7f-4a07-8d94-90d724dee801/ls/tlt-experiments/tlt_cv_samples_v1.1.0/bpnet/model_pose_config”,
“destination”: “/workspace/tlt-experiments/tlt_cv_samples_v1.1.0/bpnet/model_pose_config”
}
]
}


what should I do?

The command tlt should run on host. I donot setup the rootless docker. Is that the reason?

@ls2008
Please create a new forum topic. Thanks.

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