MCPcopy Create free account
hub / github.com/deepspeedai/DeepSpeed / get_quant_range

Method get_quant_range

op_builder/fp_quantizer.py:81–90  ·  view source on GitHub ↗
(q_bits=None)

Source from the content-addressed store, hash-verified

79
80 @staticmethod
81 def get_quant_range(q_bits=None):
82 if q_bits == 8:
83 return 480
84 elif q_bits == 6:
85 return 28.
86 elif q_bits == 12:
87 return 510.
88 else:
89 assert (0), \
90 "Please specify the right quantization range for the selected precision!"

Calls

no outgoing calls

Tested by 2

qtorch_quantizeFunction · 0.36