[FFmpeg-trac] #10990(undetermined:new): "Assertion best_input >= 0 failed" IFF upsampling AND complex filtergraph
FFmpeg
trac at avcodec.org
Wed May 1 08:03:48 EEST 2024
#10990: "Assertion best_input >= 0 failed" IFF upsampling AND complex filtergraph
-------------------------------------+-------------------------------------
Reporter: Hunter | Type: defect
Hogan |
Status: new | Priority: normal
Component: | Version: git-
undetermined | master
Keywords: | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Summary of the bug:
If resampler is invoked at the start of the filtergraph to upsample, an
error will be thrown at the very end despite the output file being
successfully written. `Assertion best_input >= 0 failed at
src/fftools/ffmpeg_filter.c:2075`
How to reproduce:
I reproduced it with a few different wav files, including a white noise
file. All were stereo, however. Batch file and 22 logs attached. Only 4
logs have the error. The other logs are to compare changing only one
variable but not getting an error.
These quick tests all have filtergraphs loaded from a textfile, and I
don't think I tested it without a text file. These tests all use
`-/complex_filter` syntax, but I got the same error with the old syntax.
I did not test downsampling at the start of the filtergraph.
I first encountered this a couple of weeks ago after building version 7.
Prior to that, however, I don't think I ever had a filtergraph that
included upsampling and multiple input and/or output pads, so I am not
claiming the error was recently introduced.
If I recall correctly, originally, FFmpeg would crash, throw the error,
and not write a usable file. IIRC, the output file was the size I expected
(in bytes), but nothing could read it: ffprobe, ffmpeg, Goldwave all said
the file was garbage. I interpreted it to mean that the "headers" were
malformed. (By "headers", I probably mean metadata, but I don't know the
precise term here.)
I worked around it by scripting:
1. upsample my input file to a temp output file
2. filter as I want, output to a new temp
3. downsample
IIRC, it was necessary for me to downsample in a different filtergraph.
But, it now looks like downsampling doesn't throw an error.
Today, I rebuilt, and noticed the differences.
{{{
% FFmpeg -hide_banner -loglevel warning -stats
-i test_input_44100_2ch.wav -/filter_complex test_filter.txt
-map "[Z0Z_out]" -codec:a pcm_f32le
"output\\test_input_44100_2ch.wav_filtergraph_192000.wav"
}}}
ffmpeg version: media autobuilder suite, built today on Windows
{{{
ffmpeg version N-115035-g192f5b58b7-gb7debef3cc+4 Copyright (c) 2000-2024
the FFmpeg developers
built with gcc 13.2.0 (Rev6, Built by MSYS2 project)
configuration: --pkg-config=pkgconf --cc='ccache gcc' --cxx='ccache g++'
--ld='ccache g++' --extra-cxxflags=-fpermissive --extra-cflags=-Wno-int-
conversion --disable-autodetect --enable-amf --enable-bzlib --enable-
d3d11va --enable-dxva2 --enable-iconv --enable-lzma --enable-zlib
--enable-sdl2 --enable-libmp3lame --enable-libopus --enable-libvorbis
--enable-libvpx --enable-libx264 --enable-libx265 --enable-libdav1d
--enable-libaom --disable-debug --enable-libfdk-aac --enable-fontconfig
--enable-libass --enable-libfreetype --enable-libmysofa --enable-
libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg
--enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora
--enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-
libwebp --enable-libxml2 --enable-libzimg --enable-libshine --enable-gpl
--enable-avisynth --enable-libxvid --enable-libopenmpt --enable-version3
--enable-librav1e --enable-libgsm --enable-libvmaf --enable-libsvtav1
--enable-chromaprint --enable-frei0r --enable-libaribb24 --enable-libbs2b
--enable-libcaca --enable-libcdio --enable-libflite --enable-libfribidi
--enable-libgme --enable-libilbc --enable-libsvthevc --enable-libsvtvp9
--enable-libkvazaar --enable-libmodplug --enable-librtmp --enable-
librubberband --enable-libtesseract --enable-libxavs --enable-libzmq
--enable-libzvbi --enable-openal --enable-libcodec2 --enable-ladspa
--enable-libglslang --enable-vulkan --enable-libdavs2 --enable-libxavs2
--enable-libuavs3d --enable-opengl --enable-libopenh264 --enable-
libharfbuzz --enable-libfontconfig --enable-openssl --extra-
cflags=-DLIBTWOLAME_STATIC --extra-cflags=-DCACA_STATIC --extra-
cflags=-DMODPLUG_STATIC --extra-cflags=-DCHROMAPRINT_NODLL --extra-
cflags=-DZMQ_STATIC --extra-libs=-lpsapi --extra-cflags=-DLIBXML_STATIC
--extra-libs=-liconv --disable-w32threads --extra-cflags=-DKVZ_STATIC_LIB
--enable-nonfree --extra-cflags=-DAL_LIBTYPE_STATIC --extra-
cflags='-IC:/apps/media-autobuild_suite/local64/include' --extra-
cflags='-IC:/apps/media-autobuild_suite/local64/include/AL'
libavutil 59. 16.101 / 59. 16.101
libavcodec 61. 5.103 / 61. 5.103
libavformat 61. 3.103 / 61. 3.103
libavdevice 61. 2.100 / 61. 2.100
libavfilter 10. 2.101 / 10. 2.101
libswscale 8. 2.100 / 8. 2.100
libswresample 5. 2.100 / 5. 2.100
libpostproc 58. 2.100 / 58. 2.100
}}}
--
Ticket URL: <https://trac.ffmpeg.org/ticket/10990>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list