public void tf_reshape_test() { using (var K = new TensorFlowBackend()) { double[,] input_array = new double[, ] { { 1, 2 }, { 3, 4 } }; Tensor variable = K.variable(array: input_array, dtype: DataType.Double); Tensor variable_new_shape = K.reshape(variable, new int[] { 1, 4 }); double[,] output = (double[, ])variable_new_shape.eval(); Assert.AreEqual(new double[, ] { { 1, 2, 3, 4 } }, output); } }