mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-04-23 01:59:38 +08:00
Fixed Tensor documentation formatting.
This commit is contained in:
parent
15f3d9d272
commit
c694be1214
@ -1742,6 +1742,7 @@ sizes:
|
|||||||
2x2 image patches can be extracted and indexed using the following code:
|
2x2 image patches can be extracted and indexed using the following code:
|
||||||
|
|
||||||
*) 2D patch: ColMajor (patch indexed by second-to-last dimension)
|
*) 2D patch: ColMajor (patch indexed by second-to-last dimension)
|
||||||
|
|
||||||
Tensor<float, 5> twod_patch;
|
Tensor<float, 5> twod_patch;
|
||||||
twod_patch = tensor.extract_image_patches<2, 2>();
|
twod_patch = tensor.extract_image_patches<2, 2>();
|
||||||
// twod_patch.dimension(0) == 2
|
// twod_patch.dimension(0) == 2
|
||||||
@ -1751,6 +1752,7 @@ sizes:
|
|||||||
// twod_patch.dimension(4) == 7
|
// twod_patch.dimension(4) == 7
|
||||||
|
|
||||||
*) 2D patch: RowMajor (patch indexed by the second dimension)
|
*) 2D patch: RowMajor (patch indexed by the second dimension)
|
||||||
|
|
||||||
Tensor<float, 5, RowMajor> twod_patch_row_major;
|
Tensor<float, 5, RowMajor> twod_patch_row_major;
|
||||||
twod_patch_row_major = tensor_row_major.extract_image_patches<2, 2>();
|
twod_patch_row_major = tensor_row_major.extract_image_patches<2, 2>();
|
||||||
// twod_patch_row_major.dimension(0) == 7
|
// twod_patch_row_major.dimension(0) == 7
|
||||||
|
Loading…
x
Reference in New Issue
Block a user