Skip to content

Additional frame created with tensorflow_stream example #207

Open

Description

@elemakil

When I process an input file using the tensorflow_stream example (without applying "deepdream") the resulting output file has one extra frame. This occurs for video files of different lenght (tested with 1 sec, 10 sec, 1min, 10min). I inspect the number of frames in the input/output video using the command

ffprobe -v error -select_streams v:0 -show_entries stream=nb_frames -of default=nokey=1:noprint_wrappers=1 video.mp4

Output of ffmpeg -version:

ffmpeg version n4.1.3 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 8.2.1 (GCC) 20181127
configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libjack --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxml2 --enable-libxvid --enable-nvdec --enable-nvenc --enable-omx --enable-shared --enable-version3
libavutil      56. 22.100 / 56. 22.100
libavcodec     58. 35.100 / 58. 35.100
libavformat    58. 20.100 / 58. 20.100
libavdevice    58.  5.100 / 58.  5.100
libavfilter     7. 40.101 /  7. 40.101
libswscale      5.  3.100 /  5.  3.100
libswresample   3.  3.100 /  3.  3.100
libpostproc    55.  3.100 / 55.  3.100

Activity

  1. RomanSteinberg commented on May 24, 2019

    @RomanSteinberg

    Hi @elemakil
    My guess is that you counted frame which has no bytes actually. Anyway, you'd better provide the code snippet for counting those frames.

  2. elemakil commented on May 24, 2019

    @elemakil
    Author

    There's no code snippet from my side. I am using the tensorflow_stream example and I count the frames using ffprobe (check my original post for command).

  3. kkroening commented on Jun 3, 2019

    @kkroening
    Owner

    Hmm, interesting. Marking as bug. Thanks for reporting.

  4. elemakil commented on Jun 14, 2019

    @elemakil
    Author

    I figured out how to get rid of the extra frame - at least according to the nb_frames key of ffprobe. By adding vsync='0' to the output of the ffmpeg reader process, video file created by the writer process will have the same number of frames as the input file. Unfortunately I can't test this using a range of video files, but at the very least this resolves the problem on my one input file :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions