ONE - On-device Neural Engine
Loading...
Searching...
No Matches
mir::ops::MaxPool2DOp Class Reference

#include <MaxPool2DOp.h>

Collaboration diagram for mir::ops::MaxPool2DOp:

Public Member Functions

 MaxPool2DOp (Output *arg, const MaxPool2DOpAttributes &attributes)
 
OperationcopyWithInputs (const std::vector< Output * > &inputs) override
 
const std::vector< std::int32_t > & getWindowSize () const
 
const std::vector< std::int32_t > & getStrides () const
 
const std::vector< std::int32_t > & getPaddingBefore () const
 
const std::vector< std::int32_t > & getPaddingAfter () const
 
DataFormat getDataFormat () const
 
const MaxPool2DOpAttributesgetAttributes () const
 
- Public Member Functions inherited from mir::Operation
virtual ~Operation ()=default
 
Type getType () const
 
std::size_t getId () const
 
void setId (std::size_t id)
 
std::size_t getNumInputs () const
 
std::size_t getNumOutputs () const
 
std::deque< Output * > & getInputs ()
 
const std::deque< Output * > & getInputs () const
 
std::deque< Output > & getOutputs ()
 
const std::deque< Output > & getOutputs () const
 
OutputgetInput (std::size_t index)
 
const OutputgetInput (std::size_t index) const
 
OutputgetOutput (std::size_t index)
 
const OutputgetOutput (std::size_t index) const
 
const ShapegetInputShape (std::size_t index) const
 
const ShapegetOutputShape (std::size_t index) const
 
void accept (IVisitor *v)
 

Additional Inherited Members

- Public Types inherited from mir::Operation
enum class  Type { HANDLE_OP }
 
- Protected Member Functions inherited from mir::Operation
 Operation (Type type, const std::vector< Output * > &inputs, std::size_t num_outputs=1)
 
void setOutputType (std::size_t index, const TensorType &type)
 

Detailed Description

Definition at line 31 of file MaxPool2DOp.h.

Constructor & Destructor Documentation

◆ MaxPool2DOp()

mir::ops::MaxPool2DOp::MaxPool2DOp ( Output arg,
const MaxPool2DOpAttributes attributes 
)
inline

Definition at line 34 of file MaxPool2DOp.h.

35 : Operation(Type::maxPool2D, {arg}), _attributes(attributes)
36 {
37 inferOutputTypes();
38 }

Member Function Documentation

◆ copyWithInputs()

Operation * mir::ops::MaxPool2DOp::copyWithInputs ( const std::vector< Output * > &  inputs)
inlineoverridevirtual

Implements mir::Operation.

Definition at line 40 of file MaxPool2DOp.h.

41 {
42 return new MaxPool2DOp(inputs[0], _attributes);
43 };
MaxPool2DOp(Output *arg, const MaxPool2DOpAttributes &attributes)
Definition MaxPool2DOp.h:34

◆ getAttributes()

const MaxPool2DOpAttributes & mir::ops::MaxPool2DOp::getAttributes ( ) const
inline

Definition at line 55 of file MaxPool2DOp.h.

55{ return _attributes; }

◆ getDataFormat()

DataFormat mir::ops::MaxPool2DOp::getDataFormat ( ) const
inline

Definition at line 53 of file MaxPool2DOp.h.

53{ return _attributes.data_format; }

References mir::MaxPool2DOpAttributes::data_format.

Referenced by mir2loco::Transformer::visit(), and mir::DotNodeBuilder::visit().

◆ getPaddingAfter()

const std::vector< std::int32_t > & mir::ops::MaxPool2DOp::getPaddingAfter ( ) const
inline

◆ getPaddingBefore()

const std::vector< std::int32_t > & mir::ops::MaxPool2DOp::getPaddingBefore ( ) const
inline

◆ getStrides()

const std::vector< std::int32_t > & mir::ops::MaxPool2DOp::getStrides ( ) const
inline

◆ getWindowSize()

const std::vector< std::int32_t > & mir::ops::MaxPool2DOp::getWindowSize ( ) const
inline

The documentation for this class was generated from the following files: