Tensor Reshaping and Transposition

0
easy

In this exercise, you first need to reshape a one-dimensional tensor into a two-dimensional tensor with 2 rows using 'view'. Then, transpose the tensor so the rows become columns and vice versa.

Examples:

1
2
3
4
1
3
2
4
1
2
3
4
5
6
1
4
2
5
3
6
1
0
0
1
1
0
0
1

Loading...
2024 © TensorGym
Contrinbute | Contact | Copyright | 𝕏