brainspy.utils.pytorch#

Class to consistently manage torch variables and their data types. It can format data provided as a torch tensor,numpy array or an nn.Module object. It also han- dles the intialization of seed for generation of random values.

Classes

TorchUtils()

Consistently manage data movement and formatting of pytorch tensors and torch.nn.Module instances.