dthpham / sminterpolate

Make motion interpolated and fluid slow motion videos from the command line.
MIT License
1.38k stars 91 forks source link

OS X output has many mono-chromatic frames #11

Open zbeekman opened 9 years ago

zbeekman commented 9 years ago

Here is the original video and here is the output after running butterflow -s full,fps=50 ~/Downloads/t_ic2.mp4

Have I done something wrong?

zbeekman commented 9 years ago

@dthpham any insight as to what the problem may be? I installed with Homebrew FWIW

dthpham commented 9 years ago

I'm not sure yet since I can't reproduce your issue. This is a sample of what I'm getting when I'm processing your video:

The command I used is butterflow -tt stroke -a -r50 -t -s a=16,b=18,spd=1 -vs 0.75 a.mp4. Can you give that a try and tell me if you're getting the same result?

zbeekman commented 9 years ago

Nope, still have many bad frames. Maybe it's due to ffmpeg? Going to look into that.

zbeekman commented 9 years ago

for some reason homebrew things ffmpeg and opencv are missing, but they aren't, reinstalling and then going to test again.

zbeekman commented 9 years ago

Just wondering, what platform are you on, @dthpham ?

I reinstalled and upgraded opencv, ffmpeg and butterflow using homebrew and am still getting monochromatic frames, using the exact same command as you ran. Here is my terminal output:

butterflow -tt stroke -a -r50 -t -s a=16,b=18,spd=1 -vs 0.75 ~/Downloads/t_ic2.mp4
ffmpeg version 2.7.2 Copyright (c) 2000-2015 the FFmpeg developers
  built with Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
  configuration: --prefix=/usr/local/homebrew/Cellar/ffmpeg/2.7.2_1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-libvorbis --enable-libfaac --enable-libass --enable-nonfree --enable-vda
  libavutil      54. 27.100 / 54. 27.100
  libavcodec     56. 41.100 / 56. 41.100
  libavformat    56. 36.100 / 56. 36.100
  libavdevice    56.  4.100 / 56.  4.100
  libavfilter     5. 16.101 /  5. 16.101
  libavresample   2.  1.  0 /  2.  1.  0
  libswscale      3.  1.101 /  3.  1.101
  libswresample   1.  2.100 /  1.  2.100
  libpostproc    53.  3.100 / 53.  3.100
Input #0, rawvideo, from 'pipe:':
  Duration: N/A, start: 0.000000, bitrate: 246240 kb/s
    Stream #0:0: Video: rawvideo (BGR[24] / 0x18524742), bgr24, 600x342, 246240 kb/s, 50 tbr, 50 tbn, 50 tbc
[libx264 @ 0x7fa51c801200] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x7fa51c801200] profile High, level 3.1
[libx264 @ 0x7fa51c801200] 264 - core 146 r2555 0c21480 - H.264/MPEG-4 AVC codec - Copyleft 2003-2015 - http://www.videolan.org/x264.html - options: cabac=1 ref=2 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=6 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=12 lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=1 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=30 rc=crf mbtree=1 crf=18.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to '/var/folders/4t/my3vyzsx7pg80tc_cxhyfc7h0000gp/T/butterflow-0.1.9/t_ic2.mp4.1373342400.0.0.75.x.x.x.libx264.rnd.mp4':
  Metadata:
    encoder         : Lavf56.36.100
    Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 600x342, q=-1--1, 50 fps, 12800 tbn, 50 tbc
    Metadata:
      encoder         : Lavc56.41.100 libx264
Stream mapping:
  Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (libx264))
frame=  100 fps=4.8 q=-1.0 Lsize=     365kB time=00:00:01.96 bitrate=1526.7kbits/s
video:363kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.540821%
[libx264 @ 0x7fa51c801200] frame I:1     Avg QP:19.39  size: 39855
[libx264 @ 0x7fa51c801200] frame P:30    Avg QP:21.58  size:  6893
[libx264 @ 0x7fa51c801200] frame B:69    Avg QP:25.11  size:  1807
[libx264 @ 0x7fa51c801200] consecutive B-frames:  7.0%  2.0%  3.0% 88.0%
[libx264 @ 0x7fa51c801200] mb I  I16..4:  8.1% 42.5% 49.4%
[libx264 @ 0x7fa51c801200] mb P  I16..4:  2.5%  3.7%  1.8%  P16..4: 18.6% 10.6%  8.1%  0.0%  0.0%    skip:54.7%
[libx264 @ 0x7fa51c801200] mb B  I16..4:  2.5%  0.7%  1.4%  B16..8: 10.7%  2.0%  0.3%  direct: 4.2%  skip:78.2%  L0:33.6% L1:47.9% BI:18.5%
[libx264 @ 0x7fa51c801200] 8x8 transform intra:30.7% inter:51.5%
[libx264 @ 0x7fa51c801200] coded y,uvDC,uvAC intra: 39.5% 62.9% 50.5% inter: 7.3% 12.9% 8.3%
[libx264 @ 0x7fa51c801200] i16 v,h,dc,p: 61% 33%  5%  2%
[libx264 @ 0x7fa51c801200] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 29% 26% 23%  4%  2%  2%  5%  3%  7%
[libx264 @ 0x7fa51c801200] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 26% 33% 13%  5%  4%  3%  5%  4%  6%
[libx264 @ 0x7fa51c801200] i8c dc,h,v,p: 49% 35% 10%  6%
[libx264 @ 0x7fa51c801200] Weighted P-Frames: Y:6.7% UV:6.7%
[libx264 @ 0x7fa51c801200] ref P L0: 80.6% 19.4%
[libx264 @ 0x7fa51c801200] ref B L0: 87.6% 12.4%
[libx264 @ 0x7fa51c801200] ref B L1: 96.2%  3.8%
[libx264 @ 0x7fa51c801200] kb/s:1485.35
dthpham commented 9 years ago

I usually develop on Linux but the output that I posted above was created on OS X 10.10.4 with a bottled butterflow and it's dependencies all installed via Homebrew. I'm using butterflow-0.1.9, ffmpeg-2.7.2, and opencv-2.4.12.

dthpham commented 9 years ago

Can you upload the video that was output using the command I posted above?

zbeekman commented 9 years ago

I can't seem to figure out how you embedded it in the github comment window, but here is a link to the latest: https://obj.umiacs.umd.edu/public-test/out.mp4

Nebules commented 9 years ago

Also having the same issue: http://www.benbray.com/misc/out.mp4

bray$ butterflow -s a=1,b=3,spd=0.5 -l -t -vs 0.75 --no-preview "Sea Perch_.MOV"

ffmpeg version 2.6.3 Copyright (c) 2000-2015 the FFmpeg developers built with Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn) configuration: --prefix=/usr/local/Cellar/ffmpeg/2.6.3 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-libvorbis --enable-libass --enable-vda libavutil 54. 20.100 / 54. 20.100 libavcodec 56. 26.100 / 56. 26.100 libavformat 56. 25.101 / 56. 25.101 libavdevice 56. 4.100 / 56. 4.100 libavfilter 5. 11.102 / 5. 11.102 libavresample 2. 1. 0 / 2. 1. 0 libswscale 3. 1.101 / 3. 1.101 libswresample 1. 1.100 / 1. 1.100 libpostproc 53. 3.100 / 53. 3.100 Input #0, rawvideo, from 'pipe:': Duration: N/A, start: 0.000000, bitrate: 298299 kb/s Stream #0:0: Video: rawvideo (BGR[24] / 0x18524742), bgr24, 960x540, 298299 kb/s, 23.98 tbr, 23.98 tbn, 23.98 tbc [libx264 @ 0x7fad75001200] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX [libx264 @ 0x7fad75001200] profile High 4:4:4 Predictive, level 3.1, 4:2:0 8-bit [libx264 @ 0x7fad75001200] 264 - core 144 r2533 c8a773e - H.264/MPEG-4 AVC codec - Copyleft 2003-2015 - http://www.videolan.org/x264.html - options: cabac=1 ref=2 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=6 psy=0 mixed_ref=1 me_range=16 chroma_me=1 trellis=0 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=0 chroma_qp_offset=0 threads=12 lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=1 keyint=250 keyint_min=23 scenecut=40 intra_refresh=0 rc=cqp mbtree=0 qp=0 Output #0, mp4, to '/var/folders/m/q7dr1r5j397c3s2rf7jw3fy40000gn/T/butterflow-0.1.9/sea perch.mov.1439829770.0.0.75.x.x.l.libx264.rnd.mp4': Metadata: encoder : Lavf56.25.101 Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 960x540, q=-1--1, 23.98 fps, 11988 tbn, 23.98 tbc Metadata: encoder : Lavc56.26.100 libx264 Stream mapping: Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (libx264)) frame= 95 fps=1.9 q=-1.0 Lsize= 20131kB time=00:00:03.96 bitrate=41621.2kbits/s
video:20130kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.006991% [libx264 @ 0x7fad75001200] frame I:30 Avg QP: 0.00 size:180966 [libx264 @ 0x7fad75001200] frame P:65 Avg QP: 0.00 size:233592 [libx264 @ 0x7fad75001200] mb I I16..4: 52.5% 0.0% 47.5% [libx264 @ 0x7fad75001200] mb P I16..4: 33.4% 0.0% 42.5% P16..4: 12.4% 5.2% 4.9% 0.0% 0.0% skip: 1.5% [libx264 @ 0x7fad75001200] 8x8 transform intra:0.0% inter:80.3% [libx264 @ 0x7fad75001200] coded y,uvDC,uvAC intra: 87.4% 87.4% 87.4% inter: 93.6% 93.6% 93.6% [libx264 @ 0x7fad75001200] i16 v,h,dc,p: 38% 61% 1% 0% [libx264 @ 0x7fad75001200] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 29% 46% 2% 5% 4% 1% 8% 3% 2% [libx264 @ 0x7fad75001200] i8c dc,h,v,p: 13% 57% 30% 0% [libx264 @ 0x7fad75001200] Weighted P-Frames: Y:78.5% UV:56.9% [libx264 @ 0x7fad75001200] ref P L0: 70.2% 29.8% [libx264 @ 0x7fad75001200] kb/s:41617.19

zbeekman commented 9 years ago

@dthpham any thoughts?

dthpham commented 9 years ago

I haven't been able to recreate what you're getting on three separate platforms so it's difficult for me to say what the issue is and let alone try to fix it. If I was forced to guess I'd say it's a hardware/driver/opencl implementation problem but I'm not confident that's the case.

You might have better luck with the program under a different environment.

I've been working on packaging a portable version of butterflow for Windows and I think it's ready to be distributed. If you have access to a Windows machine (with a compatible CPU or graphics card) and want to give it a test run I could upload a preview version here for you to try. Let me know if you're interested in testing it out.

Otherwise, I'm going to take a second, much closer, look at this on my Mac this weekend.

zbeekman commented 9 years ago

Thanks so much, I really appreciate your help.

Personally, I suspect something is amiss with my environment, but I can't figure out how to debug that since my python-fu is lacking. Maybe a conflicting Homebrew package? A bad version of a dependency? Problems with my PATH or PYTHONPATH finding the wrong version of dependencies?

dthpham commented 9 years ago

I was always unclear about whether you installed ffmpeg by any other method than with homebrew or enabled some build options that I didn't anticipate. It's a a point of interest that I should give more consideration.

To rule out it's not a problem with ffmpeg and that butterflow is picking up the right one, can you please give me the output of the following:

  1. brew info butterflow ffmpeg opencv
  2. which ffmpeg
  3. ffmpeg -version
  4. butterflow -d

Whatever PYTHONPATH is set to shouldn't be an issue. The executable that launches butterflow sets it automatically so that all dependent python modules are picked up correctly.

Though a problem could arise if a module is a different version than what is expected and is known to work with butterflow. To make sure we're working with the same modules can you also give me the output of the following:

  1. which python
  2. python -c 'import numpy;print(numpy.__version__)'
  3. PYTHONPATH=$(brew --prefix)/opt/opencv/lib/python2.7/site-packages python -c 'import cv2;print(cv2.__version__)'

This information would make the differences between our environments clear and would be valuable to me while debugging.

Thanks.

zbeekman commented 9 years ago
  1. brew info butterflow ffmpeg opencv (Caveats and options elided)
$ brew info butterflow ffmpeg opencv
homebrew/science/butterflow: stable 0.1.9 (bottled)
Makes fluid slowmo and motion interpolated videos
https://github.com/dthpham/butterflow
/usr/local/homebrew/Cellar/butterflow/0.1.9_1 (28 files, 252K) *
  Poured from bottle
From: https://github.com/homebrew/homebrew-science/blob/master/butterflow.rb
==> Dependencies
Build: pkg-config ✔
Required: ffmpeg ✔, opencv ✔

ffmpeg: stable 2.7.2, HEAD
Play, record, convert, and stream audio and video
https://ffmpeg.org/
/usr/local/homebrew/Cellar/ffmpeg/2.7.2_1 (234 files, 44M) *
  Built from source with: --with-libvorbis --with-libass --with-faac --with-tools
From: https://github.com/Homebrew/homebrew/blob/master/Library/Formula/ffmpeg.rb
==> Dependencies
Build: pkg-config ✔, texi2html ✔, yasm ✔
Recommended: x264 ✔, lame ✔, libvo-aacenc ✔, xvid ✔
Optional: faac ✔, fontconfig ✔, freetype ✔, theora ✘, libvorbis ✔, libvpx ✘, rtmpdump ✘, opencore-amr ✘, libass ✔, openjpeg ✘, speex ✘, schroedinger ✘, fdk-aac ✘, opus ✘, frei0r ✘, libcaca ✘, libbluray ✘, libsoxr ✘, libquvi ✘, libvidstab ✘, x265 ✘, openssl ✘, libssh ✘, webp ✘, zeromq ✘

homebrew/science/opencv: stable 2.4.12, HEAD
Open source computer vision library
http://opencv.org/
/usr/local/homebrew/Cellar/opencv/2.4.12 (231 files, 36M) *
  Built from source with: --with-ffmpeg
From: https://github.com/homebrew/homebrew-science/blob/master/opencv.rb
==> Dependencies
Build: cmake ✔, pkg-config ✔
Required: jpeg ✔, libpng ✔, libtiff ✔
Recommended: eigen ✔, openexr ✔, homebrew/python/numpy ✔
Optional: gstreamer ✘, jasper ✘, libdc1394 ✘, openni ✘, qt ✘, tbb ✘, ffmpeg ✔
  1. which ffmpeg
$ ls -l $(which ffmpeg)
lrwxr-xr-x  1 ibeekman  wheel  44 Aug 17 13:13 /usr/local/bin/ffmpeg -> ../homebrew/Cellar/ffmpeg/2.7.2_1/bin/ffmpeg
  1. ffmpeg -version
$ ffmpeg -version
ffmpeg version 2.7.2 Copyright (c) 2000-2015 the FFmpeg developers
built with Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
configuration: --prefix=/usr/local/homebrew/Cellar/ffmpeg/2.7.2_1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-libvorbis --enable-libfaac --enable-libass --enable-nonfree --enable-vda
libavutil      54. 27.100 / 54. 27.100
libavcodec     56. 41.100 / 56. 41.100
libavformat    56. 36.100 / 56. 36.100
libavdevice    56.  4.100 / 56.  4.100
libavfilter     5. 16.101 /  5. 16.101
libavresample   2.  1.  0 /  2.  1.  0
libswscale      3.  1.101 /  3.  1.101
libswresample   1.  2.100 /  1.  2.100
libpostproc    53.  3.100 / 53.  3.100
  1. butterflow -d
$ butterflow -d
OpenCL devices:
  Platform              : Apple
  Platform Vendor       : Apple
  Platform Version      : OpenCL 1.2 (May 10 2015 19:38:45)
    Device          : Intel(R) Core(TM) i7-2760QM CPU @ 2.40GHz
      Version       : OpenCL 1.2
      Version       : 1.1
    Device          : ATI Radeon HD 6770M
      Version       : OpenCL 1.2
      Version       : 1.2 (Jul 29 2015 02:43:14)
  1. which python
$ ls -l $(which python)
lrwxr-xr-x  1 ibeekman  wheel  42 Jun  8 20:26 /usr/local/bin/python -> ../homebrew/Cellar/python/2.7.9/bin/python
  1. python -c 'import numpy;print(numpy.__version__)'
$ python -c 'import numpy;print(numpy.__version__)'
1.9.2
  1. PYTHONPATH=$(brew --prefix)/opt/opencv/lib/python2.7/site-packages python -c 'import cv2;print(cv2.__version__)'
$ PYTHONPATH=$(brew --prefix)/opt/opencv/lib/python2.7/site-packages python -c 'import cv2;print(cv2.__version__)'
2.4.12
jasalt commented 9 years ago

Facing same here as zbeekman. Thank's a lot for the development & debugging effort!

Here's my program output:

$ butterflow -tt stroke -a -r50 -t -s a=16,b=18,spd=1 -vs 0.75 t_ic2.mp4
ffmpeg version 2.7.2 Copyright (c) 2000-2015 the FFmpeg developers
  built with Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
  configuration: --prefix=/usr/local/Cellar/ffmpeg/2.7.2_1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libass --enable-openssl --enable-nonfree --enable-vda
  libavutil      54. 27.100 / 54. 27.100
  libavcodec     56. 41.100 / 56. 41.100
  libavformat    56. 36.100 / 56. 36.100
  libavdevice    56.  4.100 / 56.  4.100
  libavfilter     5. 16.101 /  5. 16.101
  libavresample   2.  1.  0 /  2.  1.  0
  libswscale      3.  1.101 /  3.  1.101
  libswresample   1.  2.100 /  1.  2.100
  libpostproc    53.  3.100 / 53.  3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 't_ic2.mp4':
  Metadata:
    major_brand     : mp42
    minor_version   : 1
    compatible_brands: mp42avc1
    creation_time   : 2011-06-25 22:02:21
  Duration: 00:00:57.40, start: 0.000000, bitrate: 2386 kb/s
    Stream #0:0(eng): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, smpte170m/smpte170m/bt709), 800x456, 2385 kb/s, 10 fps, 10 tbr, 600 tbn, 1200 tbc (default)
    Metadata:
      creation_time   : 2011-06-25 22:02:21
      handler_name    : Apple Video Media Handler
[libx264 @ 0x7feb55013400] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x7feb55013400] profile High, level 4.2
[libx264 @ 0x7feb55013400] 264 - core 146 r2555 0c21480 - H.264/MPEG-4 AVC codec - Copyleft 2003-2015 - http://www.videolan.org/x264.html - options: cabac=1 ref=2 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=6 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=12 lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=1 keyint=250 keyint_min=10 scenecut=40 intra_refresh=0 rc_lookahead=30 rc=crf mbtree=1 crf=18.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to '/var/folders/g4/qcnfgwnx6n1c_v1lnp01p4lw0000gn/T/butterflow-0.1.9/~t_ic2.mp4.1441308844.0.0.75.x.x.x.libx264.nrm.mp4':
  Metadata:
    major_brand     : mp42
    minor_version   : 1
    compatible_brands: mp42avc1
    encoder         : Lavf56.36.100
    Stream #0:0(eng): Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 600x342, q=-1--1, 10 fps, 10240 tbn, 10 tbc (default)
    Metadata:
      creation_time   : 2011-06-25 22:02:21
      handler_name    : Apple Video Media Handler
      encoder         : Lavc56.41.100 libx264
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Press [q] to stop, [?] for help
frame=  134 fps=0.0 q=20.0 size=     492kB time=00:00:08.60 bitrate= 469.0kbits/s   frame=  233 fps=232 q=20.0 size=    1206kB time=00:00:18.50 bitrate= 533.8kbits/s   frame=  329 fps=218 q=20.0 size=    2155kB time=00:00:28.10 bitrate= 628.2kbits/s   frame=  417 fps=207 q=20.0 size=    3072kB time=00:00:36.90 bitrate= 682.0kbits/s   frame=  508 fps=202 q=20.0 size=    4086kB time=00:00:46.00 bitrate= 727.6kbits/s   frame=  574 fps=186 q=-1.0 Lsize=    5372kB time=00:00:57.20 bitrate= 769.4kbits/s
video:5369kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.062077%
[libx264 @ 0x7feb55013400] frame I:3     Avg QP:11.45  size: 36198
[libx264 @ 0x7feb55013400] frame P:558   Avg QP:15.31  size:  9599
[libx264 @ 0x7feb55013400] frame B:13    Avg QP:18.02  size:  2488
[libx264 @ 0x7feb55013400] consecutive B-frames: 96.9%  0.0%  1.0%  2.1%
[libx264 @ 0x7feb55013400] mb I  I16..4: 31.9% 22.0% 46.1%
[libx264 @ 0x7feb55013400] mb P  I16..4:  1.5%  1.2%  0.5%  P16..4: 18.2% 15.2% 13.0%  0.0%  0.0%    skip:50.4%
[libx264 @ 0x7feb55013400] mb B  I16..4:  0.6%  0.1%  0.1%  B16..8: 19.1%  9.4%  1.8%  direct: 6.7%  skip:62.2%  L0:33.1% L1:42.9% BI:24.0%
[libx264 @ 0x7feb55013400] 8x8 transform intra:35.3% inter:46.6%
[libx264 @ 0x7feb55013400] coded y,uvDC,uvAC intra: 22.6% 74.2% 70.2% inter: 23.7% 36.2% 30.6%
[libx264 @ 0x7feb55013400] i16 v,h,dc,p: 66% 31%  3%  0%
[libx264 @ 0x7feb55013400] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu:  8% 12% 68%  2%  2%  2%  2%  2%  2%
[libx264 @ 0x7feb55013400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 26% 36% 23%  2%  3%  2%  3%  3%  3%
[libx264 @ 0x7feb55013400] i8c dc,h,v,p: 52% 33% 11%  4%
[libx264 @ 0x7feb55013400] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0x7feb55013400] ref P L0: 91.1%  8.9%
[libx264 @ 0x7feb55013400] ref B L0: 94.5%  5.5%
[libx264 @ 0x7feb55013400] ref B L1: 97.3%  2.7%
[libx264 @ 0x7feb55013400] kb/s:766.17
ffmpeg version 2.7.2 Copyright (c) 2000-2015 the FFmpeg developers
  built with Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
  configuration: --prefix=/usr/local/Cellar/ffmpeg/2.7.2_1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libass --enable-openssl --enable-nonfree --enable-vda
  libavutil      54. 27.100 / 54. 27.100
  libavcodec     56. 41.100 / 56. 41.100
  libavformat    56. 36.100 / 56. 36.100
  libavdevice    56.  4.100 / 56.  4.100
  libavfilter     5. 16.101 /  5. 16.101
  libavresample   2.  1.  0 /  2.  1.  0
  libswscale      3.  1.101 /  3.  1.101
  libswresample   1.  2.100 /  1.  2.100
  libpostproc    53.  3.100 / 53.  3.100
Input #0, rawvideo, from 'pipe:':
  Duration: N/A, start: 0.000000, bitrate: 246240 kb/s
    Stream #0:0: Video: rawvideo (BGR[24] / 0x18524742), bgr24, 600x342, 246240 kb/s, 50 tbr, 50 tbn, 50 tbc
[libx264 @ 0x7fd98d81ea00] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x7fd98d81ea00] profile High, level 3.1
[libx264 @ 0x7fd98d81ea00] 264 - core 146 r2555 0c21480 - H.264/MPEG-4 AVC codec - Copyleft 2003-2015 - http://www.videolan.org/x264.html - options: cabac=1 ref=2 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=6 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=12 lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=1 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=30 rc=crf mbtree=1 crf=18.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to '/var/folders/g4/qcnfgwnx6n1c_v1lnp01p4lw0000gn/T/butterflow-0.1.9/t_ic2.mp4.1441308844.0.0.75.x.x.x.libx264.rnd.mp4':
  Metadata:
    encoder         : Lavf56.36.100
    Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 600x342, q=-1--1, 50 fps, 12800 tbn, 50 tbc
    Metadata:
      encoder         : Lavc56.41.100 libx264
Stream mapping:
  Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (libx264))
frame=   50 fps=4.5 q=26.0 size=      73kB time=00:00:00.04 bitrate=14890.0kbits/s  frame=   55 fps=4.5 q=26.0 size=      79kB time=00:00:00.14 bitrate=4636.1kbits/s   frame=   60 fps=4.5 q=26.0 size=      86kB time=00:00:00.24 bitrate=2934.1kbits/s   frame=   64 fps=4.4 q=26.0 size=     120kB time=00:00:00.32 bitrate=3069.0kbits/s   frame=   69 fps=4.5 q=26.0 size=     153kB time=00:00:00.42 bitrate=2988.5kbits/s   frame=   74 fps=4.5 q=26.0 size=     179kB time=00:00:00.52 bitrate=2814.6kbits/s   frame=   79 fps=4.5 q=26.0 size=     192kB time=00:00:00.62 bitrate=2534.8kbits/s   frame=   83 fps=4.4 q=26.0 size=     209kB time=00:00:00.70 bitrate=2441.5kbits/s   frame=   88 fps=4.4 q=26.0 size=     256kB time=00:00:00.80 bitrate=2622.3kbits/s   frame=   93 fps=4.4 q=26.0 size=     302kB time=00:00:00.90 bitrate=2746.3kbits/s   frame=  100 fps=4.7 q=-1.0 Lsize=     569kB time=00:00:01.96 bitrate=2380.1kbits/s
video:567kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.347615%
[libx264 @ 0x7fd98d81ea00] frame I:1     Avg QP:20.83  size: 36943
[libx264 @ 0x7fd98d81ea00] frame P:35    Avg QP:21.92  size:  5667
[libx264 @ 0x7fd98d81ea00] frame B:64    Avg QP:24.46  size:  5392
[libx264 @ 0x7fd98d81ea00] consecutive B-frames:  9.0% 12.0% 15.0% 64.0%
[libx264 @ 0x7fd98d81ea00] mb I  I16..4:  9.2% 44.1% 46.7%
[libx264 @ 0x7fd98d81ea00] mb P  I16..4:  1.3%  2.8%  1.0%  P16..4: 20.8%  9.4%  7.8%  0.0%  0.0%    skip:56.9%
[libx264 @ 0x7fd98d81ea00] mb B  I16..4: 11.9%  3.0%  3.0%  B16..8: 10.3%  3.8%  0.8%  direct:16.6%  skip:50.8%  L0:29.8% L1:55.8% BI:14.5%
[libx264 @ 0x7fd98d81ea00] 8x8 transform intra:23.4% inter:57.7%
[libx264 @ 0x7fd98d81ea00] coded y,uvDC,uvAC intra: 29.3% 46.4% 33.6% inter: 14.6% 28.0% 18.2%
[libx264 @ 0x7fd98d81ea00] i16 v,h,dc,p: 62% 32%  4%  2%
[libx264 @ 0x7fd98d81ea00] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 18% 30% 30%  4%  3%  2%  5%  3%  6%
[libx264 @ 0x7fd98d81ea00] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 23% 32% 19%  4%  4%  3%  6%  4%  6%
[libx264 @ 0x7fd98d81ea00] i8c dc,h,v,p: 55% 32%  9%  4%
[libx264 @ 0x7fd98d81ea00] Weighted P-Frames: Y:8.6% UV:8.6%
[libx264 @ 0x7fd98d81ea00] ref P L0: 82.1% 17.9%
[libx264 @ 0x7fd98d81ea00] ref B L0: 73.5% 26.5%
[libx264 @ 0x7fd98d81ea00] ref B L1: 95.0%  5.0%
[libx264 @ 0x7fd98d81ea00] kb/s:2321.65
$ butterflow -d
OpenCL devices:
  Platform              : Apple
  Platform Vendor       : Apple
  Platform Version      : OpenCL 1.2 (May 10 2015 19:38:45)
    Device          : Intel(R) Core(TM) i7-2760QM CPU @ 2.40GHz
      Version       : OpenCL 1.2
      Version       : 1.1
    Device          : ATI Radeon HD 6770M
      Version       : OpenCL 1.2
      Version       : 1.2 (Jul 29 2015 02:43:14)

Got same output as zbeekman for other commands too.

dthpham commented 9 years ago

Thanks for the outputs fellas.

@zbeekman

The differences that I could discern between us is that:

  1. I'm using the system's python 2.7.6 while you're using a brewed python 2.7.9.
  2. I'm using the system's numpy 1.8.0rc1 while you're using a brewed numpy 1.9.2
  3. I'm using a bottled ffmpeg while you're using one that was built from source with additional options enabled (--with-faac --with-tools)
  4. We're using different graphics devices

So even after switching to a brewed python, numpy, and building ffmpeg with the same options, I still wasn't able to replicate this issue.

What I'm working with now:

  1. brew info butterflow
homebrew/science/butterflow: stable 0.1.9 (bottled)
Makes fluid slowmo and motion interpolated videos
https://github.com/dthpham/butterflow
/usr/local/Cellar/butterflow/0.1.9_1 (28 files, 252K) *
  Poured from bottle
From: https://github.com/homebrew/homebrew-science/blob/master/butterflow.rb
==> Dependencies
Build: pkg-config ✔
Required: ffmpeg ✔, opencv ✔
  1. brew info ffmpeg
ffmpeg: stable 2.7.2 (bottled), HEAD
Play, record, convert, and stream audio and video
https://ffmpeg.org/
/usr/local/Cellar/ffmpeg/2.7.2_1 (234 files, 44M) *
  Built from source with: --with-libvorbis --with-libass --with-faac --with-tools
From: https://github.com/Homebrew/homebrew/blob/master/Library/Formula/ffmpeg.rb
==> Dependencies
Build: pkg-config ✔, texi2html ✔, yasm ✔
Recommended: x264 ✔, lame ✔, libvo-aacenc ✔, xvid ✔
Optional: faac ✔, fontconfig ✔, freetype ✔, theora ✘, libvorbis ✔, libvpx ✘, rtmpdump ✘, opencore-amr ✘, libass ✔, openjpeg ✘, speex ✘, schroedinger ✘, fdk-aac ✘, opus ✘, frei0r ✘, libcaca ✘, libbluray ✘, libsoxr ✘, libquvi ✘, libvidstab ✘, x265 ✘, openssl ✔, libssh ✘, webp ✘, zeromq ✘
  1. brew info opencv
homebrew/science/opencv: stable 2.4.12 (bottled), HEAD
Open source computer vision library
http://opencv.org/
/usr/local/Cellar/opencv/2.4.12 (225 files, 36M) *
  Built from source with: --with-ffmpeg
From: https://github.com/homebrew/homebrew-science/blob/master/opencv.rb
==> Dependencies
Build: cmake ✔, pkg-config ✔
Required: jpeg ✔, libpng ✔, libtiff ✔
Recommended: eigen ✔, openexr ✔, homebrew/python/numpy ✔
Optional: gstreamer ✘, jasper ✘, libdc1394 ✘, openni ✘, qt ✘, tbb ✘, ffmpeg ✔
  1. ffmpeg -version
ffmpeg version 2.7.2 Copyright (c) 2000-2015 the FFmpeg developers
built with Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
configuration: --prefix=/usr/local/Cellar/ffmpeg/2.7.2_1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-libvorbis --enable-libfaac --enable-libass --enable-nonfree --enable-vda
libavutil      54. 27.100 / 54. 27.100
libavcodec     56. 41.100 / 56. 41.100
libavformat    56. 36.100 / 56. 36.100
libavdevice    56.  4.100 / 56.  4.100
libavfilter     5. 16.101 /  5. 16.101
libavresample   2.  1.  0 /  2.  1.  0
libswscale      3.  1.101 /  3.  1.101
libswresample   1.  2.100 /  1.  2.100
libpostproc    53.  3.100 / 53.  3.100
  1. ls -l $(which python)
lrwxr-xr-x  1 dthpham  admin    36B Sep  4 17:40 /usr/local/bin/python@ -> ../Cellar/python/2.7.10_2/bin/python
  1. env | grep PATH
PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin

This is what I did to set up for testing and it would be great if you could do the same and report back if anything has changed:

brew uninstall butterflow
brew uninstall ffmpeg --force
brew uninstall opencv --force
brew update
brew upgrade
brew install ffmpeg --with-libvorbis --with-libass
brew install opencv --with-ffmpeg
brew install butterflow
butterflow -tt stroke -a -r50 -t -s a=16,b=18,spd=1 -vs 0.75 <video>
jasalt commented 9 years ago

Ran the given commands and did note a warning:

$ brew install opencv --with-ffmpeg
==> Installing opencv from homebrew/homebrew-science
==> Using Homebrew-provided fortran compiler.
This may be changed by setting the FC environment variable.
==> Downloading https://github.com/Itseez/opencv/archive/2.4.12.tar.gz
Already downloaded: /Library/Caches/Homebrew/opencv-2.4.12.tar.gz
==> cmake .. -DCMAKE_C_FLAGS_RELEASE= -DCMAKE_CXX_FLAGS_RELEASE= -DCMAKE_INSTA
==> make
==> make install
Warning: homebrew/science/opencv dependency gcc was built with a different C++ standard
library (libstdc++ from clang). This may cause problems at runtime.
🍺  /usr/local/Cellar/opencv/2.4.12: 225 files, 36M, built in 5.6 minutes

Output seems like previously. Output video

dthpham commented 9 years ago

Thanks. That warning is safe to ignore.

zbeekman commented 9 years ago

I uninstalled and reinstalled ffmpeg, butterflow, and opencv according to your directions, and also made sure my path matched yours and I'm still having issues. As a last ditch effort, I'm going to make sure that my optional/recommended packages match yours too, and if that doesn't solve the issue, then I'll chalk it up to a hardware difference.

jasalt commented 9 years ago

zbeekman: as a workaround for this Macbook bug, you can now run this on Ubuntu 15.04 virtual machine. No ugly frames anymore, but it can utilize only the CPU. See https://github.com/dthpham/butterflow/issues/6.

zbeekman commented 8 years ago

My MBP had a hardware failure (and is being fixed) but in the meantime I have a loaner with a virginal El Capitan install. Things work as expected on this system. I'm thinking my machine is borked in some way. brew doctor lists a lot of stuff, so when I get my personal laptop back, I may upgrade to El Capitan and am expecting that things should work as expected then. If this is the case, I'll close this issue.

lgarczyn commented 7 years ago

Hi, I get the exact same issue. The number of broken frames varies depending on the original file's encoding (-crf 23 had a lot more than -crf 0), but I can't find any other links.

At a glance, frames are usually green, red, yellow, magenta or white, indicating in 1 to 3 lost channels. The lost channels are fully white.

I could not reproduce this on monochromatic sprites.

I had a lot of trouble installing opencv due to a missing Python.h, and had to brew edit in my Python path, instead of using the python-config --prefix.

here's four test videos: https://s3-eu-west-1.amazonaws.com/omniview-experience-bucket/public/test.mp4 https://s3-eu-west-1.amazonaws.com/omniview-experience-bucket/public/test_inter.mp4 https://s3-eu-west-1.amazonaws.com/omniview-experience-bucket/public/video.mp4 https://s3-eu-west-1.amazonaws.com/omniview-experience-bucket/public/video_inter.mp4

the command to go from test.mp4 to test_inter.mp4 (and video.mp4 to video_inter.mp4) was: butterflow test.mp4 -r 2x -o test_inter.mp4 -l -sm

video.mp4 was created from separated frames from test.mp4, and put back together at a different speed and encoding. It should just be a slower version (2fps) with lots of lost frames.

homebrew/science/butterflow: stable 0.2.1 Makes fluid slow motion and motion interpolated videos https://github.com/dthpham/butterflow /Users/lgarczyn/.brew/Cellar/butterflow/0.2.1 (32 files, 191.1K) * Built from source on 2017-01-25 at 17:56:31 From: https://github.com/Homebrew/homebrew-science/blob/master/butterflow.rb ==> Dependencies Required: ffmpeg ✔, opencv --with-ffmpeg --with-opengl ✔ ==> Requirements Required: macOS >= 10.9 ✔

ffmpeg: stable 3.2.2, HEAD Play, record, convert, and stream audio and video https://ffmpeg.org/ /Users/lgarczyn/.brew/Cellar/ffmpeg/3.2.2 (239 files, 51.3M) * Built from source on 2017-01-09 at 16:59:34 with: --with-libvpx --with-libvorbis From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/ffmpeg.rb ==> Dependencies Build: pkg-config ✔, texi2html ✔, yasm ✔ Recommended: lame ✔, x264 ✔, xvid ✔ Optional: chromaprint ✘, fdk-aac ✘, fontconfig ✘, freetype ✔, frei0r ✘, game-music-emu ✘, libass ✘, libbluray ✘, libbs2b ✘, libcaca ✘, libebur128 ✘, libgsm ✘, libmodplug ✘, libsoxr ✘, libssh ✘, libvidstab ✘, libvorbis ✔, libvpx ✔, opencore-amr ✘, openh264 ✘, openjpeg ✘, openssl ✔, opus ✘, rtmpdump ✘, rubberband ✘, schroedinger ✘, sdl2 ✘, snappy ✘, speex ✘, tesseract ✘, theora ✘, two-lame ✘, wavpack ✘, webp ✘, x265 ✘, xz ✘, zeromq ✘, zimg ✘ ==> Options --with-chromaprint Enable the Chromaprint audio fingerprinting library --with-fdk-aac Enable the Fraunhofer FDK AAC library --with-fontconfig Build with fontconfig support --with-freetype Build with freetype support --with-frei0r Build with frei0r support --with-game-music-emu Build with game-music-emu support --with-libass Enable ASS/SSA subtitle format --with-libbluray Build with libbluray support --with-libbs2b Build with libbs2b support --with-libcaca Build with libcaca support --with-libebur128 Enable using libebur128 for EBU R128 loudness measurement --with-libgsm Build with libgsm support --with-libmodplug Build with libmodplug support --with-libsoxr Enable the soxr resample library --with-libssh Enable SFTP protocol via libssh --with-libvidstab Enable vid.stab support for video stabilization --with-libvorbis Build with libvorbis support --with-libvpx Build with libvpx support --with-opencore-amr Enable Opencore AMR NR/WB audio format --with-openh264 Enable OpenH264 library --with-openjpeg Enable JPEG 2000 image format --with-openssl Enable SSL support --with-opus Build with opus support --with-rtmpdump Enable RTMP protocol --with-rubberband Enable rubberband library --with-schroedinger Enable Dirac video format --with-sdl2 Enable FFplay media player --with-snappy Enable Snappy library --with-speex Build with speex support --with-tesseract Enable the tesseract OCR engine --with-theora Build with theora support --with-tools Enable additional FFmpeg tools --with-two-lame Build with two-lame support --with-wavpack Build with wavpack support --with-webp Enable using libwebp to encode WEBP images --with-x265 Enable x265 encoder --with-xz Enable decoding of LZMA-compressed TIFF files --with-zeromq Enable using libzeromq to receive commands sent through a libzeromq client --with-zimg Enable z.lib zimg library --without-lame Disable MP3 encoder --without-qtkit Disable deprecated QuickTime framework --without-securetransport Disable use of SecureTransport --without-x264 Disable H.264 encoder --without-xvid Disable Xvid MPEG-4 video encoder --HEAD Install HEAD version

homebrew/science/opencv: stable 2.4.13.2, HEAD Open source computer vision library http://opencv.org/ /Users/lgarczyn/.brew/Cellar/opencv/2.4.13.2 (278 files, 35.3M) * Built from source on 2017-01-25 at 17:44:45 with: --with-ffmpeg --with-opengl From: https://github.com/Homebrew/homebrew-science/blob/master/opencv.rb ==> Dependencies Build: cmake ✔, pkg-config ✔ Required: jpeg ✔, libpng ✔, libtiff ✔ Recommended: eigen ✔, openexr ✔, numpy ✔ Optional: jasper ✘, gstreamer ✘, libdc1394 ✘, openni ✘, tbb ✘, vtk ✘, ffmpeg ✔ ==> Requirements Optional: cuda ✘, java ✔ ==> Options --c++11 Build using C++11 mode --universal Build a universal binary --with-cuda Build with cuda support --with-ffmpeg Build with ffmpeg support --with-gstreamer Build with gstreamer support --with-jasper Build with jasper support --with-java Build with Java support --with-libdc1394 Build with libdc1394 support --with-opengl Build with OpenGL support --with-openni Build with openni support --with-tbb Enable parallel code in OpenCV using Intel TBB --with-vtk Build with vtk support --with-ximea Build with XIMEA support --without-eigen Build without eigen support --without-numpy Use your own numpy instead of Homebrew's numpy --without-opencl Disable GPU code in OpenCV using OpenCL --without-openexr Build without openexr support --without-python Build without python support --without-test Build without accuracy and performance tests --HEAD Install HEAD version

/Users/lgarczyn/.brew/bin/ffmpeg

ffmpeg version 3.2.2 Copyright (c) 2000-2016 the FFmpeg developers built with Apple LLVM version 8.0.0 (clang-800.0.42.1) configuration: --prefix=/Users/lgarczyn/.brew/Cellar/ffmpeg/3.2.2 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-libmp3lame --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid --enable-opencl --disable-lzma --enable-vda libavutil 55. 34.100 / 55. 34.100 libavcodec 57. 64.101 / 57. 64.101 libavformat 57. 56.100 / 57. 56.100 libavdevice 57. 1.100 / 57. 1.100 libavfilter 6. 65.100 / 6. 65.100 libavresample 3. 1. 0 / 3. 1. 0 libswscale 4. 2.100 / 4. 2.100 libswresample 2. 3.100 / 2. 3.100 libpostproc 54. 1.100 / 54. 1.100

OpenCL devices: Platform : Apple Platform Vendor : Apple Platform Version : OpenCL 1.2 (Oct 14 2016 20:26:22) Device : Intel(R) Core(TM) i5-6500 CPU @ 3.20GHz Version : OpenCL 1.2 Version : 1.1 Device : AMD Radeon R9 M380 Compute Engine Version : OpenCL 1.2 Version : 1.2 (Oct 19 2016 21:05:08)

brew doctor warns that Python is installed at /Library/Frameworks/Python.framework, which is wrong, that Cellar and TEMP are on different drives (I have to), and that the Homebrew prefix is not /usr/local/ on which I don't have a choice either.

dthpham commented 7 years ago

@lgarczyn Thanks for your report. I'm still unable to reproduce this on my machine so I can't debug this as well as I can with other issues. It's probably a a driver problem, an OpenCL implementation problem. I've noticed that @jasalt, @zbeekman, and you are all using an AMD device. Maybe that's the problem? The broken frames went away when @zbeekman switched to the Intel CPU. Anyways, to rule out FFMPEG, can you tell me if you can see broken frames when using the --show-preview option? That way we can see if the rendered frame is broken before or after it gets sent to the video writer.

zbeekman commented 7 years ago

Just, FYI I thought both of my machines were intel CPUs.... but the one with the bad frames is an AMD/ATI GPU and the one that works is NVIDIA GPU... at any rate, the other machine has some other serious issues and is nearing retirement. (Both MacBook Pros...)

On Thu, Jan 26, 2017 at 8:24 AM dthpham notifications@github.com wrote:

@lgarczyn https://github.com/lgarczyn Thanks for your report. I'm still unable to reproduce this on my machine so I can't debug this as well as I can with other issues. It's probably a a driver problem, an OpenCL implementation problem. I've noticed that @jasalt https://github.com/jasalt, @zbeekman https://github.com/zbeekman, and you are all using an AMD device. Maybe that's the problem? The broken frames went away when @zbeekman https://github.com/zbeekman switched to the Intel CPU. Anyways, to rule out FFMPEG, can you tell me if you can see broken frames when using the --show-preview option? That way we can see if the rendered frame is broken before or after it gets sent to the video writer.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/dthpham/butterflow/issues/11#issuecomment-275387150, or mute the thread https://github.com/notifications/unsubscribe-auth/AAREPApOvCmn5Q3xg9ushtmeySS14HlOks5rWJ6CgaJpZM4FgYJ2 .

lgarczyn commented 7 years ago

I'll check with the same env on an nvidia card, see if it change anything.

alantor commented 7 years ago

I am having a similar issue. You can see my input and output files here:

http://alan-torres.com/post/video/butterflow/butterflow_input_23.98fps.mov http://alan-torres.com/post/video/butterflow/butterflow_output_60fps_AMD.mp4

I installed butterflow from homebrew. The GPU on my MacPro is an AMD FirePro D300 2048 MB

I also tried processing the same input file using my MacBook which has a Intel HD Graphics 5300 1536 MB GPU and I did not get any of the monochromatic frames.

http://alan-torres.com/post/video/butterflow/butterflow_output_60fps_Intel.mp4

However, on both machines I got the following message right when butterflow finished processing:

[butterflow:WARNING]: Dropping S243