google / qkeras

QKeras: a quantization deep learning library for Tensorflow Keras
Apache License 2.0
533 stars 102 forks source link

How can I get the scale of the QAdaptiveActivation layer #114

Open KaiyiZhang-uo opened 1 year ago

KaiyiZhang-uo commented 1 year ago

1676141811840 As shown in the comment, the QAdaptiveActivation layer can be used to calculate the EMA of min and max of the activation values, i.e., the quantization range of the activations tensor. After we have the quantization range and the number of quantization levels (e.g., 256 for INT8), we can get the scale. However, I did not find the scale attribute in the QAdaptiveActivation layer.

So how can I get the scale of the QAdaptiveActivation layer?