tancik / StegaStamp

Invisible Hyperlinks in Physical Photographs
http://www.matthewtancik.com/stegastamp
MIT License
689 stars 193 forks source link

Problem with parameter setting . #38

Open Lee-meng-meng opened 3 years ago

Lee-meng-meng commented 3 years ago

What does YUV_scales stand for? Why did you set y,u, and v to 1,100,100, respectively? How do I adjust these three parameters?

Many thanks

tancik commented 3 years ago

YUV is a color space (https://en.wikipedia.org/wiki/YUV). The scaling varies the loss for color versus luminosity (the u,v channels are color).

Lee-meng-meng commented 3 years ago

Why did you set y,u, and v to 1,100,100, respectively?

tancik commented 3 years ago

By setting u and v larger you increase the loss on the color channels. Weighing them more helped avoid weird colors from emerging during training.

Lee-meng-meng commented 3 years ago

Thank you for your reply ~ I found that YUV should be set to 1,300,200 to avoid strange colors when training 1200*800. Is this setting related to the ratio of length to width?