Tao dataset_convert problem

Hello, I try to use TAO toolkit to train an object detection on yolo_V4 notebook. I have a custom dataset, prepared in kitti format. But I have some errors.

First time I made the labels to have 15 columns, as in Data Annotation Format — TAO Toolkit 3.22.05 documentation, but i get the following error on line 297:

 File "/root/.cache/bazel/_bazel_root/ed34e6d125608f91724fda23656f1726/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/iva/build_wheel.runfiles/ai_infra/iva/detectnet_v2/dataio/kitti_converter_lib.py", line 192, in _create_example_proto
  File "/root/.cache/bazel/_bazel_root/ed34e6d125608f91724fda23656f1726/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/iva/build_wheel.runfiles/ai_infra/iva/detectnet_v2/dataio/kitti_converter_lib.py", line 297, in _add_targets
  File "/usr/local/lib/python3.6/dist-packages/numpy/lib/npyio.py", line 2080, in genfromtxt
    raise ValueError(errmsg)
ValueError: Some errors were detected !
    Line #2 (got 15 columns instead of 16)

So I thought the label, needed 16 columns, so I made a new dataset with 16 columns. And a again a new error, on line 303, (so its okay on line 297):

  File "/root/.cache/bazel/_bazel_root/ed34e6d125608f91724fda23656f1726/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/iva/build_wheel.runfiles/ai_infra/iva/detectnet_v2/dataio/dataset_converter_lib.py", line 165, in _write_shard
  File "/root/.cache/bazel/_bazel_root/ed34e6d125608f91724fda23656f1726/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/iva/build_wheel.runfiles/ai_infra/iva/detectnet_v2/dataio/kitti_converter_lib.py", line 192, in _create_example_proto
  File "/root/.cache/bazel/_bazel_root/ed34e6d125608f91724fda23656f1726/execroot/ai_infra/bazel-out/k8-fastbuild/bin/magnet/packages/iva/build_wheel.runfiles/ai_infra/iva/detectnet_v2/dataio/kitti_converter_lib.py", line 303, in _add_targets
AssertionError: Ground truth kitti labels should have only 15 fields.
2022-07-25 13:48:10,849 [INFO] tlt.components.docker_handler.docker_handler: Stopping container.

There should be something wrong in one or several label files. Each file should have only 15 fields. You can split your dataset and find the culprit.

1 Like