def METHOD_NAME(self, input_):
    if input_ is None:
        return
    if isinstance(
            input_,
            FateTorchLayer) or isinstance(
            input_,
            Sequential):
        input_.add_optimizer(self)