Skip to content

Commit 22815dc

Browse files
authored
Sync from tflite-micro. (tensorflow#175)
1 parent 305cda5 commit 22815dc

File tree

3 files changed

+7
-11
lines changed

3 files changed

+7
-11
lines changed

src/tensorflow/lite/micro/kernels/micro_ops.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@ TfLiteRegistration Register_SLICE();
100100
TfLiteRegistration Register_SOFTMAX();
101101
TfLiteRegistration Register_SPACE_TO_BATCH_ND();
102102
TfLiteRegistration Register_SPACE_TO_DEPTH();
103+
TfLiteRegistration Register_SPLIT_V();
103104
TfLiteRegistration Register_SQUARED_DIFFERENCE();
104105
TfLiteRegistration Register_SQUEEZE();
105106
TfLiteRegistration Register_STRIDED_SLICE();
@@ -127,7 +128,6 @@ TfLiteRegistration Register_ROUND();
127128
TfLiteRegistration Register_RSQRT();
128129
TfLiteRegistration Register_SIN();
129130
TfLiteRegistration Register_SPLIT();
130-
TfLiteRegistration Register_SPLIT_V();
131131
TfLiteRegistration Register_SQRT();
132132
TfLiteRegistration Register_SQUARE();
133133
TfLiteRegistration Register_UNPACK();

src/tensorflow/lite/micro/kernels/split_v.cpp

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* Copyright 2018 The TensorFlow Authors. All Rights Reserved.
1+
/* Copyright 2023 The TensorFlow Authors. All Rights Reserved.
22
33
Licensed under the Apache License, Version 2.0 (the "License");
44
you may not use this file except in compliance with the License.
@@ -22,9 +22,8 @@ limitations under the License.
2222
#include "tensorflow/lite/micro/micro_log.h"
2323

2424
namespace tflite {
25-
namespace ops {
26-
namespace micro {
27-
namespace split_v {
25+
26+
namespace {
2827

2928
template <typename T>
3029
TfLiteStatus SplitImpl(TfLiteContext* context, TfLiteNode* node,
@@ -119,12 +118,10 @@ TfLiteStatus Eval(TfLiteContext* context, TfLiteNode* node) {
119118
return kTfLiteOk;
120119
}
121120

122-
} // namespace split_v
121+
} // namespace
123122

124123
TfLiteRegistration Register_SPLIT_V() {
125-
return tflite::micro::RegisterOp(nullptr, split_v::Prepare, split_v::Eval);
124+
return tflite::micro::RegisterOp(nullptr, Prepare, Eval);
126125
}
127126

128-
} // namespace micro
129-
} // namespace ops
130127
} // namespace tflite

src/tensorflow/lite/micro/micro_mutable_op_resolver.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -497,8 +497,7 @@ class MicroMutableOpResolver : public MicroOpResolver {
497497
}
498498

499499
TfLiteStatus AddSplitV() {
500-
return AddBuiltin(BuiltinOperator_SPLIT_V,
501-
tflite::ops::micro::Register_SPLIT_V(), ParseSplitV);
500+
return AddBuiltin(BuiltinOperator_SPLIT_V, Register_SPLIT_V(), ParseSplitV);
502501
}
503502

504503
TfLiteStatus AddSqueeze() {

0 commit comments

Comments
 (0)