Tensors can be created from Python lists with the torch.Tensor() function. # Create a torch. ... Tensor(M_data) print(M) # Create a 3D tensor of size 2x2x2.
確定! 回上一頁