styler00dollar / VSGAN-tensorrt-docker

Using VapourSynth with super resolution and interpolation models and speeding them up with TensorRT.
BSD 3-Clause "New" or "Revised" License
288 stars 30 forks source link

libsvtav1 fast-decode=1 not supported ? Also Svt[warn]: Failed to set thread priority error. #21

Closed Anon1337Elite closed 1 year ago

Anon1337Elite commented 1 year ago

[libsvtav1 @ 0x55b234b77440] Error parsing option fast-decode: 3.

Svt[warn]: Failed to set thread priority like 100 times.

f"vspipe -c y4m inference_batch.py --arg source={f} - | ffmpeg -i pipe: -c:v libsvtav1 -preset 7 -crf 35 -svtav1-params fast-decode=1 {mux_path}" )

banjaminicc commented 1 year ago

[libsvtav1 @ 0x55b234b77440] Error parsing option fast-decode: 3.

Svt[warn]: Failed to set thread priority like 100 times.

f"vspipe -c y4m inference_batch.py --arg source={f} - | ffmpeg -i pipe: -c:v libsvtav1 -preset 7 -crf 35 -svtav1-params fast-decode=1 {mux_path}" )

If you dont specify any svt av1 params it works?

Anon1337Elite commented 1 year ago

Another Error, it just randomly stops outputing, i guess ill just avoid this for now, and use something else, this is the error it stops after few mintues:

Error: fwrite() call failed when writing frame: 1841, plane: 0, errno: 32 Output 1850 frames in 451.75 seconds (4.10 fps)

Anon1337Elite commented 1 year ago

[libsvtav1 @ 0x55b234b77440] Error parsing option fast-decode: 3. Svt[warn]: Failed to set thread priority like 100 times. f"vspipe -c y4m inference_batch.py --arg source={f} - | ffmpeg -i pipe: -c:v libsvtav1 -preset 7 -crf 35 -svtav1-params fast-decode=1 {mux_path}" )

If you dont specify any svt av1 params it works?

i dont think it works since the console tells u unrecognized command.

styler00dollar commented 1 year ago

ffmpeg -i test.mp4 -c:v libsvtav1 -preset 7 -crf 35 -svtav1-params fast-decode=1 test_out.mp4 does render a video.

Svt[info]: -------------------------------------------
Svt[info]: SVT [version]:       SVT-AV1 Encoder Lib v1.4.1-64-gd5e1e2a5-dirty
Svt[info]: SVT [build]  :       GCC 12.2.1 20230111      64 bit
Svt[info]: LIB Build date: Feb  4 2023 00:54:10
Svt[info]: -------------------------------------------
Svt[info]: Number of logical cores available: 16
Svt[info]: Number of PPCS 136
Svt[info]: [asm level on system : up to avx2]
Svt[info]: [asm level selected : up to avx2]
Svt[info]: -------------------------------------------
Svt[info]: SVT [config]: main profile   tier (auto)     level (auto)
Svt[info]: SVT [config]: width / height / fps numerator / fps denominator               : 1920 / 1080 / 24 / 1
Svt[info]: SVT [config]: bit-depth / color format                                       : 8 / YUV420
Svt[info]: SVT [config]: preset / tune / pred struct                                    : 7 / PSNR / random access
Svt[info]: SVT [config]: gop size / mini-gop size / key-frame type                      : 161 / 32 / key frame
Svt[info]: SVT [config]: BRC mode / rate factor                                         : CRF / 35
Svt[info]: -------------------------------------------
Svt[warn]: Failed to set thread priority
Svt[warn]: Failed to set thread priority
...

Seems like new compiled svt now spams Failed to set thread priority, but it procudes a video. It randomly stopping is most likely related to hardware usage like running out of ram or full drive. I hope just recompiling svt will solve that warning and won't write Svt[warn]: Failed to set thread priority.

Anon1337Elite commented 1 year ago

ffmpeg -i test.mp4 -c:v libsvtav1 -preset 7 -crf 35 -svtav1-params fast-decode=1 test_out.mp4 does render a video.

Svt[info]: -------------------------------------------
Svt[info]: SVT [version]:       SVT-AV1 Encoder Lib v1.4.1-64-gd5e1e2a5-dirty
Svt[info]: SVT [build]  :       GCC 12.2.1 20230111      64 bit
Svt[info]: LIB Build date: Feb  4 2023 00:54:10
Svt[info]: -------------------------------------------
Svt[info]: Number of logical cores available: 16
Svt[info]: Number of PPCS 136
Svt[info]: [asm level on system : up to avx2]
Svt[info]: [asm level selected : up to avx2]
Svt[info]: -------------------------------------------
Svt[info]: SVT [config]: main profile   tier (auto)     level (auto)
Svt[info]: SVT [config]: width / height / fps numerator / fps denominator               : 1920 / 1080 / 24 / 1
Svt[info]: SVT [config]: bit-depth / color format                                       : 8 / YUV420
Svt[info]: SVT [config]: preset / tune / pred struct                                    : 7 / PSNR / random access
Svt[info]: SVT [config]: gop size / mini-gop size / key-frame type                      : 161 / 32 / key frame
Svt[info]: SVT [config]: BRC mode / rate factor                                         : CRF / 35
Svt[info]: -------------------------------------------
Svt[warn]: Failed to set thread priority
Svt[warn]: Failed to set thread priority
...

Seems like new compiled svt now spams Failed to set thread priority, but it procudes a video. It randomly stopping is most likely related to hardware usage like running out of ram or full drive. I hope just recompiling svt will solve that warning and won't write Svt[warn]: Failed to set thread priority.

the random stopping has happened for me on longer videos, i have plenty of space and ram, 32GB Ram i9 9900k 2070s, Either way i will be sticking with x265 once the 10bit gets fixed. Seems weird it would just stop.

Anon1337Elite commented 1 year ago

Got randomly exited on new version, not sure what is causing it tbh, is it the encode or the upscale. CPU is at like 70-90% its not even capping, GPU is max but it still exited with no errors shown just

Error: fwrite() call failed when writing frame: 3389, plane: 1, errno: 32 Output 3398 frames in 717.94 seconds (4.73 fps)

Edit:

RAM is actually going carzy i have 27GBs allocated and its using all of it, maybe that is the issue, is there a way to control this in some way ?

Edit 3 : i think it was thread_queue_size 100 , what even this does. i had it set to 5k not to annoy me lol. Ill report back if i crash, i just removed the whole thing

Edit4: Didnt crash

styler00dollar commented 1 year ago

Fixed in Failed to set thread priority in https://github.com/styler00dollar/VSGAN-tensorrt-docker/commit/4bf410d02d74a2d88a848ffc0c9794d3e1d42f13. Does not show after recompiling ffmpeg and using this dockerfile. Dockerhub image will be updated soon. Closing.