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

Ability to trade off guetzli+mozjpeg's "perfect optimization" for a faster "mozjpeg-only" live encoding mode #15

Open
nekohayo opened this issue Oct 21, 2021 · 4 comments
Labels
enhancement New feature or request

Comments

@nekohayo
Copy link

Bonjour,
Yoga is a very interesting app, and it could almost replace Squoosh for me, were it not for the excruciatingly slow guetzli-based JPEG encoding.

I would like to have the ability to have Yoga encode purely with MozJPEG instead of needing all this fancy AI perceptual encoding stuff. I value mozjpeg's 0.5 second encoding time much more than absolute perfect quality (because if I was looking for perfection, I'd be doing JPEG XL ;) Waiting 2 minutes per HD JPEG is too much for me, especially when you are batch-encoding hundreds of them (I don't want to wait hours with my 8-cores Xeon pegged burning at 100% utilization, for what would take a minute or two with mozjpeg), or when I am encoding them one by one on a "as needed" basis (like I would do with Squoosh) when doing web integration work; in that particular case I am processing images one by one, as they come and as the website is being built, so having to wait over a minute for each image interrupts my work.

I would like to be able to set a standard preferred size to downsize to, standard preferred encoder (mozjpeg for JPEGs), drag and drop files into the app, hit convert... actually, mozjpeg is so fast to convert that you would not even need to have a convert button, you could create and live-overwrite/update the file in realtime!

@nekohayo nekohayo added the enhancement New feature or request label Oct 21, 2021
@flozz
Copy link
Owner

flozz commented Nov 22, 2021

I am thinking about this, but I do not know what I will do at the end... I want to keep YOGA and YOGA Image Optimizer as simple as possible, and adding options make it more complicated... I have to make choice between options vs simplicity.

@nekohayo
Copy link
Author

I totally respect that "single code pathway" maintenance approach. If it is any help, my 2¢ biased opinion is that it should be mozjpeg, trading off "absolute perfection with 2-10% gains (?) that most humans can't perceive" for "150-200x the speed", but maybe that's just me :)

@nekohayo
Copy link
Author

A new backwards-compatible contender intended to replace mozjpeg, from one of the authors of JPEG XL: https://opensource.googleblog.com/2024/04/introducing-jpegli-new-jpeg-coding-library.html

This might be the perfect tradeoff you're looking for... reportedly better than mozjpeg, but just as fast (so an order of magnitude faster than guetzli), if I understand correctly.

@flozz
Copy link
Owner

flozz commented Apr 22, 2024

jpegli is already on my TODO list for YOGA. I have to test it to check its efficiency, I will probably have to implement Pyhon bindings for it and to add it to YOGA if everything is OK. And only then, I may be able to update YOGA Image Optimizer (the GUI) with it shipped in. :)

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

No branches or pull requests

2 participants