diff options
author | A. Unique TensorFlower <gardener@tensorflow.org> | 2018-08-06 18:12:42 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-08-06 18:16:44 -0700 |
commit | 0fc1de719ba0ad6d953f618475c73d35dd27767d (patch) | |
tree | 303aecb6c46c5888d9c155c7676aa4a384755133 /tensorflow/contrib/lite/kernels/logical.cc | |
parent | 56a82b00f461dc8bc2b3e8e63fa768144795a7b2 (diff) |
Implementation of logical_and logical_not
PiperOrigin-RevId: 207642985
Diffstat (limited to 'tensorflow/contrib/lite/kernels/logical.cc')
-rw-r--r-- | tensorflow/contrib/lite/kernels/logical.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tensorflow/contrib/lite/kernels/logical.cc b/tensorflow/contrib/lite/kernels/logical.cc index 3dc39bf79a..87c2fee667 100644 --- a/tensorflow/contrib/lite/kernels/logical.cc +++ b/tensorflow/contrib/lite/kernels/logical.cc @@ -105,6 +105,11 @@ TfLiteStatus LogicalOrEval(TfLiteContext* context, TfLiteNode* node) { return LogicalImpl(context, node, logical_or_func); } +TfLiteStatus LogicalAndEval(TfLiteContext* context, TfLiteNode* node) { + const auto logical_and_func = std::logical_and<bool>(); + return LogicalImpl(context, node, logical_and_func); +} + } // namespace } // namespace logical @@ -116,6 +121,14 @@ TfLiteRegistration* Register_LOGICAL_OR() { return &r; } +TfLiteRegistration* Register_LOGICAL_AND() { + // Init, Free, Prepare, Eval are satisfying the Interface required by + // TfLiteRegistration. + static TfLiteRegistration r = {logical::Init, logical::Free, logical::Prepare, + logical::LogicalAndEval}; + return &r; +} + } // namespace builtin } // namespace ops } // namespace tflite |