-
Notifications
You must be signed in to change notification settings - Fork 689
Closed
Description
Hello,
Im trying to convert CRNN text recognition model to TensorRT backbone but getting an error. I was able to convert the pytorch model to TensorRT without any issue and also i was able to measure the performance without error. However, when I try to evaluate the model Im facing the following error. Any idea how can I solve the issue??
2022-01-25 11:29:44,658 - mmdeploy - INFO - Sorting the dataset by 'height' and 'width' is not possible.
2022-01-25 11:29:44,783 - mmdeploy - INFO - Successfully loaded tensorrt plugins from /home/Documents/Dev/MMDeploy/build/lib/libmmdeploy_tensorrt_ops.so
2022-01-25 11:29:44,783 - mmdeploy - INFO - Successfully loaded tensorrt plugins from /home/Documents/Dev/MMDeploy/build/lib/libmmdeploy_tensorrt_ops.so
[01/25/2022-11:29:45] [TRT] [W] TensorRT was linked against cuBLAS/cuBLAS LT 11.6.3 but loaded cuBLAS/cuBLAS LT 11.5.1
[01/25/2022-11:29:46] [TRT] [W] TensorRT was linked against cuBLAS/cuBLAS LT 11.6.3 but loaded cuBLAS/cuBLAS LT 11.5.1
[ ] 0/7672, elapsed: 0s, ETA:Traceback (most recent call last):
File "./tools/test.py", line 140, in <module>
main()
File "./tools/test.py", line 133, in main
args.show_dir)
File "/home/Documents/Dev/MMDeploy/mmdeploy/codebase/base/task.py", line 138, in single_gpu_test
out_dir, **kwargs)
File "/home/Documents/Dev/MMDeploy/mmdeploy/codebase/mmocr/deploy/mmocr.py", line 141, in single_gpu_test
outputs = single_gpu_test(model, data_loader, show, out_dir, **kwargs)
File "/home/anaconda3/envs/mmdeploy/lib/python3.7/site-packages/mmdet/apis/test.py", line 32, in single_gpu_test
if batch_size == 1 and isinstance(data['img'][0], torch.Tensor):
TypeError: 'DataContainer' object is not subscriptableThis is the command I use to evaluate the performance
DEPLOY_CFG="configs/mmocr/text-recognition/text-recognition_tensorrt-fp16_dynamic-1x32x32-1x32x640.py"
MODEL_CFG="/home/Documents/Dev/mmocr/configs/textrecog/crnn/crnn_academic_dataset.py"
python ./tools/test.py ${DEPLOY_CFG} ${MODEL_CFG} --model "/home/Desktop/ocr-tensorRT/end2end.engine" --out /home/Desktop/ocr-tensorRT/out/out_ocr.pkl --show-dir "/home/Desktop/ocr-tensorRT"
Thanks!
Metadata
Metadata
Assignees
Labels
No labels