robmarkcole / coral-pi-rest-server

Perform inferencing of tensorflow-lite models on an RPi with acceleration from Coral USB stick
https://coral.ai/products/accelerator
MIT License
67 stars 20 forks source link

Flask debug mode causes the mystical "HandleQueuedBulkIn transfer in failed. Not found: USB transfer error 5" #63

Open tracetechnical opened 2 years ago

tracetechnical commented 2 years ago

Flask debug mode causes the app to initialise twice, opening another "handle" to the edge TPU.

Turning debug mode off fixes this.

Ref: https://stackoverflow.com/questions/9449101/how-to-stop-flask-from-initialising-twice-in-debug-mode#:~:text=When%20building%20a%20Flask%20service,Flask%20service%20only%20initialises%20once.

robmarkcole commented 2 years ago

Thanks for the alert!