This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

[INFO] Feature Request: Per scene encoding
#11
Nope, path is okay. I just made a typo.
Instead of '-vmaf-model-path' it needs to be '--vmaf-model-path'. Wink
-> will fix and send you a new link to a dev once I recompiled and packaged it.

Cu Selur
Reply
#12
Now it seems to work  Smile 
(didn't finished the encoding because it needed 100x the time of source with currently settings -I'll read the previous articles linked before change it)
Reply
#13
Edit: (in this case is better to edit or make a new reply? -edits are notified?-)

I read the articles and I concluded to add the following arguments in the encoding
--passes=2 --lag-in-frames=48 --enable-cdef=1 --enable-restoration=0 --enable-qm=1
But it seems it is not possible because --passes is already set to 1 in Constant Quality mode (and there isn't the two-passes one in hybrid)

Also, is right that Tune: none and Tune: VMAF with pre-processing have the same arguments? (without vmaf model path)
Reply
#14
Quote:(in this case is better to edit or make a new reply? -edits are notified?-)
Assuming there is more than a few minutes after your first post, make a new reply.

Quote:But it seems it is not possible because --passes is already set to 1 in Constant Quality mode (and there isn't the two-passes one in hybrid)
There is no contant quality rate control mode.
--end-usage=<arg>           Rate control mode
                                             vbr, cbr, cq, q
vbr = variable bit rate
cbr = constrant bit rate
cq = constrained quality
q = constant quantizer

Hybrid offers '--passes=2' with 'vbr' and 'cq' as 2pass doesn't make sense for constant quantizer or constant bit rate rate control.

Also, is right that Tune: none and Tune: VMAF with pre-processing have the same arguments? (without vmaf model path)
No that's a bug. Smile I will look at it. Smile (it's a typo, the option in the dropdown is missing an 'g' at the end. Smile)

Cu Selur
Reply
#15
(09.04.2022, 10:04)Selur Wrote:
Quote:But it seems it is not possible because --passes is already set to 1 in Constant Quality mode (and there isn't the two-passes one in hybrid)
There is no contant quality rate control mode.
            --end-usage=<arg>           Rate control mode
                                             vbr, cbr, cq, q
vbr = variable bit rate
cbr = constrant bit rate
cq = constrained quality
q = constant quantizer

Hybrid offers '--passes=2' with 'vbr' and 'cq' as 2pass doesn't make sense for constant quantizer or constant bit rate rate control.

Sorry I mean 'q' constant quantizer. Based on the previous linked articles the encoder need 2pass to enable scene-detection.

Quote:2-pass was extremely important in vpxenc-vp9, as not only was it the only way for the encoder to utilize scene-detection, but it also allowed for the placement of alternate reference frames. Not doing that seriously cripples the encoder in what it can do. It also disables other stuff, but this also applies to aomenc-av1, so letÂ’s move on to the AV1 encoder again.

In aomenc-av1, 2-pass allows for these things in particular:
- More advanced scene detection when the lookahead buffer is high enough.
- Partition recoding: the encoder itself can decide whether or not to redo partition selection based on the preset on other conditions, resulting in better partition selection.
- Better auto-alt-ref placement through the encoded stream.

It also does some more advanced things, so IÂ’d advise keeping it on if you can

So yeah, always use 2-pass if you can. Luckily, itÂ’s set by default in the standalone encoder, so you donÂ’t need to do anything if you utilize a utility like nmkoder or av1an
Reply
#16
Have you actually tried using 2pass with constant quantizer?
With a fixed quantizer, there should be no rate control, so I don't see how you could benefit from running 2passes.

Cu Selur
Reply
#17
(08.04.2022, 17:00)Werve Wrote: Now it seems to work  Smile 
(didn't finished the encoding because it needed 100x the time of source with currently settings -I'll read the previous articles linked before change it)

Unfortunately it don't work.
Almost at the end of encoding it says Crashed with exit status 1

Quote:Have you actually tried using 2pass with constant quantizer?

Not yet, I'm still experimenting
Reply
#18
Debug output shows that
after over an hour and encoding 226 frames:
22673F Pass 1/1 frame  226/178  1378917B 4556693 ms 2.98 fpm [ETA  unknown]
the encoder crashes with:
process finished with exitcode: -1073740940 and exitStatus: 1
Since the encoding starts, the calls must be okay
doing a quick test with;
ffmpeg -y -loglevel fatal -noautorotate -nostdin -threads 8 -i "G:\TestClips&Co\files\test.avi" -map 0:0 -an -sn -vf zscale=rangein=tv:range=tv -pix_fmt yuv420p10le -strict -1 -vsync 0 -f yuv4mpegpipe - | aomenc --passes=1 --pass=1 --end-usage=cq --cq-level=10 --target-bitrate=15000 --profile=0 --cpu-used=5 --min-q=1 --max-q=63 --undershoot-pct=0 --overshoot-pct=0 --buf-sz=6 --buf-initial-sz=4 --buf-optimal-sz=5 --drop-frame=0 --kf-min-dist=0 --kf-max-dist=250 --auto-alt-ref=0 --noise-sensitivity=0 --denoise-noise-level=0 --sharpness=0 --static-thresh=0 --tune-content=default --tune=vmaf_without_preprocessing --vmaf-model-path="I:/Hybrid/64bit/vmaf_v0.6.1.json" --tile-columns=6 --tile-rows=2 --frame-boost=0 --aq-mode=1 --min-gf-interval=0 --max-gf-interval=2 --threads=64 --width=640 --height=352 --input-bit-depth=10 --bit-depth=10 --denoise-noise-level=0 --min-partition-size=4 --max-partition-size=128 --sb-size=0 --max-reference-frames=7 --disable-trellis-quant=0 --enable-tpl-model=1 --enable-keyframe-filtering=0 --force-video-mode=1 --reduced-tx-type-set=1 --use-intra-dct-only=0 --use-inter-dct-only=0 --use-intra-default-tx-only=0 --quant-b-adapt=1 --coeff-cost-upd-freq=0 --mode-cost-upd-freq=0 --mv-cost-upd-freq=0 -o "E:\Temp\2022-04-09@14_42_18_5410_01.ivf" -
which seems to work fine.

So my guess is that either:
  • something is wrong with the source a frame around 226
  • something is interfering with the encoding process (or the communication between the decoder and the encoder)
  • you are running out of ram (or space)
  • your system is overclocked (which causes memory issues)
  • there is some bug in aomenc
-> this does not look like a bug in Hybrid.

Cu Selur
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)