Closed alexarje closed 4 years ago
Hmm, strange, that one gives me no errors. I can even call functions on mg
after evaluating this. The error you pasted happens when the cv2.VideoCapture
cannot find the video (or if it is a corrupt one) resulting in the fps
variable not getting filled, which leads to the ZeroDivisionError
.
Are you sure you have an actual dance.avi in the same folder as the notebook?
Yes, it turns out to be a path problem. I just ran the notebook from the current location, while the dance.avi was in the examples folder. Moving the notebook into the examples folder, where the dance.avi is, solves the problem. We should probably do this in the release, since end users will most likely just start the notebook from where it is located and expect it to work "out of the box".
Oh yes, I actually did this in november, and I completely forgot... :) But I will also write a cell about relative and absolute paths in the notebook.
Yes, good. Important to make the first experience of the toolbox as easy as possible, otherwize new people will move on quickly.
Continuing my testing of the Jupyter notebook. Running:
mg = mgmodule.MgObject('dance.avi')
gives me this error: