Open seang opened 2 years ago
Thanks for this detailed report. By default in pixray the init_image is mixed with noise.
python pixray.py \
--iterations 0 \
--init_image inputs/test_pattern_wide2.jpg \
--output outputs/debug/test_pattern_wide2_A.jpg
To prevent this you would need to also set init_image_alpha explicitly to either 255 (force opaque) or 0 (leave alpha untouched - useful if the init-image actually has an alpha channel).
python pixray.py \
--iterations 0 \
--init_image inputs/test_pattern_wide2.jpg \
--init_image_alpha 255 \
--output outputs/debug/test_pattern_wide2_B.png
Can you try adding init_image_alpha=255 and reporting if this is closer to the expected value? It's entirely possible that there will still be some discrepancy as there might not be perfect alignment between the init_image resizing and the pixeldrawer sampling on the image across the square - but if so this can be investigated.
Hi! We have a use case where we're doing some iteration, exporting the image and then reloading the image at at later time.
What we're finding so far is that the
color_vars
value in the pixeldrawer class is not the same which is preventing our second run from converging in the expected amount of time.we ran this block first:
Which produced pixel-drawer-debug.png as expected, with the pixeldrawer instance having a
color_vars[:10]
value of:Then we passed the image output hosted on a site as the init_image url with this command:
Which resulted in the pixeldrawer instance having a startup value
color_vars[:10]
of:( After init_from_tensor is called )
We're not really sure why but if you have any ideas they'd be appreciated