tensorflow / model-optimization

A toolkit to optimize ML models for deployment for Keras and TensorFlow, including quantization and pruning.
https://www.tensorflow.org/model_optimization
Apache License 2.0
1.49k stars 319 forks source link

Fix for the bug with data_format in clustering per channel #951

Closed wwwind closed 2 years ago

wwwind commented 2 years ago

When the data_format is 'channels_first', clustering per channel is not working correctly due to mismatch in arguments. This CR fixed this case + added test that we set the argument correctly.

The reported bug is https://github.com/tensorflow/model-optimization/issues/939