Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: XPSNR (or other alternative image metric) #244

Closed
gitoss opened this issue Dec 17, 2024 · 1 comment · Fixed by #251
Closed

Feature Request: XPSNR (or other alternative image metric) #244

gitoss opened this issue Dec 17, 2024 · 1 comment · Fixed by #251

Comments

@gitoss
Copy link

gitoss commented Dec 17, 2024

Referencing #167 and #104 ...

... because adding SSIMULACRA2 seems to be non-trivial, how about XPSNR (that was already mentioned in one of the other tickets)?

I'm looking for an alternative metric to compare images, and have been told VMAF doesn't condsider chroma at all. Edit: Though the Fgh page talks about images, codec wiki says XPSNR "video-focused" - doh. https://wiki.x266.mov/docs/metrics/XPSNR

XPSNR (https://github.com/fraunhoferhhi/xpsnr) has already been added to ffmpeg (https://ffmpeg.org/ffmpeg-filters.html#xpsnr-1) and seems to work fine out of the box.

I didn't look what ab-av1 does with ffmpeg, but the XPSNR score is easy to pull from stdout or the XPSNR logfile.

I'm still resistant to re-writing ab-av1's logic in a script to use command line tools like ssimulacra2.exe or butteraugli.exe because ab-av1 works just fine :-)

ffmpeg -i 1.png -i 2.png -lavfi xpsnr="stats_file=-" -f null -

[Parsed_xpsnr_0 @ 0000000000420f80] XPSNR  r: 40.6130
XPSNR average, 1 frames  r: 40.6130  g: 41.0275  b: 40.6961  (minimum: 40.6130)
[out#0/null @ 0000000000421c40] video:0KiB audio:0KiB subtitle:0KiB other streams:0KiB global headers:0KiB muxing overhead: unknown
frame=    1 fps=0.0 q=-0.0 Lsize=N/A time=00:00:00.04 bitrate=N/A speed=0.0844x

xpsnr.log

@alexheretic
Copy link
Owner

Thanks for adding the ffmpeg call example and motivation. Based on this it should be possible to provide xpsnr support. I will experiment when I get some time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants