[docs]@torch.jit.scriptdefsystems_and_targets_to_device(# pragma: no coversystems:List[System],targets:Dict[str,TensorMap],device:torch.device,):""" Transfers the systems and targets to the specified device. :param systems: List of systems. :param targets: Dictionary of targets. :param device: Device to transfer to. """systems=[system.to(device=device)forsysteminsystems]targets={key:value.to(device=device)forkey,valueintargets.items()}returnsystems,targets
[docs]@torch.jit.scriptdefsystems_and_targets_to_dtype(# pragma: no coversystems:List[System],targets:Dict[str,TensorMap],dtype:torch.dtype,):""" Changes the systems and targets to the specified floating point data type. :param systems: List of systems. :param targets: Dictionary of targets. :param dtype: Desired floating point data type. """systems=[system.to(dtype=dtype)forsysteminsystems]targets={key:value.to(dtype=dtype)forkey,valueintargets.items()}returnsystems,targets