(
        self,
        inputs: List[ArrayIndexType],
        output: ArrayIndexType,
        size_dict: Dict[str, int],
    )
Utility that stateful optimizers can use to ensure they are not
        called with different contractions across separate runs.
Utility that stateful optimizers can use to ensure they are not
        called with different contractions across separate runs.
Utility that stateful optimizers can use to ensure they are not called with different contractions across separate runs .
def _check_args_against_first_call(
        self,
        inputs: List[ArrayIndexType],
        output: ArrayIndexType,
        size_dict: Dict[str, int],
    ) -> None:
        """Utility that stateful optimizers can use to ensure they are not
        called with different contractions across separate runs.
        """
        args = (inputs, output, size_dict)
        if not hasattr(self, "_first_call_args"):
            # simply set the attribute as currently there is no global PathOptimizer init
            self._first_call_args = args
        elif args != self._first_call_args:
            raise ValueError(
                "The arguments specifying the contraction that this path optimizer "
                "instance was called with have changed - try creating a new instance."
            )
def _check_args_against_first_call ( self , inputs : List [ ArrayIndexType ] , output : ArrayIndexType , size_dict : Dict [ str , int ] , ) -> None : args = ( inputs , output , size_dict ) if not hasattr ( self , "_first_call_args" ) : # simply set the attribute as currently there is no global PathOptimizer init self . _first_call_args = args elif args != self . _first_call_args : raise ValueError ( "The arguments specifying the contraction that this path optimizer " "instance was called with have changed - try creating a new instance." )