Comments (7)
Do you mean the visualization of the predictors that were chosen, as shown on slide 71 of https://docs.google.com/presentation/d/1LlmUR0Uoh4dgT3DjanLjhlXrk_5W2nJBDqDAMbhe8v8/edit#slide=id.ga352fd7e04_0_12 ?
You can get something like that by setting kWantDebug = true
in the beginning of jxl/modular/encoding/enc_encoding.cc
, and then doing something like benchmark_xl --input=image.png --codec=jxl:m:tortoise:g3 --debug_image_dir=outputdir
. This produces debug images per group and per channel (setting g3
makes the groups larger so you don't get too many of them), so you'll have to figure out a way to combine them into a big image.
from libjxl.
thanks for your answer @jonsneyers! In fact, I am trying to extract the predicted value by JPEG-XL for each pixel, and not the predictor choice itself. According to the overview paper, "(..) when predicting a value in position (x, y), the adaptive predictor looks at the maximum error that each prediction mode would have produced on pixels (x−1, y), (x, y−1) and (x−1, y−1), and chooses the prediction mode that is expected to produce the least amount of error." Based on this, is it possible to access the predicted value at each position?
Thanks
from libjxl.
There's currently no code to dump that, but it could be done. I'm not sure what exactly you would want to see though: the predicted value at every pixel would usually be quite close to the actual value since the prediction happens per pixel (so it sees the corrected values on the top and left). It might be more interesting to do something like "show how the predictor would have completed this subrectangle without further information" (i.e. setting all residuals to zero there).
Also: I don't know what paper you're looking at, but the "adaptive predictor" is not in the spec anymore. There's the weighted predictor, and there are a bunch of other predictors, and the predictor to be used is part of the context model (the MA tree leaf nodes).
from libjxl.
Here is a little playground where you can see how different predictors would continue some pattern:
from libjxl.
I added a slide (slide number 77) to show some examples of how some of the predictors would work: https://docs.google.com/presentation/d/1LlmUR0Uoh4dgT3DjanLjhlXrk_5W2nJBDqDAMbhe8v8/edit#slide=id.gde87dfbe27_0_140
from libjxl.
I really appreciate your feedback and effort on this question. I am now sure that I will be able to extract what I want and I will dig into the code in the next days to dump those predicted samples! :-)
from libjxl.
OK, closing this issue, feel free to reopen if you have further questions.
from libjxl.
Related Issues (20)
- cjxl fails with "JxlEncoderAddJPEGFrame() failed" for a valid JFIF file HOT 2
- Compression with --resampling=2 dramattically slower than other values
- What exactly resampling does? HOT 4
- libjxl should generate ICC profiles that use CICP tag when appropriate HOT 3
- Different defaults for SSIMULACRA2 and Butteraugli between APIs and executables HOT 4
- cjxl not properly converting the ICC profiles of some JPGs or djxl not properly decoding the converted JXLs with ICC profile back to JPG HOT 4
- The -p option (progressive) with jpg input files results in error and no image being put out, even when it is just on its own without any other options. HOT 3
- Pixel-to-jpeg is faster than Jpeg reconstruction? HOT 2
- cant open in photoshop HOT 3
- Wasm performance is much worse HOT 14
- cjpegli fails with nondescript error message if input PNG contains alpha HOT 2
- Utilities do not output useful debug and error messages, even with multiple `-v` arguments HOT 2
- Losslessly recompressing JXL turns enum tags into ICC profiles HOT 4
- Trouble linking wasm_demo with jpeg encoder HOT 5
- GitLab's wg1/jpeg-xl is not mirroring recent commits, out-of-date for several months HOT 2
- a recent commit breaks it building with MABS (build system for FFmpeg) HOT 3
- Issues with building and testing in mac OS. HOT 6
- Idea: libjxl in the Linux kernel HOT 14
- Example decode_progressive contains code that could lead to buffer overflow
- num_threads HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from libjxl.