You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As Keras_CV==0.6.4, RandomColorDegeneration and Equalization preprocessing layers are not subclasses of VectorizedBaseImageAugmentationLayer, thus resulting in a slow forward pass.
Expected Behavior:
RandomColorDegeneration and Equalization preprocessing layers should be subclasses of VectorizedBaseImageAugmentationLayer (introduced in v. 0.5.0).
The implementation of RandomColorDegeneration is quite straightforward, while RandomColorDegeneration has a potential bottleneck represented by tf.histogram_fixed_width.
In the following Colab I propose an implementation for both layers.
@sup3rgiu thank you for filing the issue! If you can open a PR for vectorized implementation of these layers with example outputs showing different augmentations for each image in a batch. that would be great!
@sup3rgiu thank you for filing the issue! If you can open a PR for vectorized implementation of these layers with example outputs showing different augmentations for each image in a batch. that would be great!
Current Behavior:
As Keras_CV==0.6.4, RandomColorDegeneration and Equalization preprocessing layers are not subclasses of
VectorizedBaseImageAugmentationLayer
, thus resulting in a slow forward pass.Expected Behavior:
RandomColorDegeneration and Equalization preprocessing layers should be subclasses of
VectorizedBaseImageAugmentationLayer
(introduced in v. 0.5.0).The implementation of
RandomColorDegeneration
is quite straightforward, whileRandomColorDegeneration
has a potential bottleneck represented by tf.histogram_fixed_width.In the following Colab I propose an implementation for both layers.
Colab:
This colab includes a possible vectorized implementation of the given layers, and also a benchmark.
https://colab.research.google.com/drive/1t5b4a11ae3HWxUoyL-R50E2z8dkNSQYP?usp=sharing
Version:
0.6.4
The text was updated successfully, but these errors were encountered: