Using OpenCV with Django
Use a separate thread for the cv2 function call and the app should work like a charm. From what I figure..infinite loading is probably because the video never ceases recording and hence the code further up ahead is never taken into account, ergo an infinite loading page. Threads should probably do it. 
:) :)
I want to use OpenCV in my Django application. As OpenCV is a library, I thought we can use it like any other library.
When I try to import it using import cv2 in the views of Django, it works fine but when I try to make library function calls in Django view like cap = cv2.VideoCapture(0) and try to run the app on my browser, nothing happens: the template does not load and no traceback in the terminal and the application remains loading forever.
Don't know why but the cv2 function call is not executing as expected. Since there is no traceback, I am not able to understand what is the problem. If anyone can suggest what is wrong ? Is it the right way to use OpenCV with Django ?