[FFmpeg-user] Questions about "Cannot allocate memory"
Mark Filipak (ffmpeg)
markfilipak at bog.us
Mon Feb 1 03:28:46 EET 2021
"Error while filtering: Cannot allocate memory
"Failed to inject frame into filter network: Cannot allocate memory
"Error while processing the decoded data for stream #0:0
"Conversion failed!"
In lines like this:
"frame= 1588 fps=0.5 q=22.4 size= 23296kB time=00:01:06.02 bitrate=2890.3kbits/s speed=0.0225x"
Regarding "frame=":
Why are many frame numbers repeated?
Why are many frame numbers skipped?
How can a particular frame number appear twice with 2 different PTSs?
Regarding "size=...kB":
Why does "size=...kB" only increase?
If it is cummulative, why is it cummulative?
If it is cummulative to indicate buffering, why doesn't it ever decrease?
If it is important, why isn't it in 'bytes' instead of 'kB'?
And in lines like this:
"[matroska @ 000001f9e7236480] Starting new cluster due to timestamp"
Why are new clusters started? What causes it?
In this context, what is a cluster?
What does "due to timestamp" really mean? Are there timestamp errors?
===== BEGIN ABBREVIATED, ANNOTATED REPORT =====
ffmpeg started on 2021-01-31 at 05:40:19
Report written to "ffmpeg-20210131-054019.log"
Log level: 32
Command line:
ffmpeg -i "THE LAST EMPEROR [1987] source part5.mkv" -map 0 -filter_complex
"minterpolate=fps=48000/1001:mi_mode=mci:mc_mode=obmc:scd=fdiff:scd_threshold=10:vsbmc=1:search_param=32,
telecine=pattern=3322,pp=linblenddeint, setpts=N*1001/60000/TB" -codec:v libx265 -x265-params
"crf=20:qcomp=0.60" -codec:a copy -codec:s copy "THE LAST EMPEROR [1987] part5.mkv"
ffmpeg version N-100851-g9f38fac053 Copyright (c) 2000-2021 the FFmpeg developers
built with gcc 9.3-win32 (GCC) 20200320
configuration: --prefix=/ffbuild/prefix --pkg-config-flags=--static --pkg-config=pkg-config
--cross-prefix=x86_64-w64-mingw32- --arch=x86_64 --target-os=mingw32 --enable-gpl --enable-version3
--disable-debug --disable-w32threads --enable-pthreads --enable-iconv --enable-zlib --enable-libxml2
--enable-libfreetype --enable-libfribidi --enable-gmp --enable-lzma --enable-fontconfig
--enable-opencl --enable-libvmaf --enable-vulkan --enable-libvorbis --enable-amf --enable-libaom
--enable-avisynth --enable-libdav1d --enable-libdavs2 --enable-ffnvcodec --enable-cuda-llvm
--enable-libglslang --enable-libass --enable-libbluray --enable-libmp3lame --enable-libopus
--enable-libtheora --enable-libvpx --enable-libwebp --enable-libmfx --enable-libopencore-amrnb
--enable-libopencore-amrwb --enable-libopenjpeg --enable-librav1e --enable-librubberband
--enable-schannel --enable-sdl2 --enable-libsoxr --enable-libsrt --enable-libsvtav1
--enable-libtwolame --enable-libuavs3d --enable-libvidstab --enable-libx264 --enable-libx26
libavutil 56. 64.100 / 56. 64.100
libavcodec 58.119.100 / 58.119.100
libavformat 58. 65.101 / 58. 65.101
libavdevice 58. 11.103 / 58. 11.103
libavfilter 7.100.100 / 7.100.100
libswscale 5. 8.100 / 5. 8.100
libswresample 3. 8.100 / 3. 8.100
libpostproc 55. 8.100 / 55. 8.100
[matroska,webm @ 000001f9e5cc6500] Could not find codec parameters for stream 3 (Subtitle:
hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' (0) and 'probesize' (5000000) options
Input #0, matroska,webm, from 'THE LAST EMPEROR [1987] source part5.mkv':
Metadata:
encoder : libebml v1.4.0 + libmatroska v1.6.2
creation_time : 2021-01-31T10:27:14.000000Z
Duration: 00:30:58.75, start: 0.083000, bitrate: 26470 kb/s
Stream #0:0: Video: h264 (High), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9],
23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
Metadata:
BPS-eng : 24224255
DURATION-eng : 00:30:58.649000000
NUMBER_OF_FRAMES-eng: 44563
NUMBER_OF_BYTES-eng: 5628048550
_STATISTICS_WRITING_APP-eng: mkvmerge v51.0.0 ('I Wish') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2021-01-31 10:27:14
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:1(eng): Audio: dts (DTS-HD MA), 48000 Hz, stereo, s32p (24 bit) (default)
Metadata:
BPS-eng : 2052102
DURATION-eng : 00:30:58.657000000
NUMBER_OF_FRAMES-eng: 174249
NUMBER_OF_BYTES-eng: 476769300
_STATISTICS_WRITING_APP-eng: mkvmerge v51.0.0 ('I Wish') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2021-01-31 10:27:14
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:2(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
Metadata:
BPS-eng : 192000
DURATION-eng : 00:30:58.656000000
NUMBER_OF_FRAMES-eng: 58083
NUMBER_OF_BYTES-eng: 44607744
_STATISTICS_WRITING_APP-eng: mkvmerge v51.0.0 ('I Wish') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2021-01-31 10:27:14
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:3(eng): Subtitle: hdmv_pgs_subtitle
Metadata:
BPS-eng : 0
DURATION-eng : 00:00:00.000000000
NUMBER_OF_FRAMES-eng: 0
NUMBER_OF_BYTES-eng: 0
_STATISTICS_WRITING_APP-eng: mkvmerge v51.0.0 ('I Wish') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2021-01-31 10:27:14
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
[Parsed_telecine_1 @ 000001f9e64f0f00] Telecine pattern 3322 yields up to 2 frames per frame, pts
advance factor: 8/10
Stream mapping:
Stream #0:0 (h264) -> minterpolate
setpts -> Stream #0:0 (libx265)
Stream #0:1 -> #0:1 (copy)
Stream #0:2 -> #0:2 (copy)
Stream #0:3 -> #0:3 (copy)
Press [q] to stop, [?] for help
[Parsed_telecine_1 @ 000001f9e7236ac0] Telecine pattern 3322 yields up to 2 frames per frame, pts
advance factor: 8/10
Output #0, matroska, to 'THE LAST EMPEROR [1987] part5.mkv':
Metadata:
encoder : Lavf58.65.101
Stream #0:0: Video: hevc, yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9],
q=2-31, 59.94 fps, 1k tbn (default)
Metadata:
encoder : Lavc58.119.100 libx265
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: N/A
Stream #0:1(eng): Audio: dts (DTS-HD MA) ([1] [0][0] / 0x2001), 48000 Hz, stereo, s32p (24 bit)
(default)
Metadata:
BPS-eng : 2052102
DURATION-eng : 00:30:58.657000000
NUMBER_OF_FRAMES-eng: 174249
NUMBER_OF_BYTES-eng: 476769300
_STATISTICS_WRITING_APP-eng: mkvmerge v51.0.0 ('I Wish') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2021-01-31 10:27:14
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:2(eng): Audio: ac3 ([0] [0][0] / 0x2000), 48000 Hz, stereo, fltp, 192 kb/s
Metadata:
BPS-eng : 192000
DURATION-eng : 00:30:58.656000000
NUMBER_OF_FRAMES-eng: 58083
NUMBER_OF_BYTES-eng: 44607744
_STATISTICS_WRITING_APP-eng: mkvmerge v51.0.0 ('I Wish') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2021-01-31 10:27:14
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:3(eng): Subtitle: hdmv_pgs_subtitle ([255][255][255][255] / 0xFFFFFFFF)
Metadata:
BPS-eng : 0
DURATION-eng : 00:00:00.000000000
NUMBER_OF_FRAMES-eng: 0
NUMBER_OF_BYTES-eng: 0
_STATISTICS_WRITING_APP-eng: mkvmerge v51.0.0 ('I Wish') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2021-01-31 10:27:14
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
frame= 1 fps=0.0 q=0.0 size= 4kB time=00:00:00.65 bitrate= 55.9kbits/s speed=1.21x
frame= 2 fps=0.8 q=0.0 size= 4kB time=00:00:00.65 bitrate= 55.9kbits/s speed=0.263x
frame= 6 fps=1.3 q=0.0 size= 4kB time=00:00:00.70 bitrate= 51.7kbits/s speed=0.15x
...234 more such lines
frame= 256 fps=0.5 q=27.0 size= 256kB time=00:00:10.60 bitrate= 197.8kbits/s speed=0.0224x
frame= 257 fps=0.5 q=28.2 size= 256kB time=00:00:10.60 bitrate= 197.8kbits/s speed=0.0224x
frame= 257 fps=0.5 q=28.2 size= 256kB time=00:00:10.60 bitrate= 197.8kbits/s speed=0.0223x
...96 more such lines
frame= 355 fps=0.5 q=24.0 size= 3072kB time=00:00:14.63 bitrate=1719.6kbits/s speed=0.0224x
frame= 356 fps=0.5 q=27.4 size= 3072kB time=00:00:14.63 bitrate=1719.6kbits/s speed=0.0223x
frame= 356 fps=0.5 q=27.4 size= 3072kB time=00:00:14.64 bitrate=1718.2kbits/s speed=0.0222x
...113 more such lines
frame= 471 fps=0.5 q=28.0 size= 5376kB time=00:00:19.62 bitrate=2243.7kbits/s speed=0.0227x
frame= 472 fps=0.5 q=28.3 size= 5376kB time=00:00:19.62 bitrate=2243.7kbits/s speed=0.0226x
frame= 472 fps=0.5 q=28.3 size= 5376kB time=00:00:19.62 bitrate=2243.7kbits/s speed=0.0226x
...84 more such lines
frame= 558 fps=0.5 q=22.4 size= 6912kB time=00:00:23.14 bitrate=2446.1kbits/s speed=0.0226x
frame= 558 fps=0.5 q=22.4 size= 6912kB time=00:00:23.14 bitrate=2446.1kbits/s speed=0.0226x
frame= 560 fps=0.5 q=24.4 size= 6912kB time=00:00:23.18 bitrate=2442.8kbits/s speed=0.0225x
...15 more such lines
frame= 576 fps=0.5 q=27.3 size= 7168kB time=00:00:23.94 bitrate=2452.0kbits/s speed=0.0227x
frame= 577 fps=0.5 q=28.2 size= 7168kB time=00:00:23.94 bitrate=2452.0kbits/s speed=0.0226x
frame= 577 fps=0.5 q=28.2 size= 7168kB time=00:00:23.94 bitrate=2452.0kbits/s speed=0.0226x
...117 more such lines
frame= 696 fps=0.5 q=27.5 size= 9216kB time=00:00:28.94 bitrate=2608.8kbits/s speed=0.0226x
frame= 697 fps=0.5 q=28.2 size= 9216kB time=00:00:28.94 bitrate=2608.8kbits/s speed=0.0226x
frame= 698 fps=0.5 q=28.7 size= 9216kB time=00:00:28.94 bitrate=2608.8kbits/s speed=0.0225x
...107 more such lines
frame= 806 fps=0.5 q=28.0 size= 11008kB time=00:00:33.45 bitrate=2695.8kbits/s speed=0.0226x
frame= 807 fps=0.5 q=28.3 size= 11008kB time=00:00:33.45 bitrate=2695.8kbits/s speed=0.0226x
frame= 807 fps=0.5 q=28.3 size= 11008kB time=00:00:33.46 bitrate=2694.8kbits/s speed=0.0226x
...119 more such lines
frame= 928 fps=0.5 q=28.8 size= 13056kB time=00:00:38.58 bitrate=2772.1kbits/s speed=0.0225x
frame= 929 fps=0.5 q=28.2 size= 13056kB time=00:00:38.58 bitrate=2772.1kbits/s speed=0.0225x
frame= 929 fps=0.5 q=28.2 size= 13056kB time=00:00:38.59 bitrate=2771.4kbits/s speed=0.0225x
...113 more such lines
frame= 1044 fps=0.5 q=28.2 size= 14848kB time=00:00:43.46 bitrate=2798.3kbits/s speed=0.0225x
frame= 1045 fps=0.5 q=24.0 size= 14848kB time=00:00:43.46 bitrate=2798.3kbits/s speed=0.0225x
frame= 1045 fps=0.5 q=24.0 size= 14848kB time=00:00:43.46 bitrate=2798.3kbits/s speed=0.0225x
...9 more such lines
frame= 1056 fps=0.5 q=27.7 size= 15104kB time=00:00:43.87 bitrate=2820.2kbits/s speed=0.0225x
frame= 1057 fps=0.5 q=28.2 size= 15104kB time=00:00:43.87 bitrate=2820.2kbits/s speed=0.0224x
frame= 1057 fps=0.5 q=28.2 size= 15104kB time=00:00:43.88 bitrate=2819.5kbits/s speed=0.0224x
...30 more such lines
frame= 1089 fps=0.5 q=24.0 size= 15616kB time=00:00:45.24 bitrate=2827.2kbits/s speed=0.0225x
frame= 1090 fps=0.5 q=23.3 size= 15616kB time=00:00:45.24 bitrate=2827.2kbits/s speed=0.0224x
frame= 1090 fps=0.5 q=23.3 size= 15616kB time=00:00:45.26 bitrate=2826.5kbits/s speed=0.0224x
...117 more such lines
frame= 1209 fps=0.5 q=28.2 size= 17408kB time=00:00:50.25 bitrate=2837.9kbits/s speed=0.0225x
frame= 1210 fps=0.5 q=23.8 size= 17408kB time=00:00:50.25 bitrate=2837.9kbits/s speed=0.0225x
frame= 1210 fps=0.5 q=23.8 size= 17408kB time=00:00:50.26 bitrate=2837.2kbits/s speed=0.0224x
...117 more such lines
frame= 1329 fps=0.5 q=28.2 size= 19200kB time=00:00:55.25 bitrate=2846.6kbits/s speed=0.0225x
frame= 1330 fps=0.5 q=23.9 size= 19200kB time=00:00:55.25 bitrate=2846.6kbits/s speed=0.0225x
frame= 1330 fps=0.5 q=23.9 size= 19200kB time=00:00:55.26 bitrate=2846.0kbits/s speed=0.0225x
...123 more such lines
frame= 1455 fps=0.5 q=23.5 size= 20992kB time=00:01:00.52 bitrate=2841.3kbits/s speed=0.0225x
frame= 1456 fps=0.5 q=27.3 size= 20992kB time=00:01:00.52 bitrate=2841.3kbits/s speed=0.0225x
frame= 1456 fps=0.5 q=27.3 size= 20992kB time=00:01:00.53 bitrate=2840.8kbits/s speed=0.0225x
...117 more such lines
frame= 1575 fps=0.5 q=24.1 size= 23040kB time=00:01:05.52 bitrate=2880.4kbits/s speed=0.0225x
frame= 1576 fps=0.5 q=27.1 size= 23040kB time=00:01:05.52 bitrate=2880.4kbits/s speed=0.0225x
frame= 1576 fps=0.5 q=27.1 size= 23040kB time=00:01:05.53 bitrate=2880.0kbits/s speed=0.0225x
...10 more such lines
frame= 1588 fps=0.5 q=22.4 size= 23296kB time=00:01:06.02 bitrate=2890.3kbits/s speed=0.0225x
frame= 1588 fps=0.5 q=22.4 size= 23296kB time=00:01:06.03 bitrate=2889.8kbits/s speed=0.0225x
frame= 1590 fps=0.5 q=26.0 size= 23296kB time=00:01:06.22 bitrate=2881.9kbits/s speed=0.0225x
...117 more such lines
...It was at this point that lines changed: "Starting new cluster" and changes in "size=...kB" got
smaller.
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1708 fps=0.5 q=28.8 size= 25088kB time=00:01:11.14 bitrate=2888.6kbits/s speed=0.0226x
frame= 1709 fps=0.5 q=27.9 size= 25088kB time=00:01:11.14 bitrate=2888.6kbits/s speed=0.0225x
frame= 1710 fps=0.5 q=23.7 size= 25088kB time=00:01:11.14 bitrate=2888.6kbits/s speed=0.0225x
frame= 1710 fps=0.5 q=23.7 size= 25088kB time=00:01:11.14 bitrate=2888.6kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1711 fps=0.5 q=27.7 size= 25344kB time=00:01:11.21 bitrate=2915.5kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1713 fps=0.5 q=28.7 size= 25344kB time=00:01:11.27 bitrate=2912.9kbits/s speed=0.0225x
frame= 1714 fps=0.5 q=27.8 size= 25344kB time=00:01:11.27 bitrate=2912.9kbits/s speed=0.0225x
frame= 1714 fps=0.5 q=27.8 size= 25344kB time=00:01:11.28 bitrate=2912.4kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1716 fps=0.5 q=26.9 size= 25344kB time=00:01:11.46 bitrate=2905.0kbits/s speed=0.0226x
frame= 1716 fps=0.5 q=26.9 size= 25344kB time=00:01:11.46 bitrate=2905.0kbits/s speed=0.0225x
frame= 1717 fps=0.5 q=28.0 size= 25344kB time=00:01:11.46 bitrate=2905.0kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1719 fps=0.5 q=27.9 size= 25344kB time=00:01:11.52 bitrate=2902.9kbits/s speed=0.0225x
frame= 1720 fps=0.5 q=23.8 size= 25344kB time=00:01:11.52 bitrate=2902.9kbits/s speed=0.0225x
frame= 1720 fps=0.5 q=23.8 size= 25344kB time=00:01:11.53 bitrate=2902.4kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1722 fps=0.5 q=27.9 size= 25344kB time=00:01:11.72 bitrate=2894.7kbits/s speed=0.0225x
frame= 1723 fps=0.5 q=28.0 size= 25344kB time=00:01:11.72 bitrate=2894.7kbits/s speed=0.0225x
frame= 1723 fps=0.5 q=28.0 size= 25344kB time=00:01:11.72 bitrate=2894.7kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1725 fps=0.5 q=23.7 size= 25344kB time=00:01:11.77 bitrate=2892.5kbits/s speed=0.0225x
frame= 1726 fps=0.5 q=27.6 size= 25344kB time=00:01:11.77 bitrate=2892.5kbits/s speed=0.0225x
frame= 1726 fps=0.5 q=27.6 size= 25344kB time=00:01:11.78 bitrate=2892.1kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1728 fps=0.5 q=28.7 size= 25344kB time=00:01:11.90 bitrate=2887.4kbits/s speed=0.0225x
frame= 1729 fps=0.5 q=27.8 size= 25344kB time=00:01:11.90 bitrate=2887.4kbits/s speed=0.0225x
frame= 1729 fps=0.5 q=27.8 size= 25344kB time=00:01:11.91 bitrate=2887.0kbits/s speed=0.0225x
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame= 1731 fps=0.5 q=27.3 size= 25600kB time=00:01:12.10 bitrate=2908.3kbits/s speed=0.0225x
frame= 1732 fps=0.5 q=27.9 size= 25600kB time=00:01:12.10 bitrate=2908.3kbits/s speed=0.0225x
frame= 1732 fps=0.5 q=27.9 size= 25600kB time=00:01:12.10 bitrate=2908.3kbits/s speed=0.0225x
...And so on until...
[matroska @ 000001f9e7236480] Starting new cluster due to timestamp
frame=19904 fps=0.5 q=28.2 size= 358400kB time=00:13:49.99 bitrate=3537.4kbits/s speed=0.0217x
frame=19905 fps=0.5 q=28.6 size= 358400kB time=00:13:49.99 bitrate=3537.4kbits/s speed=0.0217x
frame=19905 fps=0.5 q=28.6 size= 358400kB time=00:13:50.00 bitrate=3537.3kbits/s speed=0.0217x
Error while filtering: Cannot allocate memory
Failed to inject frame into filter network: Cannot allocate memory
Error while processing the decoded data for stream #0:0
Conversion failed!
More information about the ffmpeg-user
mailing list