Open daniel11609 opened 2 years ago
Hi @daniel11609, thank you for your interest!
This is, of course, somewhat hard to debug - I haven’t had that issue (yet) and there’s no error message. Since you’re already using VSCode: could you set a breakpoint at the “Worker started!” print and go line by line, see where the error occurs?
If that’s not an option I don’t fully know what to suggest, since everything seems to be in order. One idea would be to try another video file (or you could send me yours so I can check on another machine?).
You even use the same GPU I use - if you can describe your Python environment, I’ll try and recreate your exact steps next week and see if I can figure something out.
Hey @tfaehse, thank you for the fast response. I just tried it again without anaconda. Now I was able to convert a small clip and it worked pretty good. It seems like that the output file is missing audio, does the tool support audio?
Oh nice, that’s a relief already!
Yes and no. OpenCV doesn’t support audio, so the resulting file doesn’t have audio. But theoretically the tool should create a blurred, mute video (with a _copy postfix) and then use ffmpeg to attach the original audio track to this edited video.
That seems to have failed, the most likely explanation is that there’s no “FFMPEG_BINARY” environment variable pointing to your ffmpeg.exe.
I am on windows and I extracted the ffmpeg essentials and also created the variable. Does it matter if it is an user or system wide variable?
It shouldn’t, no. Does the tool say something along the lines of “Video blurred successfully” at the end or not?
One quick and dirty way to debug this would be to replace “sub process.run” in line 182 in src/blurre.py with a “print”. Then, once the video is blurred, check the console for that print (it should be a somewhat long ffmpeg command). Maybe you can already see what’s wrong there, or you can try running it manually in a command window and see if it works. If it works manually but not in the tool I have something to work on
It said blurred successfully in xx min xx seconds. Another thing, the output is in .mkv, when I tried converting it to mp4 or so it did not include the blurring. Any tip for that ?
Will do some testing later on and let you know if there are any more issues / solutions :)
That’s very weird. The blurred output video shouldn’t even have any of the (blurred out) information anymore, so I don’t see how converting it should make it reappear. Have you tried handbrake or something like that?
Maybe I messed smth up. Tried with vlc first, now trying some online tools (which isn't the perfect solution)
Update: When using footage directly taken from my camera (Cycliq Fly12 CE) the tool crashes when clicking start. When using output from sony vegas it is working.
Thank you for that! I have an idea of what might cause this, I vaguely remember that some devices don’t set some values, like the total frame count, for their videos. I don’t check for that possibility at all.
Could you send me a video file from your camera? A few seconds of a wall or so would easily be enough if that’s okay for you. Here would be fine, or also at my GitHub name @me.com
You should have received it by email
Yep! Just got it. I’ll get back to you when I have news :)
converted nicely, but no audio. I did see the xxx_copy file while converting. Will need to try debug mode.
I've had a quick look, the sound just seems to be some missing codec for Windows's default media player, VLC plays it just fine. The video opened without errors for me, so I'm still not fully sure what's going on there...
You can insert the following two lines after line 140 and see (in the console) if OpenCV correctly reads the frame count and framerate, that might be the issue.
print(f"Total frames: {length}")
print(f"FPS: {fps}")
Did you use the file as input?
Yeah, there were no issues for me.
Very strange. I do not understand why the short clip works, all the other ones are failing, Could it be connected to size of a file ?
Fascinating, the new video you sent me manages to crash it for me too. OpenCV's VideoCapture reports it's opened properly, but then read() never returns. I'll look into it over the weekend!
Sorry @daniel11609, no real news unfortunately. Curiously enough even the latest video works fine on macOS, it's got to be some sort of OpenCV bug on Windows. I tested a very minimal example (open video, read the first frame) and even that crashes. Can I use your video to file a report there?
@tfaehse Sure you can use it. Not a problem.
Sorry for bothering you here. Unfortunately I wasn't able to get it working on my machine. Using windows 10 and followed the steps.
when I click start the app freezes and at some point just disappears. No output / error.
Any help is appreciated :)