Calculate the required scales for converting int8 modules Currently there are four type of modules should be supported: 1) Graph: calculate scales for input and output 2) Linear: calculate scales for input, output and weight 3) Spatial Convolution: calculate scales for input, output and weight 4) Sequential: calculate scales for input, output as well as the scales of submodules 5) ConcatTable: calculate scales for input, output as well as the scales of submodules
Calculate the required scales for converting int8 modules Currently there are four type of modules should be supported: 1) Graph: calculate scales for input and output 2) Linear: calculate scales for input, output and weight 3) Spatial Convolution: calculate scales for input, output and weight 4) Sequential: calculate scales for input, output as well as the scales of submodules 5) ConcatTable: calculate scales for input, output as well as the scales of submodules
input activity
Get dimension mask of input
Get dimension mask of input
inputDimMask field which stores value of input dimension mask
Get input scales
Get input scales
field which stores value of input scales
Get output scales
Get output scales
field which stores value of output scales
Get dimension mask of weight
Get dimension mask of weight
weightDimMask which stores value of weight mask
Get weight scales
Get weight scales
field which stores value of weight scales
Set dimension mask of input
Set dimension mask of input
value of input dimension mask to be set
when set it to true, update mask including itself and submodules, otherwise only update mask to module itself.
Unit
Set input scales Clear existing buffer of input scales, and place updated scales into the cleared buffer
Set input scales Clear existing buffer of input scales, and place updated scales into the cleared buffer
value of input scales to be set
Unit
Set dimension mask of output
Set dimension mask of output
value of output dimension mask to be set
when set it to true, update mask in full scope including itself and submodules, otherwise only update mask to module itself.
Unit
Set output scales Clear existing buffer of output scales, and place updated scales into the cleared buffer
Set output scales Clear existing buffer of output scales, and place updated scales into the cleared buffer
value of output scales to be set
Unit
Set dimension mask for weight
Set dimension mask for weight
value of weight mask to be set
when set it to true, update mask in full scope including itself and submodules, otherwise only update mask to module itself.
Unit
Set weight scales Clear existing buffer of weight scales, and place updated scales into the cleared buffer
Set weight scales Clear existing buffer of weight scales, and place updated scales into the cleared buffer
value of weight scales to be set
Unit
Trait which provides MKL-DNN functionality to convert from FP32 to INT8