View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0000655 | Cinelerra-GG | Bug | public | 2024-04-30 17:04 | 2024-05-15 18:09 |
| Reporter | deim | Assigned To | PhyllisSmith | ||
| Priority | normal | Severity | crash | Reproducibility | always |
| Status | assigned | Resolution | open | ||
| Summary | 0000655: SIGSEGV AV1 AOM encode | ||||
| Description | When I encode to AV1 I often get SIGSEGV: 99% ETA: 0:00:10 ** segv at 0x7fe323058ce0 in pid 1482, tid 8658 dump attached | ||||
| Tags | AV1, Crash, encode, libAOM | ||||
| Attached Files | cinelerra_batch1482.dmp (4,096 bytes)
** segv at 0x7fe323058ce0 in pid 1482, tid 8658
created on Tue Apr 30 15:37:02 2024
by 1000:1000 deim()
OS:
NAME=Gentoo
ID=gentoo
PRETTY_NAME="Gentoo Linux"
ANSI_COLOR="1;32"
HOME_URL="https://www.gentoo.org/"
SUPPORT_URL="https://www.gentoo.org/support/"
BUG_REPORT_URL="https://bugs.gentoo.org/"
VERSION_ID="2.14"
CPUS: 8
CPUINFO:
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 60
model name : Intel(R) Core(TM) i7-4770K CPU @ 3.50GHz
stepping : 3
microcode : 0x28
cpu MHz : 4107.969
cache size : 8192 KB
physical id : 0
siblings : 8
core id : 0
cpu cores : 4
apicid : 0
initial apicid : 0
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid sse4_1 sse4_2 movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm cpuid_fault epb pti ssbd ibrs ibpb stibp tpr_shadow flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid xsaveopt dtherm ida arat pln pts vnmi md_clear flush_l1d
vmx flags : vnmi preemption_timer invvpid ept_x_only ept_ad ept_1gb flexpriority tsc_offset vtpr mtf vapic ept vpid unrestricted_guest ple
bugs : cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf mds swapgs itlb_multihit srbds mmio_unknown
bogomips : 7000.49
clflush size : 64
cache_alignment : 64
address sizes : 39 bits physical, 48 bits virtual
power management:
processor : 1
vendor_id : GenuineIntel
cpu family : 6
model : 60
THREADS:
thread 0x7fe27dffb6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe27e7fc6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe27effd6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe27f7fe6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe27ffff6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe294ff96c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2957fa6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe295ffb6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2967fc6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe296ffd6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe2977fe6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe297fff6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe29cff96c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe29d7fa6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe29dffb6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe29e7fc6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe29effd6c0, owner 0x7fe320d53840, 7HueUnit
thread 0x7fe29f7fe6c0, owner 0x7fe320d53840, 13SharpenEngine
thread 0x7fe30880b6c0, owner 0x7fe320d53840, 13SharpenEngine
thread 0x7fe29ffff6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2b8ff16c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2b97f26c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2b9ff36c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2ba7f46c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2baff56c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2bb7f66c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2bbff76c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2bffff6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2c8ff96c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2c97fa6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2c9ffb6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe2ca7fc6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe302ffd6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe3037fe6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe303fff6c0, owner 0x7fe320d53840, 10DirectUnit
thread 0x7fe300ff96c0, owner 0x7fe320d53840, 6FFMPEG
thread 0x7fe2caffd6c0, owner 0x7fe31c7d36c0, N7BC_Xfer6SlicerE
thread 0x7fe2cb7fe6c0, owner 0x7fe31c7d36c0, N7BC_Xfer6SlicerE
thread 0x7fe2cbfff6c0, owner 0x7fe31c7d36c0, N7BC_Xfer6SlicerE
thread 0x7fe31afd06c0, owner 0x7fe320d53840, N7BC_Xfer6SlicerE
thread 0x7fe31b7d16c0, owner 0x7fe320d53840, N7BC_Xfer6 | ||||
|
|
@deim Unfortunately it is not failing for me, but I will try some different input. So that I make sure I am using the same parameters, I am rendering using these: File format: ffmpeg webm Video wrench: av1.webm with just the defaults Audio wrench: not checked If I should be testing with different parameters, please reply what they are. Do you have a small test case that almost always fails? If so, please add it here or if concerned about publicly sharing, you can send to me privately at: phylsmith2017@gmail.com |
|
|
I did some tests with the appimage 20240229. The av1.webm preset works but with reduced performance (5 fps rendering). The preset av1_svt.webm does not work with the appimage because it is not active by default. I have a processor that supports AVX2 (similar to your) and in my CinGG compiled with svt the rendering comes in at 35 fps). The av1_vaapi.webm preset is not active in my system because the GPU does not support it. We would need to know what version of CinGG you use and what presets you tried. As for the dump, I'm sorry but I can't interpret it. Try running from terminal and report the error messages that appear there. |
|
|
I'm using this custom two-pass settings in batch: cin -r batch.j pass1of2_av1.webm (345 bytes)
webm libaom-av1 # this codec codes less than one frame per sec # and so even a few seconds of video can take # a very long time to encode cin_stats_filename /tmp/cin_video_av1_webm flags +pass1 b 2048k #minrate=512k #maxrate=1485k #tile-columns=2 g 819 #threads=8 #quality=good #crf=32 #speed=4 cpu-used 5 row-mt 1 tiles 2x2 strict -2 threads 8 pass2of2_av1.webm (345 bytes)
webm libaom-av1 # this codec codes less than one frame per sec # and so even a few seconds of video can take # a very long time to encode cin_stats_filename /tmp/cin_video_av1_webm flags +pass2 b 2048k #minrate=512k #maxrate=1485k #tile-columns=2 g 819 #threads=8 #quality=good #crf=32 #speed=4 cpu-used 5 row-mt 1 tiles 2x2 strict -2 threads 8 |
|
|
Also since I'm on Gentoo I'm using custom ebuild actually as in attachment with media-libs/libaom version 3.8.1 (I suppose Cinelerra takes system libaom) (just for info I'm preparing some quality/speed/size comparison of some codecs if You're interested I could share when it's done) cinelerraGG-202402.ebuild (1,856 bytes)
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="The most advanced non-linear video editor and compositor - Good Guy's version"
HOMEPAGE="https://www.cinelerra-gg.org/"
IUSE="+pref opus vpx +fdk vaapi vdpau"
RDEPEND=">=sci-libs/fftw-3
>=media-libs/libtheora-1.1:="
DEPEND="${RDEPEND}
app-arch/xz-utils
virtual/pkgconfig
dev-lang/nasm
dev-util/ctags
fdk? ( media-libs/fdk-aac )
media-libs/jbigkit"
inherit git-r3
# EGIT_REPO_URI="git://git.cinelerra-cv.org/goodguy/cinelerra.git"
EGIT_REPO_URI="git://git.cinelerra-gg.org/goodguy/cinelerra"
EGIT_CLONE_TYPE=shallow
if [[ ${PV} != *9999* ]]; then
EGIT_COMMIT="b7f6f61e450ed50974930a07e0337f07c120f29d"
fi
#else
# SRC_URI=""
KEYWORDS="~amd64 ~arm ~arm64 ~x86"
#fi
SLOT="0"
S="${WORKDIR}"/${P}/cinelerra-5.1
PATCHES=(
)
src_prepare() {
./autogen.sh
default
}
src_configure() {
CONF="$(use_enable opus)"
if use fdk ; then
export FFMPEG_EXTRA_CFG=" --enable-libfdk-aac --enable-nonfree"
export EXTRA_LIBS=" -lfdk-aac"
fi
if use pref ; then
CONF="${CONF} --prefix=/usr/local_cin"
fi
# if use opus ; then
# CONF="${CONF} --enable-opus"
# fi
if use vpx ; then
CONF="${CONF} --enable-libvpx"
fi
CONF="${CONF} $(use_with vaapi) ${CONF} $(use_with vdpau)"
econf ${CONF}
}
src_compile() {
emake
}
src_install() {
emake -j1 -l1 DESTDIR="${D}" install
# patch better render templates
tar -xzf "${FILESDIR}"/fqt_mp4.tar.gz -C "${D}"/usr/share/cin/ffmpeg/
if use pref ; then
mkdir -p "${D}"/etc/env.d/
cp "${FILESDIR}"/99local_cin "${D}"/etc/env.d/
fi
}
pkg_postinst() {
if use pref ; then
elog "Don't forget to run env-update if first install"
fi
}
|
|
|
It doesn't solve your crashing problem, but try modifying the e-build by inserting "--enable-libsvtav1", then use the "av1_svt.webm" preset (which you can customize as needed). Libaom is really too slow in encoding. However, CinGG uses its own internal libaom library and is therefore not the most up-to-date: /cinelerra5/cinelerra-5.1/thirdparty/libaom-v3.8.0 I don't know if disabling libaom in the e-build makes it possible to use system libaom. I am very interested in your comparative codec tests. Thanks. |
|
|
IgorBeg also is having no problem as reported on the Mailing List: "On my UbuntuStudio_16.04 using CinGG-20240229-x86_64-older-distros.AppImage NO crash BUT,... it works for FFMPEG | webm, video-> av1.webm," I will be testing with the 2 pass parameters to see if I can get it to fail today. |
|
|
@deim @Andrea_Paz Using deim's pass1/pass2 avi/webm render formats, I am able to easily reproduce a render failure on pass1 although it does not crash for me. I see "void AssetPicon::create_objects():" in the terminal window. This is definitely a problem but I can not say it is the same as deim's. Workaround fix that for me results in a render completion (pass1 and pass2) is to "turn off Draw Media" during the render in the patchbay -- I assume for all video tracks but I only had 1 video track and no audio tracks. "Draw Media" is the 3rd icon from the left after "Play Track" and "Arm Track". Deim, could you test this workaround? It does not fail for me on small resolution files. Input file is Elecard's 4K example which is of size 409458359 and I renamed as cows_4k.webm. Maybe Andrea can test on Arch? My test before turning off "Draw Media" would fail on pass1 in about 8 minutes. When it worked, the first pass took 5 minutes and the second pass took 1 hour 32 minutes. |
|
|
Doing the encoding from the CinGG GUI, using the presets from Deim (2 pass), and using the Render batch without Render Farm, I encountered no problems and the resulting rendering works fine. From the terminal with cin -r does not work: ** rendered 0 frames in 0.000 secs, 0.000 fps Session time: 0:00:00 Cpu time: user: 0:00:00.066 sys: 0:00:00.020 I am not familiar with batch renders and have never done terminal renders; so I am definitely wrong in something. |
|
|
Batch rendering is sensitive to actual position, in-out points and selections in project file. Best to set actual position to start and unset in-out points and selections - it's feature not a bug :-) I'll try svt-av1 codec to see if problem could be there also. BTW I'm possibly done with little bench program and now I'm trying to compare some codecs. I'll share results when it's done. |
|
|
How could be please allowed use of system libraries for encoding for libsvtav1? I noticed that the others are from OS and labeled as shared I'm puzzled since I don't know what values to add (I wanna give recent versions try): --- a/configure.ac +++ b/configure.ac @@ -467,7 +467,7 @@ [ usr/local/lib*/libaom*.a ], [ usr/local/include ]) -PKG_3RD([libsvtav1],[no], +PKG_3RD([libsvtav1],[auto], [libsvtav1-v1.8.0], [ usr/local/lib*/libSvtAv1Enc.a ], [ usr/local/include/svt-av1 ]) @@ -668,6 +668,8 @@ CHECK_HEADERS([opus], [libopus headers], [opus/opus_multistream.h]) CHECK_LIB([libaom], [aom], [aom_codec_version]) CHECK_HEADERS([libaom], [libaom headers], [aom/aom.h]) +CHECK_LIB([SvtAv1Enc], [SvtAv1Enc], [version]) +CHECK_HEADERS([SvtAv1Enc], [SvtAv1Enc headers], [svt-av1/EbSvtAv1Enc.h]) CHECK_LIB([dav1d], [dav1d], [dav1d_version]) CHECK_HEADERS([dav1d], [libdav1d headers], [dav1d/dav1d.h]) CHECK_LIB([libwebp], [webp], [WebPGetEncoderVersion]) cat /usr/lib64/pkgconfig/SvtAv1Enc.pc prefix=/usr exec_prefix=${prefix} includedir=${prefix}/include libdir=${exec_prefix}/lib64 Name: SvtAv1Enc Description: SVT (Scalable Video Technology) for AV1 encoder library Version: 2.0.0 Libs: -L${libdir} -lSvtAv1Enc Libs.private: -lpthread -lm Cflags: -I${includedir}/svt-av1 -DEB_DLL Cflags.private: -UEB_DLL |
|
|
I suppose the error could be caused by usage of system libraries found in compile time. I learned some codec libraries could be included if there is supplied configuration for them in cmake config file. => So I suppose this behavior is feature not a bug. Still I would love to figure out how to set svt-av1 system library to be recognized also since I like testing new versions of libraries promising speed and efficiency improvements. How difficult is adding new versions? libsvt-av1 2.0.0 https://gitlab.com/AOMediaCodec/SVT-AV1/-/releases libaom 3.9.0 https://gitlab.com/webmproject/libaom/-/tags Thanks for effort :-) |
|
|
Following Andrew's instructions, I have an old ./configure made specifically to use only the system libraries, including ffmpeg (that is, excluding all .../thirdparty). It is as follows: ./configure --with-single-user --disable-static-build --without-thirdparty --without-libdpx--disable-libwebp --without-nv --without-lv2 Libaom 3.9.0 and system libsvtav1 2.0.0 are recognized and work (with av1.webm and av1_svt.webm presets; I haven't tried your “two pass” presets...). Performance seems slightly worse to me than with CinGG's internal libraries. |
|
|
I also tried batch rendering two pass with your presets and they work fine. In the first line of presets I replaced “libaom-av1” with “libsvtav1”. I still can't use the command line render... |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2024-04-30 17:04 | deim | New Issue | |
| 2024-04-30 17:04 | deim | Tag Attached: AV1 | |
| 2024-04-30 17:04 | deim | Tag Attached: Crash | |
| 2024-04-30 17:04 | deim | Tag Attached: encode | |
| 2024-04-30 17:04 | deim | Tag Attached: libAOM | |
| 2024-04-30 17:04 | deim | File Added: cinelerra_batch1482.dmp | |
| 2024-05-01 03:04 | PhyllisSmith | Assigned To | => PhyllisSmith |
| 2024-05-01 03:04 | PhyllisSmith | Status | new => acknowledged |
| 2024-05-01 03:04 | PhyllisSmith | Note Added: 0005614 | |
| 2024-05-01 10:00 | Andrea_Paz | Note Added: 0005615 | |
| 2024-05-01 10:02 | Andrea_Paz | Note Edited: 0005615 | |
| 2024-05-01 10:03 | Andrea_Paz | Note Edited: 0005615 | |
| 2024-05-02 09:47 | deim | File Added: pass1of2_av1.webm | |
| 2024-05-02 09:47 | deim | File Added: pass2of2_av1.webm | |
| 2024-05-02 09:47 | deim | Note Added: 0005616 | |
| 2024-05-02 09:52 | deim | File Added: cinelerraGG-202402.ebuild | |
| 2024-05-02 09:52 | deim | Note Added: 0005617 | |
| 2024-05-02 10:58 | Andrea_Paz | Note Added: 0005618 | |
| 2024-05-05 15:40 | PhyllisSmith | Note Added: 0005619 | |
| 2024-05-06 01:38 | PhyllisSmith | Status | acknowledged => feedback |
| 2024-05-06 01:38 | PhyllisSmith | Note Added: 0005620 | |
| 2024-05-06 01:40 | PhyllisSmith | Note Edited: 0005620 | |
| 2024-05-06 15:39 | Andrea_Paz | Note Added: 0005621 | |
| 2024-05-08 17:24 | deim | Note Added: 0005623 | |
| 2024-05-08 17:24 | deim | Status | feedback => assigned |
| 2024-05-08 20:23 | deim | Note Added: 0005625 | |
| 2024-05-15 12:11 | deim | Note Added: 0005631 | |
| 2024-05-15 14:03 | Andrea_Paz | Note Added: 0005632 | |
| 2024-05-15 18:09 | Andrea_Paz | Note Added: 0005633 |