6 ms·
Upon more investigation, these numbers are certainly machine generated. Here is an example: A constant lookup table is used for determining the importance of
by londons_explore 10y ago
Upon more investigation, these numbers are certainly machine generated. Here is an example:
A constant lookup table is used for determining the importance of a change vs distance. Seperate tables are used for vertical and horizontal distances (I guess eyes might be slightly more sensitive to vertical edges than horizontal ones?).
Those tables are wildly different in magnitude:
static const double off = 1.4103373714040413; // First value of Y lookup table
static const double off = 11.38708334481672; // First value of X lookup table
However, later on, when those tables are used, another scale factor is used (simplified code):
static const double xmul = 0.758304045695;
static const double ymul = 2.28148649801;
The two constant scale factors directly multiply together, so there is no need for both. No human would manually calculate to 10 decimal places a number which had no effect. Hence, my theory is these numbers have been auto-generated by some kind of hill climbing type algorithm.
- divbit 10y agoSee fig. 2.1 here: http://disp.ee.ntu.edu.tw/meeting/%E7%B6%AD%E6%AF%85/An%20Introduction%20to%20Image%20Compression/An%20introduction%20to%20Image%20Compression.pdf http://disp.ee.ntu.edu.tw/meeting/%E7%B6%AD%E6%AF%85/An%20In... and also read here: https://en.wikipedia.org/wiki/YUV https://en.wikipedia.org/wiki/YUV That is my quick guess on how to roughly derive the constants (because it is new, probably there are some fancy modifications tho :) )
- cjhanks 10y agoYeah, this looks like an optimizer wrote the program. I presume the code was tested against natural images... so it might not be appropriate for all image types.