or.hpp
1 // Copyright (C) 2018-2021 Intel Corporation
2 // SPDX-License-Identifier: Apache-2.0
3 //
4 
5 #pragma once
6 
7 #include <memory>
8 
9 #include "ngraph/op/util/binary_elementwise_logical.hpp"
10 
11 namespace ngraph
12 {
13  namespace op
14  {
15  namespace v1
16  {
17  /// \brief Elementwise logical-or operation.
18  ///
19  class NGRAPH_API LogicalOr : public util::BinaryElementwiseLogical
20  {
21  public:
22  NGRAPH_RTTI_DECLARATION;
23  LogicalOr() = default;
24  /// \brief Constructs a logical-or operation.
25  ///
26  /// \param arg0 Node that produces the first input tensor.<br>
27  /// `[d0, ...]`
28  /// \param arg1 Node that produces the second input tensor.<br>
29  /// `[d0, ...]`
30  /// \param auto_broadcast Auto broadcast specification
31  ///
32  /// Output `[d0, ...]`
33  ///
34  LogicalOr(const Output<Node>& arg0,
35  const Output<Node>& arg1,
36  const AutoBroadcastSpec& auto_broadcast =
37  AutoBroadcastSpec(AutoBroadcastType::NUMPY));
38 
39  virtual std::shared_ptr<Node>
40  clone_with_new_inputs(const OutputVector& new_args) const override;
41 
42  bool evaluate(const HostTensorVector& outputs,
43  const HostTensorVector& inputs) const override;
44  bool has_evaluate() const override;
45  };
46  } // namespace v1
47  } // namespace op
48 } // namespace ngraph
A handle for one of a node's outputs.
Definition: node_output.hpp:33
Abstract base class for elementwise binary logical operations, i.e., operations where the same scalar...
Definition: binary_elementwise_logical.hpp:42
Elementwise logical-or operation.
Definition: or.hpp:20
bool evaluate(const HostTensorVector &outputs, const HostTensorVector &inputs) const override
Evaluates the op on input_values putting results in output_values.
LogicalOr(const Output< Node > &arg0, const Output< Node > &arg1, const AutoBroadcastSpec &auto_broadcast=AutoBroadcastSpec(AutoBroadcastType::NUMPY))
Constructs a logical-or operation.
bool has_evaluate() const override
Allows to get information about availability of evaluate method for the current operation.
The Intel nGraph C++ API.
Definition: attribute_adapter.hpp:16
Implicit broadcast specification.
Definition: attr_types.hpp:311