| 27 | using kernels::tensor_shape; |
| 28 | |
| 29 | TEST(Mat2Tensor, Shape) { |
| 30 | cv::Mat mat; |
| 31 | mat.create(480, 640, CV_8UC3); |
| 32 | EXPECT_EQ(tensor_shape<3>(mat), TensorShape(480, 640, 3)); |
| 33 | mat.create(123, 321, CV_32FC2); |
| 34 | EXPECT_EQ(tensor_shape<DynamicDimensions>(mat), TensorShape(123, 321, 2)); |
| 35 | mat.create(123, 321, CV_32F); |
| 36 | EXPECT_EQ(tensor_shape<3>(mat), TensorShape(123, 321, 1)); |
| 37 | EXPECT_EQ(tensor_shape<2>(mat), TensorShape(123, 321)); |
| 38 | } |
| 39 | |
| 40 | |
| 41 | TEST(Mat2Tensor, View) { |
nothing calls this directly
no test coverage detected