@@ -622,10 +622,8 @@ class _TrainOneStepCell(Cell): | |||||
self._noise_mech_param_updater = _MechanismsParamsUpdater( | self._noise_mech_param_updater = _MechanismsParamsUpdater( | ||||
decay_policy=self._noise_mech._decay_policy, | decay_policy=self._noise_mech._decay_policy, | ||||
decay_rate=self._noise_mech._noise_decay_rate, | decay_rate=self._noise_mech._noise_decay_rate, | ||||
cur_noise_multiplier= | |||||
self._noise_mech._noise_multiplier, | |||||
init_noise_multiplier= | |||||
self._noise_mech._initial_noise_multiplier) | |||||
cur_noise_multiplier=self._noise_mech._noise_multiplier, | |||||
init_noise_multiplier=self._noise_mech._initial_noise_multiplier) | |||||
def construct(self, data, label): | def construct(self, data, label): | ||||
""" | """ | ||||
@@ -23,6 +23,7 @@ from mindarmour.privacy.sup_privacy.sup_ctrl.conctrl import SuppressCtrl | |||||
LOGGER = LogUtil.get_instance() | LOGGER = LogUtil.get_instance() | ||||
TAG = 'suppress masker' | TAG = 'suppress masker' | ||||
class SuppressMasker(Callback): | class SuppressMasker(Callback): | ||||
""" | """ | ||||
Periodicity check suppress privacy function status and toggle suppress operation. | Periodicity check suppress privacy function status and toggle suppress operation. | ||||
@@ -186,6 +186,7 @@ class _TupleAdd(nn.Cell): | |||||
out = self.hyper_map(self.add, input1, input2) | out = self.hyper_map(self.add, input1, input2) | ||||
return out | return out | ||||
class _TupleMul(nn.Cell): | class _TupleMul(nn.Cell): | ||||
""" | """ | ||||
Mul two tuple of data. | Mul two tuple of data. | ||||
@@ -200,7 +201,7 @@ class _TupleMul(nn.Cell): | |||||
out = self.hyper_map(self.mul, input1, input2) | out = self.hyper_map(self.mul, input1, input2) | ||||
return out | return out | ||||
# come from nn.cell_wrapper.TrainOneStepCell | |||||
class TrainOneStepCell(Cell): | class TrainOneStepCell(Cell): | ||||
r""" | r""" | ||||
Network training package class. | Network training package class. | ||||