aihwkit_lightning.simulator.parameters.enums module
Utility enumerators for resistive processing units.
- class aihwkit_lightning.simulator.parameters.enums.WeightClipType(value)[source]
Bases:
EnumWeight clipper type.
- LAYER_GAUSSIAN = 'LayerGaussian'
Calculates the second moment of the whole weight matrix and clips at
sigmatimes the result symmetrically around zero.
- LAYER_GAUSSIAN_PER_CHANNEL = 'LayerGaussianPerChannel'
Calculates the second moment of the whole weight matrix per output column and clips at
sigmatimes the result symmetrically around zero.
- LEARNABLE_PER_CHANNEL = 'LearnablePerChannel'
Implements ParetoQ-like learnable weight clipping (originally LSQ) see eq. 3 from https://arxiv.org/pdf/1902.08153. Implements this on a per-channel basis.
- NONE = 'None'
None.
- class aihwkit_lightning.simulator.parameters.enums.WeightModifierType(value)[source]
Bases:
EnumWeight modifier type.
- ADD_NORMAL = 'AddNormal'
Additive Gaussian noise.
- ADD_NORMAL_PER_CHANNEL = 'AddNormalPerChannel'
Additive Gaussian noise per channel.
- DISCRETIZE = 'Discretize'
Quantize the weights.
- DISCRETIZE_ADD_NORMAL = 'DiscretizeAddNormal'
First discretize and then additive Gaussian noise.
- DISCRETIZE_ADD_NORMAL_PER_CHANNEL = 'DiscretizeAddNormalPerChannel'
First discretize per channel and then additive Gaussian noise per channel.
- DISCRETIZE_PER_CHANNEL = 'DiscretizePerChannel'
Quantize the weights per channel.
- NONE = 'None'
No weight modifier. Nothing happens to the weight.
- class aihwkit_lightning.simulator.parameters.enums.WeightNoiseInjectionType(value)[source]
Bases:
EnumWeight modifier type.
- ADD_NORMAL = 'AddNormal'
Additive Gaussian noise.
- ADD_NORMAL_PER_CHANNEL = 'AddNormalPerChannel'
Additive Gaussian noise per channel.
- NONE = 'None'
No weight modifier. Nothing happens to the weight.
- class aihwkit_lightning.simulator.parameters.enums.WeightQuantizationType(value)[source]
Bases:
EnumWeight quantization type.
- DISCRETIZE = 'Discretize'
Quantize the weights.
- DISCRETIZE_PER_CHANNEL = 'DiscretizePerChannel'
Quantize the weights per channel.
- NONE = 'None'
No weight quantizer. Nothing happens to the weight.