Skip to content

Commit

Permalink
Fix (quant/minifloat): add scaling_min_val to base quantizers (#773)
Browse files Browse the repository at this point in the history
  • Loading branch information
Giuseppe5 authored Dec 5, 2023
1 parent 58936c4 commit 422b632
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/brevitas/quant/experimental/float_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,15 @@ class FloatWeightBase(SolveTensorQuantFloatToIntImplFromEnum):
tensor_quant = FloatQuant
signed = True
float_to_int_impl_type = 'round'
scaling_min_val = 1e-10


class FloatActBase(SolveTensorQuantFloatToIntImplFromEnum):
proxy_class = ActQuantProxyFromInjector
tensor_quant = FloatQuant
signed = True
float_to_int_impl_type = 'round'
scaling_min_val = 1e-10


class ScaledFloatWeightBase(FloatWeightBase, WeightQuantSolver):
Expand Down

0 comments on commit 422b632

Please sign in to comment.