The variant
A lefout map is used to store the residue for each done pixel no matter it is an isolated pixel or not. Next time, before calculating the total weights for a chosen pixel, find the total leftout(T_leftout) around the chosen pixel and the new error = error + T_leftout. There is no global leftout and others are same as before. The tone PSNR has a tiny improvement for both basic and variant method. For example, for variant usually 5 out of 12 examples better than Pang's method, right now it is 6 out of 12. For basic method 10 out of 12 better than Pang's method, right now it is 11 out of 12. But the MSSIM for the basic method is not good anymore. Look at the ramp for both method. This modification improves the variant method, but brings some wrong matching for the basic method.
The wrong matching comes from the decision for drawing white or black after adding the total leftout.
Interesting. I think this will improve things, but I also think that there is an even simpler thing you can do that may have even larger impact: after running the distribution once, possibly saturating some pixels in the neighborhood, immediately run it a second time (this time with w=0 for the newly saturated pixels). This distributes the error in a way that conforms with the original idea.
ReplyDeleteIt won't always work (e.g., in the case of isolated pixels) but it will definitely help and it seems as though it is a complementary idea to what you implemented. I'd like to see the results from trying it.