less_eq.hpp
1 //*****************************************************************************
2 // Copyright 2017-2021 Intel Corporation
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //*****************************************************************************
16 
17 #pragma once
18 
19 #include "ngraph/op/util/binary_elementwise_comparison.hpp"
20 
21 namespace ngraph
22 {
23  namespace op
24  {
25  namespace v1
26  {
27  /// \brief Elementwise less-than-or-equal operation.
28  class NGRAPH_API LessEqual : public util::BinaryElementwiseComparison
29  {
30  public:
31  NGRAPH_RTTI_DECLARATION;
32  /// \brief Constructs a less-than-or-equal operation.
34  : util::BinaryElementwiseComparison(AutoBroadcastSpec::NUMPY)
35  {
36  }
37 
38  /// \brief Constructs a less-than-or-equal operation.
39  ///
40  /// \param arg0 Node that produces the first input tensor.
41  /// \param arg1 Node that produces the second input tensor.
42  /// \param auto_broadcast Auto broadcast specification
43  LessEqual(const Output<Node>& arg0,
44  const Output<Node>& arg1,
45  const AutoBroadcastSpec& auto_broadcast =
46  AutoBroadcastSpec(AutoBroadcastType::NUMPY));
47 
48  virtual std::shared_ptr<Node>
49  clone_with_new_inputs(const OutputVector& new_args) const override;
50  bool evaluate(const HostTensorVector& outputs,
51  const HostTensorVector& inputs) const override;
52  };
53  } // namespace v1
54  } // namespace op
55 } // namespace ngraph
A handle for one of a node's outputs.
Definition: node_output.hpp:42
Abstract base class for elementwise binary comparison operations, i.e., operations where the same sca...
Definition: binary_elementwise_comparison.hpp:55
Elementwise less-than-or-equal operation.
Definition: less_eq.hpp:29
LessEqual()
Constructs a less-than-or-equal operation.
Definition: less_eq.hpp:33
LessEqual(const Output< Node > &arg0, const Output< Node > &arg1, const AutoBroadcastSpec &auto_broadcast=AutoBroadcastSpec(AutoBroadcastType::NUMPY))
Constructs a less-than-or-equal operation.
bool evaluate(const HostTensorVector &outputs, const HostTensorVector &inputs) const override
Evaluates the op on input_values putting results in output_values.
The Intel nGraph C++ API.
Definition: attribute_adapter.hpp:28
Implicit broadcast specification.
Definition: attr_types.hpp:323