hunglc007 / tensorflow-yolov4-tflite

YOLOv4, YOLOv4-tiny, YOLOv3, YOLOv3-tiny Implemented in Tensorflow 2.0, Android. Convert YOLO v4 .weights tensorflow, tensorrt and tflite
https://github.com/hunglc007/tensorflow-yolov4-tflite
MIT License
2.23k stars 1.24k forks source link

ValueError: Got unexpected field names: ['max_batch_size'] #401

Open Stevenisawesome520 opened 2 years ago

Stevenisawesome520 commented 2 years ago

I am facing the following error: Traceback (most recent call last): File "convert_trt.py", line 100, in <module> app.run(main) File "/usr/local/lib/python3.7/dist-packages/absl/app.py", line 303, in run _run_main(main, args) File "/usr/local/lib/python3.7/dist-packages/absl/app.py", line 251, in _run_main sys.exit(main(argv)) File "convert_trt.py", line 96, in main save_trt() File "convert_trt.py", line 58, in save_trt max_batch_size=8) File "/usr/lib/python3.7/collections/__init__.py", line 416, in _replace raise ValueError(f'Got unexpected field names: {list(kwds)!r}') ValueError: Got unexpected field names: ['max_batch_size']

is there anyone having the same problem? Would you please solve this problem? Thank you.

edwardchang0112-nctu commented 2 years ago

Any ideas on this issue? I got the same issue.

UygarUsta commented 2 years ago

Install required tensorflow version (pip install tensorflow==2.3.0rc0).Also do not forget that libnvinfer6 should also be installed.

maxlotz commented 2 years ago

This guide suggests that when using trt.TrtGraphConverterV2 instead of trt.TrtGraphConverter, it does not have a max_batch_size argument https://docs.nvidia.com/deeplearning/frameworks/tf-trt-user-guide/index.html#tf-trt-api-20

sumaiya69 commented 11 months ago

I'm facing the same issue. How did you solve the error?