Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#3851 closed defect (fixed)

Problem With Memory On Larger M4b to mp3 conversions

Reported by: michael1t Owned by:
Priority: normal Component: avformat
Version: git-master Keywords: mp3
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: yes

Description

Hello All ...

I have been using ffmpeg for a while and it works great ...

I only just starting having issues ...

Here is my problem ...

Windows Xp...

ffmpeg 8-11-2014 Nightly build test NO JOY ...win32

When I convert m4b to mp3 files and the m4b is bigger 850 mb (AudioBook?) some are bigger than 1.4 gb

ffmpeg crashes error out of memory ...

I watch ffmpeg in the task manager And I can See it is trying to keep the complete file in memory
it never dumps it to the disk until the conversion is complete ...
If I watch the File on the Disk it does NOT get bigger that 1 kB until it errors or finishes ...

Smaller m4b work fine ...

Here are some of the command lines I have tried and work But NOT for the Large files.

ffmpeg -i test.m4b -map_metadata 0:s:0 -codec:a libmp3lame -q:a 4 done.mp3

NOTE: all of the m4b files play fine ...

I have tried Many different m4b files without issue ...only those larger files 850 MB ... error ...
(I do NOT know the exact size at which it stops working)

All the above lines work perfectly with smaller files I only have issues if the m4b file is larger ..

thanks all in advance

Michael T.

Change History (10)

comment:1 Changed 5 years ago by cehoyos

Please provide your ffmpeg command line together with the complete, uncut console output and an input sample.

comment:2 Changed 5 years ago by michael1t

Please note the m4b file 800 mb and the log file is 504 MB not able to upload ..

Sorry

ffmpeg -v 9 -loglevel 99 -report -i testfile.m4b -map_metadata 0:s:0 -codec:a libmp3lame -q:a 4 done.mp3


Michael T.

Last edited 5 years ago by michael1t (previous) (diff)

comment:3 Changed 5 years ago by jamal

Can you at least post the first several lines? Even if not complete, part of the output will help us analyze the problem

comment:4 Changed 5 years ago by michael1t

I hope this helps ...

Michael T.

ffmpeg started on 2014-08-13 at 07:41:44
Report written to "ffmpeg-20140813-074144.log"
Command line:
ffmpeg -v 9 -loglevel 99 -report -i testfile.m4b -map_metadata 0:s:0 -codec:a libmp3lame -q:a 4 done.mp3
ffmpeg version N-64357-g42a92a2 Copyright (c) 2000-2014 the FFmpeg developers
  built on Jul  1 2014 22:02:07 with gcc 4.8.3 (GCC)
  configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-decklink --enable-zlib
  libavutil      52. 90.101 / 52. 90.101
  libavcodec     55. 68.100 / 55. 68.100
  libavformat    55. 44.100 / 55. 44.100
  libavdevice    55. 13.101 / 55. 13.101
  libavfilter     4.  9.100 /  4.  9.100
  libswscale      2.  6.100 /  2.  6.100
  libswresample   0. 19.100 /  0. 19.100
  libpostproc    52.  3.100 / 52.  3.100
Splitting the commandline.
Reading option '-v' ... matched as option 'v' (set logging level) with argument '9'.
Reading option '-loglevel' ... matched as option 'loglevel' (set logging level) with argument '99'.
Reading option '-report' ... matched as option 'report' (generate a report) with argument '1'.
Reading option '-i' ... matched as input file with argument 'testfile.m4b'.
Reading option '-map_metadata' ... matched as option 'map_metadata' (set metadata information of outfile from infile) with argument '0:s:0'.
Reading option '-codec:a' ... matched as option 'codec' (codec name) with argument 'libmp3lame'.
Reading option '-q:a' ... matched as option 'q' (use fixed quality scale (VBR)) with argument '4'.
Reading option 'done.mp3' ... matched as output file.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option v (set logging level) with argument 9.
Applying option loglevel (set logging level) with argument 99.
Applying option report (generate a report) with argument 1.
Successfully parsed a group of options.
Parsing a group of options: input file testfile.m4b.
Successfully parsed a group of options.
Opening an input file: testfile.m4b.
[mov,mp4,m4a,3gp,3g2,mj2 @ 032bbc20] Format mov,mp4,m4a,3gp,3g2,mj2 probed with size=2048 and score=100
[mov,mp4,m4a,3gp,3g2,mj2 @ 032bbc20] ISO: File Type Major Brand: M4A 
[mov,mp4,m4a,3gp,3g2,mj2 @ 032bbc20] stream 0, timescale not set
[mov,mp4,m4a,3gp,3g2,mj2 @ 032bbc20] Before avformat_find_stream_info() pos: 14765840 bytes read:14787912 seeks:0
[mjpeg @ 02dbb1c0] marker=d8 avail_size_in_buf=7764
[mjpeg @ 02dbb1c0] marker parser used 0 bytes (0 bits)
[mjpeg @ 02dbb1c0] marker=e0 avail_size_in_buf=7762
[mjpeg @ 02dbb1c0] marker parser used 16 bytes (128 bits)
[mjpeg @ 02dbb1c0] marker=db avail_size_in_buf=7744
[mjpeg @ 02dbb1c0] index=0
[mjpeg @ 02dbb1c0] qscale[0]: 3
[mjpeg @ 02dbb1c0] marker parser used 67 bytes (536 bits)
[mjpeg @ 02dbb1c0] marker=db avail_size_in_buf=7675
[mjpeg @ 02dbb1c0] index=1
[mjpeg @ 02dbb1c0] qscale[1]: 6
[mjpeg @ 02dbb1c0] marker parser used 67 bytes (536 bits)
[mjpeg @ 02dbb1c0] marker=c0 avail_size_in_buf=7606
[mjpeg @ 02dbb1c0] sof0: picture: 200x302
[mjpeg @ 02dbb1c0] component 0 2:2 id: 0 quant:0
[mjpeg @ 02dbb1c0] component 1 1:1 id: 1 quant:1
[mjpeg @ 02dbb1c0] component 2 1:1 id: 2 quant:1
[mjpeg @ 02dbb1c0] pix fmt id 22111100
[mjpeg @ 02dbb1c0] marker parser used 17 bytes (136 bits)
[mjpeg @ 02dbb1c0] marker=c4 avail_size_in_buf=7587
[mjpeg @ 02dbb1c0] class=0 index=0 nb_codes=12
[mjpeg @ 02dbb1c0] marker parser used 31 bytes (248 bits)
[mjpeg @ 02dbb1c0] marker=c4 avail_size_in_buf=7554
[mjpeg @ 02dbb1c0] class=1 index=0 nb_codes=251
[mjpeg @ 02dbb1c0] marker parser used 181 bytes (1448 bits)
[mjpeg @ 02dbb1c0] marker=c4 avail_size_in_buf=7371
[mjpeg @ 02dbb1c0] class=0 index=1 nb_codes=12
[mjpeg @ 02dbb1c0] marker parser used 31 bytes (248 bits)
[mjpeg @ 02dbb1c0] marker=c4 avail_size_in_buf=7338
[mjpeg @ 02dbb1c0] class=1 index=1 nb_codes=251
[mjpeg @ 02dbb1c0] marker parser used 181 bytes (1448 bits)
[mjpeg @ 02dbb1c0] escaping removed 28 bytes
[mjpeg @ 02dbb1c0] marker=da avail_size_in_buf=7155
[mjpeg @ 02dbb1c0] component: 0
[mjpeg @ 02dbb1c0] component: 1
[mjpeg @ 02dbb1c0] component: 2
[mjpeg @ 02dbb1c0] marker parser used 7126 bytes (57004 bits)
[mjpeg @ 02dbb1c0] marker=d9 avail_size_in_buf=0
[mjpeg @ 02dbb1c0] decode frame unused 0 bytes
[mov,mp4,m4a,3gp,3g2,mj2 @ 032bbc20] demuxer injecting skip 2112
[aac @ 02dba5e0] skip 4224 samples due to side data
[aac @ 02dba5e0] skip whole frame, skip left: 2176
[mov,mp4,m4a,3gp,3g2,mj2 @ 032bbc20] max_analyze_duration 5000000 reached at 5015510 microseconds
[mov,mp4,m4a,3gp,3g2,mj2 @ 032bbc20] After avformat_find_stream_info() pos: 14793412 bytes read:14820680 seeks:0 frames:111
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'testfile.m4b':
  Metadata:
    major_brand     : M4A 
    minor_version   : 0
    compatible_brands: M4A mp42isom
    creation_time   : 2014-01-31 09:48:13
    title           : Outlander 3.0.0-Voyager
    compilation     : 0
    gapless_playback: 0
    encoder         : iTunes 11.1.4.62
    Encoding Params : vers
    iTunNORM        :  00000597 00000000 0000A452 00000000 085272A6 00000000 00007F55 00000000 08AF76E4 00000000
    artist          : Diana Gabaldon
    album_artist    : Diana Gabaldon
    album           : Outlander 3.0.0-Voyager
    track           : 1/1
    genre           : Audio book
  Duration: 43:15:02.29, start: 0.000000, bitrate: 41 kb/s
    Stream #0:0(und), 110, 1/22050: Audio: aac (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 41 kb/s (default)
    Metadata:
      creation_time   : 2014-01-31 09:48:13
    Stream #0:1, 1, 1/90000: Video: mjpeg, yuvj420p(pc, bt470bg), 200x302 [SAR 1:1 DAR 100:151], 1/90000, 90k tbr, 90k tbn, 90k tbc
Successfully opened the file.
Parsing a group of options: output file done.mp3.
Applying option map_metadata (set metadata information of outfile from infile) with argument 0:s:0.
Applying option codec:a (codec name) with argument libmp3lame.
Applying option q:a (use fixed quality scale (VBR)) with argument 4.
Successfully parsed a group of options.
Opening an output file: done.mp3.
Successfully opened the file.
detected 2 logical cores
[graph 0 input from stream 0:1 @ 02dcce00] Setting 'video_size' to value '200x302'
[graph 0 input from stream 0:1 @ 02dcce00] Setting 'pix_fmt' to value '12'
[graph 0 input from stream 0:1 @ 02dcce00] Setting 'time_base' to value '1/90000'
[graph 0 input from stream 0:1 @ 02dcce00] Setting 'pixel_aspect' to value '1/1'
[graph 0 input from stream 0:1 @ 02dcce00] Setting 'sws_param' to value 'flags=2'
[graph 0 input from stream 0:1 @ 02dcce00] Setting 'frame_rate' to value '90000/1'
[graph 0 input from stream 0:1 @ 02dcce00] w:200 h:302 pixfmt:yuvj420p tb:1/90000 fr:90000/1 sar:1/1 sws_param:flags=2
[format @ 02dcd6c0] compat: called with args=[rgb24|rgba|rgb48be|rgba64be|pal8|gray|gray8a|gray16be|monob]
[format @ 02dcd6c0] Setting 'pix_fmts' to value 'rgb24|rgba|rgb48be|rgba64be|pal8|gray|gray8a|gray16be|monob'
[auto-inserted scaler 0 @ 02dcea00] Setting 'flags' to value '0x4'
[auto-inserted scaler 0 @ 02dcea00] w:iw h:ih flags:'0x4' interl:0
[format @ 02dcd6c0] auto-inserting filter 'auto-inserted scaler 0' between the filter 'Parsed_null_0' and the filter 'format'
[AVFilterGraph @ 02dcc120] query_formats: 4 queried, 2 merged, 1 already done, 0 delayed
[auto-inserted scaler 0 @ 02dcea00] picking rgb24 out of 8 ref:yuvj420p alpha:0
[swscaler @ 02db4300] deprecated pixel format used, make sure you did set range correctly
[auto-inserted scaler 0 @ 02dcea00] w:200 h:302 fmt:yuvj420p sar:1/1 -> w:200 h:302 fmt:rgb24 sar:1/1 flags:0x4
[mp3 @ 032c2020] Frame rate very high for a muxer not efficiently supporting it.
Please consider specifying a lower framerate, a different muxer or -vsync 2
[graph 1 input from stream 0:0 @ 02dd0260] Setting 'time_base' to value '1/44100'
[graph 1 input from stream 0:0 @ 02dd0260] Setting 'sample_rate' to value '44100'
[graph 1 input from stream 0:0 @ 02dd0260] Setting 'sample_fmt' to value 'fltp'
[graph 1 input from stream 0:0 @ 02dd0260] Setting 'channel_layout' to value '0x3'
[graph 1 input from stream 0:0 @ 02dd0260] tb:1/44100 samplefmt:fltp samplerate:44100 chlayout:0x3
[audio format for output stream 0:1 @ 02dd0160] Setting 'sample_fmts' to value 's32p|fltp|s16p'
[audio format for output stream 0:1 @ 02dd0160] Setting 'sample_rates' to value '44100|48000|32000|22050|24000|16000|11025|12000|8000'
[audio format for output stream 0:1 @ 02dd0160] Setting 'channel_layouts' to value '0x4|0x3'
[AVFilterGraph @ 02dcf1c0] query_formats: 4 queried, 9 merged, 0 already done, 0 delayed
[mp3 @ 032c2020] Using AVStream.codec.time_base as a timebase hint to the muxer is deprecated. Set AVStream.time_base instead.
[mp3 @ 032c2020] Using AVStream.codec.time_base as a timebase hint to the muxer is deprecated. Set AVStream.time_base instead.
Output #0, mp3, to 'done.mp3':
  Metadata:
    TDEN            : 2014-01-31 09:48:13
    TLAN            : und
    TSSE            : Lavf55.44.100
    Stream #0:0, 0, 1/90000: Video: png, rgb24, 200x302 [SAR 1:1 DAR 100:151], 1/90000, q=2-31, 200 kb/s, 90k fps, 90k tbn, 90k tbc
    Metadata:
      encoder         : Lavc55.68.100 png
    Stream #0:1, 0, 1/44100: Audio: mp3 (libmp3lame), 44100 Hz, stereo, fltp (default)
    Metadata:
      encoder         : Lavc55.68.100 libmp3lame
Stream mapping:
  Stream #0:1 -> #0:0 (mjpeg (native) -> png (native))
  Stream #0:0 -> #0:1 (aac (native) -> mp3 (libmp3lame))
Press [q] to stop, [?] for help
[mjpeg @ 032c3dc0] marker=d8 avail_size_in_buf=7764
[mjpeg @ 032c3dc0] marker parser used 0 bytes (0 bits)
[mjpeg @ 032c3dc0] marker=e0 avail_size_in_buf=7762
[mjpeg @ 032c3dc0] marker parser used 16 bytes (128 bits)
[mjpeg @ 032c3dc0] marker=db avail_size_in_buf=7744
[mjpeg @ 032c3dc0] index=0
[mjpeg @ 032c3dc0] qscale[0]: 3
[mjpeg @ 032c3dc0] marker parser used 67 bytes (536 bits)
[mjpeg @ 032c3dc0] marker=db avail_size_in_buf=7675
[mjpeg @ 032c3dc0] index=1
[mjpeg @ 032c3dc0] qscale[1]: 6
[mjpeg @ 032c3dc0] marker parser used 67 bytes (536 bits)
[mjpeg @ 032c3dc0] marker=c0 avail_size_in_buf=7606
[mjpeg @ 032c3dc0] sof0: picture: 200x302
[mjpeg @ 032c3dc0] component 0 2:2 id: 0 quant:0
[mjpeg @ 032c3dc0] component 1 1:1 id: 1 quant:1
[mjpeg @ 032c3dc0] component 2 1:1 id: 2 quant:1
[mjpeg @ 032c3dc0] pix fmt id 22111100
[mjpeg @ 032c3dc0] marker parser used 17 bytes (136 bits)
[mjpeg @ 032c3dc0] marker=c4 avail_size_in_buf=7587
[mjpeg @ 032c3dc0] class=0 index=0 nb_codes=12
[mjpeg @ 032c3dc0] marker parser used 31 bytes (248 bits)
[mjpeg @ 032c3dc0] marker=c4 avail_size_in_buf=7554
[mjpeg @ 032c3dc0] class=1 index=0 nb_codes=251
[mjpeg @ 032c3dc0] marker parser used 181 bytes (1448 bits)
[mjpeg @ 032c3dc0] marker=c4 avail_size_in_buf=7371
[mjpeg @ 032c3dc0] class=0 index=1 nb_codes=12
[mjpeg @ 032c3dc0] marker parser used 31 bytes (248 bits)
[mjpeg @ 032c3dc0] marker=c4 avail_size_in_buf=7338
[mjpeg @ 032c3dc0] class=1 index=1 nb_codes=251
[mjpeg @ 032c3dc0] marker parser used 181 bytes (1448 bits)
[mjpeg @ 032c3dc0] escaping removed 28 bytes
[mjpeg @ 032c3dc0] marker=da avail_size_in_buf=7155
[mjpeg @ 032c3dc0] component: 0
[mjpeg @ 032c3dc0] component: 1
[mjpeg @ 032c3dc0] component: 2
[mjpeg @ 032c3dc0] marker parser used 7126 bytes (57004 bits)
[mjpeg @ 032c3dc0] marker=d9 avail_size_in_buf=0
[mjpeg @ 032c3dc0] decode frame unused 0 bytes
[aac @ 032c39c0] skip 4224 samples due to side data
[aac @ 032c39c0] skip whole frame, skip left: 2176
[aac @ 032c39c0] skip whole frame, skip left: 128
[aac @ 032c39c0] skip 128/2048 samples
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004897 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output
[mp3 @ 032c2020] Delay between the first packet and last packet in the muxing queue is 10004898 > 10000000: forcing output

comment:5 Changed 5 years ago by jamal

Can you try using -vn in the command line?
Something like

ffmpeg -i testfile.m4b -map_metadata 0:s:0 -vn -codec:a libmp3lame -q:a 4 done.mp3

And see if it stops buffering all the audio in memory until conversion is completed (Which would fix the out-of-memory crash)

comment:6 Changed 5 years ago by michael1t

Hello jamal ,

That Did it ... it works now ... thanks
Is that The Best Way to Do it ...

Here is the Report it made ...

ffmpeg started on 2014-08-13 at 18:33:49
Report written to "ffmpeg-20140813-183349.log"
Command line:
ffmpeg -v 9 -loglevel 99 -report -i testfile.m4b -map_metadata 0:s:0 -vn -codec:a libmp3lame -q:a 4 done.mp3
ffmpeg version N-64357-g42a92a2 Copyright (c) 2000-2014 the FFmpeg developers
  built on Jul  1 2014 22:02:07 with gcc 4.8.3 (GCC)
  configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-decklink --enable-zlib
  libavutil      52. 90.101 / 52. 90.101
  libavcodec     55. 68.100 / 55. 68.100
  libavformat    55. 44.100 / 55. 44.100
  libavdevice    55. 13.101 / 55. 13.101
  libavfilter     4.  9.100 /  4.  9.100
  libswscale      2.  6.100 /  2.  6.100
  libswresample   0. 19.100 /  0. 19.100
  libpostproc    52.  3.100 / 52.  3.100
Splitting the commandline.
Reading option '-v' ... matched as option 'v' (set logging level) with argument '9'.
Reading option '-loglevel' ... matched as option 'loglevel' (set logging level) with argument '99'.
Reading option '-report' ... matched as option 'report' (generate a report) with argument '1'.
Reading option '-i' ... matched as input file with argument 'testfile.m4b'.
Reading option '-map_metadata' ... matched as option 'map_metadata' (set metadata information of outfile from infile) with argument '0:s:0'.
Reading option '-vn' ... matched as option 'vn' (disable video) with argument '1'.
Reading option '-codec:a' ... matched as option 'codec' (codec name) with argument 'libmp3lame'.
Reading option '-q:a' ... matched as option 'q' (use fixed quality scale (VBR)) with argument '4'.
Reading option 'done.mp3' ... matched as output file.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option v (set logging level) with argument 9.
Applying option loglevel (set logging level) with argument 99.
Applying option report (generate a report) with argument 1.
Successfully parsed a group of options.
Parsing a group of options: input file testfile.m4b.
Successfully parsed a group of options.
Opening an input file: testfile.m4b.
[mov,mp4,m4a,3gp,3g2,mj2 @ 02dbc8e0] Format mov,mp4,m4a,3gp,3g2,mj2 probed with size=2048 and score=100
[mov,mp4,m4a,3gp,3g2,mj2 @ 02dbc8e0] ISO: File Type Major Brand: M4A 
[mov,mp4,m4a,3gp,3g2,mj2 @ 02dbc8e0] stream 0, timescale not set
[mov,mp4,m4a,3gp,3g2,mj2 @ 02dbc8e0] Before avformat_find_stream_info() pos: 14765840 bytes read:14787912 seeks:0
[mjpeg @ 02dbb840] marker=d8 avail_size_in_buf=7764
[mjpeg @ 02dbb840] marker parser used 0 bytes (0 bits)
[mjpeg @ 02dbb840] marker=e0 avail_size_in_buf=7762
[mjpeg @ 02dbb840] marker parser used 16 bytes (128 bits)
[mjpeg @ 02dbb840] marker=db avail_size_in_buf=7744
[mjpeg @ 02dbb840] index=0
[mjpeg @ 02dbb840] qscale[0]: 3
[mjpeg @ 02dbb840] marker parser used 67 bytes (536 bits)
[mjpeg @ 02dbb840] marker=db avail_size_in_buf=7675
[mjpeg @ 02dbb840] index=1
[mjpeg @ 02dbb840] qscale[1]: 6
[mjpeg @ 02dbb840] marker parser used 67 bytes (536 bits)
[mjpeg @ 02dbb840] marker=c0 avail_size_in_buf=7606
[mjpeg @ 02dbb840] sof0: picture: 200x302
[mjpeg @ 02dbb840] component 0 2:2 id: 0 quant:0
[mjpeg @ 02dbb840] component 1 1:1 id: 1 quant:1
[mjpeg @ 02dbb840] component 2 1:1 id: 2 quant:1
[mjpeg @ 02dbb840] pix fmt id 22111100
[mjpeg @ 02dbb840] marker parser used 17 bytes (136 bits)
[mjpeg @ 02dbb840] marker=c4 avail_size_in_buf=7587
[mjpeg @ 02dbb840] class=0 index=0 nb_codes=12
[mjpeg @ 02dbb840] marker parser used 31 bytes (248 bits)
[mjpeg @ 02dbb840] marker=c4 avail_size_in_buf=7554
[mjpeg @ 02dbb840] class=1 index=0 nb_codes=251
[mjpeg @ 02dbb840] marker parser used 181 bytes (1448 bits)
[mjpeg @ 02dbb840] marker=c4 avail_size_in_buf=7371
[mjpeg @ 02dbb840] class=0 index=1 nb_codes=12
[mjpeg @ 02dbb840] marker parser used 31 bytes (248 bits)
[mjpeg @ 02dbb840] marker=c4 avail_size_in_buf=7338
[mjpeg @ 02dbb840] class=1 index=1 nb_codes=251
[mjpeg @ 02dbb840] marker parser used 181 bytes (1448 bits)
[mjpeg @ 02dbb840] escaping removed 28 bytes
[mjpeg @ 02dbb840] marker=da avail_size_in_buf=7155
[mjpeg @ 02dbb840] component: 0
[mjpeg @ 02dbb840] component: 1
[mjpeg @ 02dbb840] component: 2
[mjpeg @ 02dbb840] marker parser used 7126 bytes (57004 bits)
[mjpeg @ 02dbb840] marker=d9 avail_size_in_buf=0
[mjpeg @ 02dbb840] decode frame unused 0 bytes
[mov,mp4,m4a,3gp,3g2,mj2 @ 02dbc8e0] demuxer injecting skip 2112
[aac @ 02ec1020] skip 4224 samples due to side data
[aac @ 02ec1020] skip whole frame, skip left: 2176
[mov,mp4,m4a,3gp,3g2,mj2 @ 02dbc8e0] max_analyze_duration 5000000 reached at 5015510 microseconds
[mov,mp4,m4a,3gp,3g2,mj2 @ 02dbc8e0] After avformat_find_stream_info() pos: 14793412 bytes read:14820680 seeks:0 frames:111
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'testfile.m4b':
  Metadata:
    major_brand     : M4A 
    minor_version   : 0
    compatible_brands: M4A mp42isom
    creation_time   : 2014-01-31 09:48:13
    title           : Outlander 3.0.0-Voyager
    compilation     : 0
    gapless_playback: 0
    encoder         : iTunes 11.1.4.62
    Encoding Params : vers
    iTunNORM        :  00000597 00000000 0000A452 00000000 085272A6 00000000 00007F55 00000000 08AF76E4 00000000
    artist          : Diana Gabaldon
    album_artist    : Diana Gabaldon
    album           : Outlander 3.0.0-Voyager
    track           : 1/1
    genre           : Audio book
  Duration: 43:15:02.29, start: 0.000000, bitrate: 41 kb/s
    Stream #0:0(und), 110, 1/22050: Audio: aac (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 41 kb/s (default)
    Metadata:
      creation_time   : 2014-01-31 09:48:13
    Stream #0:1, 1, 1/90000: Video: mjpeg, yuvj420p(pc, bt470bg), 200x302 [SAR 1:1 DAR 100:151], 1/90000, 90k tbr, 90k tbn, 90k tbc
Successfully opened the file.
Parsing a group of options: output file done.mp3.
Applying option map_metadata (set metadata information of outfile from infile) with argument 0:s:0.
Applying option vn (disable video) with argument 1.
Applying option codec:a (codec name) with argument libmp3lame.
Applying option q:a (use fixed quality scale (VBR)) with argument 4.
Successfully parsed a group of options.
Opening an output file: done.mp3.
Successfully opened the file.
detected 2 logical cores
[graph 0 input from stream 0:0 @ 02db6fa0] Setting 'time_base' to value '1/44100'
[graph 0 input from stream 0:0 @ 02db6fa0] Setting 'sample_rate' to value '44100'
[graph 0 input from stream 0:0 @ 02db6fa0] Setting 'sample_fmt' to value 'fltp'
[graph 0 input from stream 0:0 @ 02db6fa0] Setting 'channel_layout' to value '0x3'
[graph 0 input from stream 0:0 @ 02db6fa0] tb:1/44100 samplefmt:fltp samplerate:44100 chlayout:0x3
[audio format for output stream 0:0 @ 02dbc580] Setting 'sample_fmts' to value 's32p|fltp|s16p'
[audio format for output stream 0:0 @ 02dbc580] Setting 'sample_rates' to value '44100|48000|32000|22050|24000|16000|11025|12000|8000'
[audio format for output stream 0:0 @ 02dbc580] Setting 'channel_layouts' to value '0x4|0x3'
[AVFilterGraph @ 02db5360] query_formats: 4 queried, 9 merged, 0 already done, 0 delayed
[mp3 @ 02f6c900] Using AVStream.codec.time_base as a timebase hint to the muxer is deprecated. Set AVStream.time_base instead.
Output #0, mp3, to 'done.mp3':
  Metadata:
    TDEN            : 2014-01-31 09:48:13
    TLAN            : und
    TSSE            : Lavf55.44.100
    Stream #0:0, 0, 1/44100: Audio: mp3 (libmp3lame), 44100 Hz, stereo, fltp (default)
    Metadata:
      encoder         : Lavc55.68.100 libmp3lame
Stream mapping:
  Stream #0:0 -> #0:0 (aac (native) -> mp3 (libmp3lame))
Press [q] to stop, [?] for help
[aac @ 02ea1180] skip 4224 samples due to side data
[aac @ 02ea1180] skip whole frame, skip left: 2176
[aac @ 02ea1180] skip whole frame, skip left: 128
[aac @ 02ea1180] skip 128/2048 samples
size=     199kB time=00:00:25.14 bitrate=  64.7kbits/s    
size=     407kB time=00:00:51.24 bitrate=  65.1kbits/s    
size=     616kB time=00:01:17.52 bitrate=  65.1kbits/s    
size=     825kB time=00:01:43.67 bitrate=  65.2kbits/s    
size=    1033kB time=00:02:09.66 bitrate=  65.3kbits/s    
size=    1239kB time=00:02:35.31 bitrate=  65.4kbits/s    
size=    1446kB time=00:03:01.25 bitrate=  65.3kbits/s    
size=    1652kB time=00:03:27.32 bitrate=  65.3kbits/s    
size=    1856kB time=00:03:53.18 bitrate=  65.2kbits/s    
size=    2061kB time=00:04:18.81 bitrate=  65.2kbits/s    
size=    2270kB time=00:04:45.06 bitrate=  65.2kbits/s    
size=    2479kB time=00:05:11.34 bitrate=  65.2kbits/s    
size=    2689kB time=00:05:37.49 bitrate=  65.3kbits/s    
size=    2889kB time=00:06:03.06 bitrate=  65.2kbits/s    
size=    3097kB time=00:06:29.21 bitrate=  65.2kbits/s    
..
.
.
.
.
size= 1252145kB time=43:15:00.99 bitrate=  65.9kbits/s    
[output stream 0:0 @ 02ea45a0] EOF on sink link output stream 0:0:default.
No more output streams to write to, finishing.
[libmp3lame @ 02ebe020] Trying to remove 559 more samples than there are in the queue
size= 1252152kB time=43:15:02.30 bitrate=  65.9kbits/s    

video:0kB audio:1252152kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.000021%
Input file #0 (testfile.m4b):
  Input stream #0:0 (audio): 3352769 packets read (800519487 bytes); 3352767 frames decoded (6866466688 samples); 
  Input stream #0:1 (video): 1 packets read (7766 bytes); 
  Total: 3352770 packets (800527253 bytes) demuxed
Output file #0 (done.mp3):
  Output stream #0:0 (audio): 5960475 frames encoded (6866466688 samples); 5960476 packets muxed (1282203470 bytes); 
  Total: 5960476 packets (1282203470 bytes) muxed
3352769 frames successfully decoded, 0 decoding errors
[AVIOContext @ 02ea0ca0] Statistics: 1 seeks, 5960477 writeouts
[AVIOContext @ 02dbcf80] Statistics: 815285304 bytes read, 0 seeks

thanks .. Is there another way to fix it ... ???
Is this the Best way ???

Just Checking ...

Thanks

Michael T.

comment:7 Changed 5 years ago by jamal

  • Analyzed by developer set
  • Component changed from undetermined to avformat
  • Keywords mp3 added
  • Reproduced by developer set
  • Status changed from new to open
  • Version changed from unspecified to git-master

With -vn you made ffmpeg skip the cover art from the source file.

Currently, the mp3 muxer buffers every audio packet in memory until it receives the cover art if there's any, point when it dumps all the buffered audio to the file.
In your sample the cover art must be at the very end, so ffmpeg ran out of memory before it got to it.

For now yes, that's the best workaround.

comment:8 Changed 5 years ago by cehoyos

Please upload your input sample, there is no file size limit.

comment:9 follow-up: Changed 5 years ago by cehoyos

  • Resolution set to fixed
  • Status changed from open to closed

Fixed by James Almer in d3e9bee6

comment:10 in reply to: ↑ 9 Changed 5 years ago by michael1t

Replying to cehoyos:

Fixed by James Almer in d3e9bee6

It was Fixed and I can use the normal options with out it crashing ...
Please tell me which nightly build I should download and test ...
As the work around list above has limits and is not a fix ...

Michael T.

Note: See TracTickets for help on using tickets.