libffcv / ffcv

FFCV: Fast Forward Computer Vision (and other ML workloads!)
https://ffcv.io
Apache License 2.0
2.81k stars 180 forks source link

Add solarization #203

Closed bordesf closed 1 year ago

bordesf commented 2 years ago

An implementation of Solarization that follow RandomSolarize from torchvision.transforms.

Here is an example with a threshold of 1. Left: original image; Middle: FFCV Solarization; Right: Torchvision.transforms solarization_pytorch_ffcv

By the way, will it be possible to add the test_data/pig.png into a ffcv/beton file that will be saved in this repo ? This would enable the writing of automatics tests to ensure consistency with torchvision.transforms.