tf.reshape

tf.reshape(tensor, shape, name=None)

Among them, tensor is a vector, or a matrix

shape is the transformed vector, or transformed matrix shape

[2,1] Convert to two rows and one column

[2, -1] Convert to two rows, how many columns? Since -1 means that the computer needs several columns for its own calculation, I need two rows anyway.

-1 means that the computer calculates the parameters by itself

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325350175&siteId=291194637