One of the reasons why open-cv / CV2 is fast is that it is written in C++ and accessible in python through CPython, in your search for a solution keep in mind that:
- The more round trips and conversions between physical systems you have, the greater lag your code will experience.
- Most browsers only natively run javascript, html, php, and WASM / webassembly . (I’m sure i’m forgetting some less used ones, JAR containers I dunno?)
- So if you want to skip sending streaming video back and forth or at least use the browser to draw bounding boxes directly on the screen, I would research implementations of CV2 support in the browser, I think Rust compiles to WASM? Not sure if it has implemented CV2.
Edit:
Maybe this is even an option to be used with anvil: