@parent.setter
    def parent(self, p):
        if getattr(self,'_parent',None) not in None:
            print 'Regularization has switched to a new parent!'
        self._parent = p
dataset/ETHPy150Open simpeg/simpeg/SimPEG/Regularization.py/BaseRegularization.parent/operator `is not` -> `not in`