def optimizer(self, optimizer: Optimizer): """ Sets optimizer """ super(VQE, self.__class__).optimizer.__set__(self, optimizer) # type: ignore if optimizer is not None: optimizer.set_max_evals_grouped(self._max_evals_grouped)
def optimizer(self, optimizer: Optimizer): """ Sets optimizer """ super().optimizer = optimizer if optimizer is not None: optimizer.set_max_evals_grouped(self._max_evals_grouped)