I am making an automatized air hockey robot using OpenCV to detect objects
Up until now everything works but while in the loop memory is consumed in few seconds (it uses 1GB un about 1 min).
I have been disabling code to detect where the the leak comes from and finally got the line that makes the ram consume itself. It is when i get moments
moments = cv.Moments(cv.GetMat(img, 0))
where img
is simply a query from my webcam. I have tried to delete the objects after use, but with no result.
Does anyone know how to fix this one?