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

Function SetMinorToMajorLayout

tensorflow/compiler/xla/index_util_test.cc:27–32  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

25namespace {
26
27void SetMinorToMajorLayout(Shape* shape, std::vector<int64> dimensions) {
28 shape->mutable_layout()->clear_minor_to_major();
29 for (auto dimension : dimensions) {
30 shape->mutable_layout()->add_minor_to_major(dimension);
31 }
32}
33
34TEST(IndexUtilTest, VectorIndexing) {
35 // Vectors are trivially laid out and the linear index should always be the

Callers 1

TESTFunction · 0.85

Calls 1

mutable_layoutMethod · 0.80

Tested by

no test coverage detected