ffcv icon indicating copy to clipboard operation
ffcv copied to clipboard

fill parmeter in translate has no effect

Open tfriedel opened this issue 3 years ago • 5 comments

When using the translate operation, the empty part of the result image should be filled with the tuple provided with the "fill" argument. It's currently not being used and thus the background will always consist of (0,0,0).

tfriedel avatar Feb 26 '22 16:02 tfriedel

Hello @tfriedel, Which transform are you referring to ? I don't think FFCV comes with a translate transform does it?

GuillaumeLeclerc avatar Mar 02 '22 22:03 GuillaumeLeclerc

this one: https://github.com/libffcv/ffcv/blob/main/ffcv/transforms/translate.py

tfriedel avatar Mar 03 '22 00:03 tfriedel

When using the translate operation, the empty part of the result image should be filled with the tuple provided with the "fill" argument. It's currently not being used and thus the background will always consist of (0,0,0).

It's actually worse than that, it's uninitialized and once in a while it contains a random value other than 0.0!

daniel-geon-park avatar Mar 03 '22 12:03 daniel-geon-park

I didn't know we had that augmentation. Sorry about that, I'll try to fix that soon, but if someone wants to go ahead and make a PR it should be pretty straightforward

GuillaumeLeclerc avatar Mar 03 '22 17:03 GuillaumeLeclerc

This should be fixed in #184 !

andrewilyas avatar Mar 11 '22 14:03 andrewilyas

Now fixed on PyPI!

andrewilyas avatar Mar 03 '23 01:03 andrewilyas