0

I'm trying to run this on an Mac with an Apple M1 chip:

ffmpeg -i input.MP4 -c:v hevc_videotoolbox -b:v 2000000 -s 1280x720 output.mp4

And FFmpeg returning error:

Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> hevc (hevc_videotoolbox))
  Stream #0:1 -> #0:1 (aac (native) -> aac (native))
Press [q] to stop, [?] for help
[hevc_videotoolbox @ 0x7fa5bf815000] Error: cannot create compression session: -12908
[hevc_videotoolbox @ 0x7fa5bf815000] Try -allow_sw 1. The hardware encoder may be busy, or not supported.
Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

Any way to fix this? Do I need to install additional packages or what can I do?

It works only if I not specify c:v.

ffmpeg -hwaccels` and `ffmpeg -encoders | grep videotoolbox

Both mention they have Video Toolbox.


The debugging output when I run this command:

ffmpeg -loglevel debug -i input.MP4 -c:v hevc_videotoolbox -b:v 2000000 output.mp4

Is this:

Applying option c:v (codec name) with argument hevc_videotoolbox.
Applying option b:v (video bitrate (please use -b:v)) with argument 2000000.
Successfully parsed a group of options.
Opening an output file: xxxx
[out#0/mp4 @ 0x7f8921804fc0] No explicit maps, mapping streams automatically...
[vost#0:0/hevc_videotoolbox @ 0x7f8910f04bc0] Created video stream from input stream 0:0
detected 8 logical cores
[h264 @ 0x7f8920f13840] nal_unit_type: 7(SPS), nal_ref_idc: 1
[h264 @ 0x7f8920f13840] Decoding VUI
[h264 @ 0x7f8920f13840] nal_unit_type: 8(PPS), nal_ref_idc: 1
[aost#0:1/aac @ 0x7f8920f68d40] Created audio stream from input stream 0:1
For transform of length 64, inverse, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    2: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 32, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft32_ns_float_c - type: fft_float, len: 32, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_inv_float_c - type: mdct_float, len: 64, factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only]
        fft32_ns_float_c - type: fft_float, len: 32, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 64, inverse, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    2: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 32, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft32_ns_float_c - type: fft_float, len: 32, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_inv_float_c - type: mdct_float, len: 64, factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only]
        fft32_ns_float_c - type: fft_float, len: 32, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 120, inverse, mdct_float, flags: [aligned, out_of_place], found 5 matches:
    1: mdct_pfa_15xM_inv_float_c - type: mdct_float, len: [30, ∞], factors[2]: [15, any], flags: [unaligned, out_of_place, inv_only], prio: 304
    2: mdct_pfa_5xM_inv_float_c - type: mdct_float, len: [10, ∞], factors[2]: [5, any], flags: [unaligned, out_of_place, inv_only], prio: 144
    3: mdct_pfa_3xM_inv_float_c - type: mdct_float, len: [6, ∞], factors[2]: [3, any], flags: [unaligned, out_of_place, inv_only], prio: 112
    4: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    5: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 4, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft4_fwd_float_sse2 - type: fft_float, len: 4, factor: 2, flags: [aligned, inplace, out_of_place, preshuf], prio: 352
    2: fft4_ns_float_c - type: fft_float, len: 4, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_pfa_15xM_inv_float_c - type: mdct_float, len: 120, factors[2]: [15, any], flags: [unaligned, out_of_place, inv_only]
        fft4_fwd_float_sse2 - type: fft_float, len: 4, factor: 2, flags: [aligned, inplace, out_of_place, preshuf]
For transform of length 128, inverse, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    2: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 64, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft64_ns_float_c - type: fft_float, len: 64, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_inv_float_c - type: mdct_float, len: 128, factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only]
        fft64_ns_float_c - type: fft_float, len: 64, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 480, inverse, mdct_float, flags: [aligned, out_of_place], found 5 matches:
    1: mdct_pfa_15xM_inv_float_c - type: mdct_float, len: [30, ∞], factors[2]: [15, any], flags: [unaligned, out_of_place, inv_only], prio: 304
    2: mdct_pfa_5xM_inv_float_c - type: mdct_float, len: [10, ∞], factors[2]: [5, any], flags: [unaligned, out_of_place, inv_only], prio: 144
    3: mdct_pfa_3xM_inv_float_c - type: mdct_float, len: [6, ∞], factors[2]: [3, any], flags: [unaligned, out_of_place, inv_only], prio: 112
    4: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    5: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 16, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft16_ns_float_c - type: fft_float, len: 16, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_pfa_15xM_inv_float_c - type: mdct_float, len: 480, factors[2]: [15, any], flags: [unaligned, out_of_place, inv_only]
        fft16_ns_float_c - type: fft_float, len: 16, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 512, inverse, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    2: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 256, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft256_ns_float_c - type: fft_float, len: 256, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_inv_float_c - type: mdct_float, len: 512, factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only]
        fft256_ns_float_c - type: fft_float, len: 256, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 960, inverse, mdct_float, flags: [aligned, out_of_place], found 5 matches:
    1: mdct_pfa_15xM_inv_float_c - type: mdct_float, len: [30, ∞], factors[2]: [15, any], flags: [unaligned, out_of_place, inv_only], prio: 304
    2: mdct_pfa_5xM_inv_float_c - type: mdct_float, len: [10, ∞], factors[2]: [5, any], flags: [unaligned, out_of_place, inv_only], prio: 144
    3: mdct_pfa_3xM_inv_float_c - type: mdct_float, len: [6, ∞], factors[2]: [3, any], flags: [unaligned, out_of_place, inv_only], prio: 112
    4: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    5: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 32, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft32_ns_float_c - type: fft_float, len: 32, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_pfa_15xM_inv_float_c - type: mdct_float, len: 960, factors[2]: [15, any], flags: [unaligned, out_of_place, inv_only]
        fft32_ns_float_c - type: fft_float, len: 32, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 1024, inverse, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: 96
    2: mdct_naive_inv_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only], prio: -130976
For transform of length 512, inverse, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft512_ns_float_c - type: fft_float, len: 512, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_inv_float_c - type: mdct_float, len: 1024, factors[2]: [2, any], flags: [unaligned, out_of_place, inv_only]
        fft512_ns_float_c - type: fft_float, len: 512, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 1024, forward, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_fwd_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only], prio: 96
    2: mdct_naive_fwd_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only], prio: -130976
For transform of length 512, forward, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft512_ns_float_c - type: fft_float, len: 512, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_fwd_float_c - type: mdct_float, len: 1024, factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only]
        fft512_ns_float_c - type: fft_float, len: 512, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
[file @ 0x7f8920f6f440] Setting default whitelist 'file,crypto,data'
Successfully opened the file.
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> hevc (hevc_videotoolbox))
  Stream #0:1 -> #0:1 (aac (native) -> aac (native))
Press [q] to stop, [?] for help
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[h264 @ 0x7f8920f13840] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f13840] nal_unit_type: 6(SEI), nal_ref_idc: 0
    Last message repeated 2 times
[h264 @ 0x7f8920f13840] nal_unit_type: 5(IDR), nal_ref_idc: 1
[graph_1_in_0_1 @ 0x7f8921807dc0] Setting 'time_base' to value '1/48000'
[graph_1_in_0_1 @ 0x7f8921807dc0] Setting 'sample_rate' to value '48000'
[graph_1_in_0_1 @ 0x7f8921807dc0] Setting 'sample_fmt' to value 'fltp'
[graph_1_in_0_1 @ 0x7f8921807dc0] Setting 'channel_layout' to value 'mono'
[h264 @ 0x7f8920f13840] Format yuv420p chosen by get_format().
[h264 @ 0x7f8920f13840] Reinit context to 1920x1088, pix_fmt: yuv420p
[graph_1_in_0_1 @ 0x7f8921807dc0] tb:1/48000 samplefmt:fltp samplerate:48000 chlayout:mono
[format_out_0_1 @ 0x7f8910f05180] Setting 'sample_fmts' to value 'fltp'
[format_out_0_1 @ 0x7f8910f05180] Setting 'sample_rates' to value '96000|88200|64000|48000|44100|32000|24000|22050|16000|12000|11025|8000|7350'
[AVFilterGraph @ 0x7f8921807980] query_formats: 4 queried, 6 merged, 3 already done, 0 delayed
For transform of length 1024, forward, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_fwd_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only], prio: 96
    2: mdct_naive_fwd_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only], prio: -130976
For transform of length 512, forward, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: ct_type:1 pic_struct:0
fft512_ns_float_c - type: fft_float, len: 512, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_fwd_float_c - type: mdct_float, len: 1024, factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only]
        fft512_ns_float_c - type: fft_float, len: 512, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
For transform of length 128, forward, mdct_float, flags: [aligned, out_of_place], found 2 matches:
    1: mdct_fwd_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only], prio: 96
    2: mdct_naive_fwd_float_c - type: mdct_float, len: [2, ∞], factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only], prio: -130976
For transform of length 64, forward, fft_float, flags: [aligned, inplace, preshuf], found 2 matches:
    1: fft_pfa_ns_float_c - type: fft_float, len: [6, ∞], factors[2]: [7, 5, 3, 2, any], flags: [unaligned, inplace, out_of_place, preshuf], prio: 112
    2: fft64_ns_float_c - type: fft_float, len: 64, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf], prio: 96
Transform tree:
    mdct_fwd_float_c - type: mdct_float, len: 128, factors[2]: [2, any], flags: [unaligned, out_of_place, fwd_only]
        fft64_ns_float_c - type: fft_float, len: 64, factor: 2, flags: [unaligned, inplace, out_of_place, preshuf]
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.03625
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.03625 queue head -1 ts N/A
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.0575833
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.0575833 queue head -1 ts N/A
[h264 @ 0x7f8920f0cc00] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f0cc00] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 0x7f8920f0cc00] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.0789167
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.0789167 queue head -1 ts N/A
[h264 @ 0x7f8920f0cc00] ct_type:1 pic_struct:0
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.10025
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.10025 queue head -1 ts N/A
[h264 @ 0x7f8920f1d400] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f1d400] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 0x7f8920f1d400] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[h264 @ 0x7f8920f1d400] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.121583
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.121583 queue head -1 ts N/A
[h264 @ 0x7f8920f27e00] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f27e00] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 0x7f8920f27e00] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.142917
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.142917 queue head -1 ts N/A
[h264 @ 0x7f8920f27e00] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.16425
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.16425 queue head -1 ts N/A
[h264 @ 0x7f8920f328c0] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f328c0] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 0x7f8920f328c0] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.185583
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.185583 queue head -1 ts N/A
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[h264 @ 0x7f8920f328c0] ct_type:1 pic_struct:0
[h264 @ 0x7f8920f3d380] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f3d380] nal_unit_type: 6(SEI), nal_ref_idc: 0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.206917
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.206917 queue head -1 ts N/A
[h264 @ 0x7f8920f3d380] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[h264 @ 0x7f8920f3d380] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.22825
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.22825 queue head -1 ts N/A
[h264 @ 0x7f8920f47e00] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f47e00] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 0x7f8920f47e00] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.249583
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.249583 queue head -1 ts N/A
[NULL @ 0x7f8920f066c0] ct_type:1 pic_struct:0
[h264 @ 0x7f8920f47e00] ct_type:1 pic_struct:0
[h264 @ 0x7f8920f528c0] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f528c0] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 0x7f8920f528c0] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[out#0/mp4 @ 0x7f8921804fc0] sq: send 1 ts 0.270917
[out#0/mp4 @ 0x7f8921804fc0] sq: receive 1 ts 0.270917 queue head -1 ts N/A
[h264 @ 0x7f8920f528c0] ct_type:1 pic_struct:0
[h264 @ 0x7f8920f5d380] nal_unit_type: 9(AUD), nal_ref_idc: 0
[h264 @ 0x7f8920f5d380] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 0x7f8920f5d380] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
[h264 @ 0x7f8920f5d380] ct_type:1 pic_struct:0
[graph 0 input from stream 0:0 @ 0x7f88e10048c0] Setting 'video_size' to value '1920x1080'
[graph 0 input from stream 0:0 @ 0x7f88e10048c0] Setting 'pix_fmt' to value '0'
[graph 0 input from stream 0:0 @ 0x7f88e10048c0] Setting 'time_base' to value '1/30000'
[graph 0 input from stream 0:0 @ 0x7f88e10048c0] Setting 'pixel_aspect' to value '0/1'
[graph 0 input from stream 0:0 @ 0x7f88e10048c0] Setting 'frame_rate' to value '30000/1001'
[graph 0 input from stream 0:0 @ 0x7f88e10048c0] w:1920 h:1080 pixfmt:yuv420p tb:1/30000 fr:30000/1001 sar:0/1
[format @ 0x7f88e0f04600] Setting 'pix_fmts' to value 'videotoolbox_vld|nv12|yuv420p|bgra|p010le'
[AVFilterGraph @ 0x7f88e0f04200] query_formats: 4 queried, 3 merged, 0 already done, 0 delayed
[hevc_videotoolbox @ 0x7f89218062c0] Error: cannot create compression session: -12908
[hevc_videotoolbox @ 0x7f89218062c0] Try -allow_sw 1. The hardware encoder may be busy, or not supported.
[vost#0:0/hevc_videotoolbox @ 0x7f8910f04bc0] Error while opening encoder - maybe incorrect parameters such as bit_rate, rate, width or height.
Error while filtering: Generic error in an external library
[vist#0:0/h264 @ 0x7f8921804dc0] Decoder thread received EOF packet
[vist#0:0/h264 @ 0x7f8921804dc0] Decoder returned EOF, finishing
[vist#0:0/h264 @ 0x7f8921804dc0] Terminating decoder thread
[aist#0:1/aac @ 0x7f8921805780] Decoder thread received EOF packet
[aist#0:1/aac @ 0x7f8921805780] Decoder returned EOF, finishing
[aist#0:1/aac @ 0x7f8921805780] Terminating decoder thread
[out#0/mp4 @ 0x7f8921804fc0] sq: 0 EOF
[out#0/mp4 @ 0x7f8921804fc0] sq: finish 0; head ts NOPTS
[out#0/mp4 @ 0x7f8921804fc0] sq: 1 EOF
[out#0/mp4 @ 0x7f8921804fc0] sq: finish 1; head ts 0.270917
[out#0/mp4 @ 0x7f8921804fc0] sq: finish queue
[out#0/mp4 @ 0x7f8921804fc0] sq: 1 EOF
[out#0/mp4 @ 0x7f8921804fc0] sq: finish queue
[out#0/mp4 @ 0x7f8921804fc0] sq: 1 EOF
[out#0/mp4 @ 0x7f8921804fc0] sq: finish queue
[out#0/mp4 @ 0x7f8921804fc0] Nothing was written into output file, because at least one of its streams received no packets.
frame=    0 fps=0.0 q=0.0 Lsize=       0kB time=00:00:00.24 bitrate=   0.0kbits/s speed=3.53x
[aac @ 0x7f8920f69100] Qavg: 3040.040
[AVIOContext @ 0x7f8920f6f540] Statistics: 0 bytes written, 0 seeks, 0 writeouts
[in#0/mov,mp4,m4a,3gp,3g2,mj2 @ 0x7f8920f05d00] Terminating demuxer thread
[in#0/mov,mp4,m4a,3gp,3g2,mj2 @ 0x7f8920f05d00] Input file #0 (/Users/philipp/Library/CloudStorage/GoogleDrive-skorphil@gmail.com/My Drive/2020vid/2020-06-13/2020-06-13_205142.MP4):
[in#0/mov,mp4,m4a,3gp,3g2,mj2 @ 0x7f8920f05d00]   Input stream #0:0 (video): 9 packets read (756128 bytes); 9 frames decoded; 0 decode errors;
[in#0/mov,mp4,m4a,3gp,3g2,mj2 @ 0x7f8920f05d00]   Input stream #0:1 (audio): 14 packets read (4779 bytes); 12 frames decoded; 0 decode errors (12288 samples);
[in#0/mov,mp4,m4a,3gp,3g2,mj2 @ 0x7f8920f05d00]   Total: 23 packets (760907 bytes) demuxed
[AVIOContext @ 0x7f8920f06100] Statistics: 1198190 bytes read, 2 seeks
Conversion failed!
Giacomo1968
  • 58,727

1 Answers1

2

I fixed this by uninstalling ffmpeg from conda and installing new one via homebrew

The problem was caused by wrong version of ffmpeg i had in my conda environment. ffmpeg -version:

ffmpeg version 6.1.1 Copyright (c) 2000-2023 the FFmpeg developers
built with clang version 14.0.6
configuration: --prefix=/Users/philipp/miniconda3 --cc=x86_64-apple-darwin13.4.0-clang --ar=x86_64-apple-darwin13.4.0-ar --nm=x86_64-apple-darwin13.4.0-nm --ranlib=x86_64-apple-darwin13.4.0-ranlib --strip=x86_64-apple-darwin13.4.0-strip --disable-doc --enable-swresample --enable-swscale --enable-openssl --enable-libxml2 --enable-libtheora --enable-demuxer=dash --enable-postproc --enable-hardcoded-tables --enable-libfreetype --enable-libharfbuzz --enable-libfontconfig --enable-libdav1d --enable-zlib --enable-libaom --enable-pic --enable-shared --disable-static --disable-gpl --enable-version3 --disable-sdl2 --enable-libopenh264 --enable-libopus --enable-libmp3lame --enable-libopenjpeg --enable-libvorbis --enable-pthreads --enable-libtesseract --enable-libvpx --enable-librsvg
libavutil      58. 29.100 / 58. 29.100
libavcodec     60. 31.102 / 60. 31.102
libavformat    60. 16.100 / 60. 16.100
libavdevice    60.  3.100 / 60.  3.100
libavfilter     9. 12.100 /  9. 12.100
libswscale      7.  5.100 /  7.  5.100
libswresample   4. 12.100 /  4. 12.100

It was old and built for x86-x64, not for Apple Silicon.

Giacomo1968
  • 58,727