06. Tensorflow2.0中的维度变换

1. Outline

  • shape, ndim
  • reshape
  • expand_dims/squeeze
  • transpose

06. Tensorflow2.0中的维度变换

2. Reshape

2.1. Reshape is flexible

06. Tensorflow2.0中的维度变换

2.2. Reshape could lead to potential bugs!

06. Tensorflow2.0中的维度变换

3. tf.transpose

06. Tensorflow2.0中的维度变换

4. Squeeze VS Expand_dims

4.1. Expand dim

  • a: [classes, students, classes]
    • [4, 35, 8]
  • add school dim
    • [1, 4, 35, 8] + [1, 4, 35, 8]
    • [2, 4, 35, 8]

06. Tensorflow2.0中的维度变换

4.2. Squeeze dim

06. Tensorflow2.0中的维度变换
06. Tensorflow2.0中的维度变换

5. 需要全套课程视频+PPT+代码资源可以私聊我-

  • 方式1:CSDN私信我!
  • 方式2:QQ邮箱:[email protected]或者直接加我QQ: 594042358!