hhk7734 / tensorflow-yolov4

YOLOv4 Implemented in Tensorflow 2.
MIT License
136 stars 75 forks source link

Replaced reading of image from open-cv to pyTurboJpeg #87

Closed JayantGoel001 closed 3 years ago

JayantGoel001 commented 3 years ago

Increased Performance by using PyTurboJPEG for reading images in RGB format.

https://github.com/lilohuang/PyTurboJPEG

Issue Number: #85

Benchmark

macOS

Function Wall-clock time
cv2.imdecode() 0.528 sec
TurboJPEG.decode() 0.191 sec
cv2.imencode() 0.875 sec
TurboJPEG.encode() 0.176 sec

Windows

Function Wall-clock time
cv2.imdecode() 0.358 sec
TurboJPEG.decode() 0.135 sec
cv2.imencode() 0.581 sec
TurboJPEG.encode() 0.140 sec
JayantGoel001 commented 3 years ago

Hi @hhk7734 According to me, everything is fine but the workflow is giving some error. Can You please tell me what is it about?

hhk7734 commented 3 years ago

format check errror

change directory to local repo and run black -l 80 .

JayantGoel001 commented 3 years ago

format check errror

change directory to local repo and run black -l 80 .

Yup It Worked And Is there any requirements.txt where I can add PyturboJPEG for installation

I have added PyTurboJPEG==1.5.1 in this file https://github.com/JayantGoel001/tensorflow-yolov4/blob/Jayant/setup.cfg Is it OK?

hhk7734 commented 3 years ago

when running pip install, check pyproject.toml and then setup.py and setup.cfg. Because PyTurboJPEG will probably not affect install, It looks Ok :)

where did yoy test? windows? mac? linux?

JayantGoel001 commented 3 years ago

when running pip install, check pyproject.toml and then setup.py and setup.cfg. Because PyTurboJPEG will probably not affect install, It looks Ok :)

where did yoy test? windows? mac? linux?

Well I tested it on Colab so kind of linux Environment

hhk7734 commented 3 years ago

I don't have windows. So, I will test this on Coral, Linux, MacOS. and then will merge it. :)

hhk7734 commented 3 years ago

I have a lot of work, so the test is delayed. Tested on Linux. Merge first, and pip release will be done after other OS tests are finished.

JayantGoel001 commented 3 years ago

I have a lot of work, so the test is delayed. Tested on Linux. Merge first, and pip release will be done after other OS tests are finished.

Sure😃