analogvnn.utils.to_tensor_parameter
#
Module Contents#
Functions#
|
Converts the given arguments to torch.Tensor of type torch.float32. |
|
Converts the given arguments to nn.Parameter of type torch.float32. |
- analogvnn.utils.to_tensor_parameter.to_float_tensor(*args) Tuple[Union[torch.Tensor, None], Ellipsis] [source]#
Converts the given arguments to torch.Tensor of type torch.float32.
The returned tensors are not trainable.
- Parameters:
*args – the arguments to convert.
- Returns:
the converted arguments.
- Return type:
- analogvnn.utils.to_tensor_parameter.to_nongrad_parameter(*args) Tuple[Union[torch.nn.Parameter, None], Ellipsis] [source]#
Converts the given arguments to nn.Parameter of type torch.float32.
The returned parameters are not trainable.
- Parameters:
*args – the arguments to convert.
- Returns:
the converted arguments.
- Return type: