PINA icon indicating copy to clipboard operation
PINA copied to clipboard

Multisolver raises error when not specifying optimizers

Open dario-coscia opened this issue 1 year ago • 0 comments

Describe the bug The Multisolver class raises error when not specifying optimizers

To Reproduce Inherit from Multisolver and do not specify the optimizers. E.g:

class EnsembleSolverInterface(MultiSolverInterface):
    def __init__(
        self,
        problem,
        models,
        ensemble_dim=0,
        optimizers=None,
        schedulers=None,
        weighting=None,
        use_lt=True,
    ):
        super().__init__(
            problem, models, optimizers, schedulers, weighting, use_lt
        )

Expected behavior Initialize with default optimizers and schedulers.

Output

TypeError: 'NoneType' object is not iterable

dario-coscia avatar Mar 24 '25 11:03 dario-coscia