bitorch.layers.config.LayerConfig

class bitorch.layers.config.LayerConfig[source]

Class to provide layer configurations.

Methods

get_quantization_function

Returns the quantization module specified by the given name or object.

Attributes

debug_activated

gradient_cancellation_threshold

input_quantization

name

pact_bits

padding_value

weight_quantization

get_quantization_function(quantization: Union[str, Quantization]) Quantization[source]

Returns the quantization module specified by the given name or object.

Parameters:

quantization – quantization module or name of quantization function.

Returns:

the quantization module