Browse Source

Pre Merge pull request !339 from itcomee/master

pull/339/MERGE
itcomee Gitee 3 years ago
parent
commit
3c014bac2d
2 changed files with 3 additions and 0 deletions
  1. +1
    -0
      mindarmour/privacy/sup_privacy/mask_monitor/masker.py
  2. +2
    -0
      mindarmour/privacy/sup_privacy/train/model.py

+ 1
- 0
mindarmour/privacy/sup_privacy/mask_monitor/masker.py View File

@@ -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.


+ 2
- 0
mindarmour/privacy/sup_privacy/train/model.py View File

@@ -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,6 +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 # come from nn.cell_wrapper.TrainOneStepCell
class TrainOneStepCell(Cell): class TrainOneStepCell(Cell):
r""" r"""


Loading…
Cancel
Save