MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / TEST

Function TEST

tensorflow/lite/kernels/gather_test.cc:69–76  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

67};
68
69TEST(GatherOpTest, Shuffle) {
70 GatherOpModel m({TensorType_FLOAT32, {2, 2}}, {TensorType_INT32, {2}});
71 m.SetInput<float>({-2.0, 0.2, 0.7, 0.8});
72 m.SetPositions<int32_t>({1, 0});
73 m.Invoke();
74 EXPECT_THAT(m.GetOutput<float>(),
75 ElementsAreArray(ArrayFloatNear({0.7, 0.8, -2, 0.2})));
76}
77
78TEST(GatherOpTest, Test0DIndex) {
79 GatherOpModel m({TensorType_FLOAT32, {2, 2}}, {TensorType_INT32, {}});

Callers

nothing calls this directly

Calls 6

ArrayFloatNearFunction · 0.70
InvokeMethod · 0.45
GetOutputShapeMethod · 0.45
emptyMethod · 0.45
SetStringInputMethod · 0.45
GetStringOutputMethod · 0.45

Tested by

no test coverage detected