MCPcopy Create free account
hub / github.com/NVIDIA/DALI / TEST

Function TEST

dali/core/tensor_shape_test.cc:32–42  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

30 "Unexpected tensor shape size");
31
32TEST(TensorShapeTest, DefaultStaticShapeConstructor) {
33 TensorShape<0> zero_tensor;
34 ASSERT_EQ(zero_tensor.size(), 0);
35
36 constexpr int test_dim = 5;
37 // Default constructor
38 TensorShape<test_dim> empty_tensor;
39 for (int i = 0; i < test_dim; i++) {
40 EXPECT_EQ(empty_tensor[i], int64_t(0));
41 }
42}
43
44TEST(TensorShapeTest, StaticShapeConstructor) {
45 // std::array and expanded list constructor

Callers

nothing calls this directly

Calls 15

uniform_list_shapeFunction · 0.85
volumeFunction · 0.85
flatten_shapesFunction · 0.85
calculate_pointersFunction · 0.85
collapse_dimsFunction · 0.85
make_cspanFunction · 0.85
is_degenerate_dimFunction · 0.85
permute_dimsFunction · 0.85
unfold_outer_dimFunction · 0.85
is_uniformFunction · 0.50
collapse_dimFunction · 0.50
sample_rangeFunction · 0.50

Tested by

no test coverage detected