// TODO TFLDiv
-// TODO TFLMaxPool2D
+/**
+ * @brief MAX_POOL_2D in TensorFlow Lite
+ */
+class TFLMaxPool2D final : public FixedArityNode<1, TFLNodeImpl<TFLOpcode::MAX_POOL_2D>>
+{
+public:
+ TFLMaxPool2D()
+ : _fused_act_fun(FusedActFunc::UNDEFINED), _padding(Padding::UNDEFINED) { /* empty */}
+
+public:
+ loco::Node *value(void) const { return at(0)->node(); }
+ void value(loco::Node *node) { at(0)->node(node); }
+
+ FusedActFunc fusedActivationFunction() const { return _fused_act_fun; }
+ void fusedActivationFunction(FusedActFunc fused_act_fun) { _fused_act_fun = fused_act_fun; }
+
+ Padding padding() const { return _padding; }
+ void padding(Padding padding) { _padding = padding; }
+
+ const Filter *filter(void) const { return &_filter; }
+ Filter *filter(void) { return &_filter; }
+
+ const Stride *stride(void) const { return &_stride; }
+ Stride *stride(void) { return &_stride; }
+
+private:
+ FusedActFunc _fused_act_fun;
+ Padding _padding;
+ Stride _stride;
+ Filter _filter;
+};
// TODO TFLMul
// TODO TFLDiv
-// TODO TFLMaxPool2D
+bool TFLNodeSummaryBuilder::summary(const locoex::TFLMaxPool2D *node, locop::NodeSummary &s) const
+{
+ s.opname("TFL.MAX_POOL_2D");
+ s.args().append("input", tbl()->lookup(node->value()));
+ s.state(locop::NodeSummary::State::PartiallyKnown);
+ return true;
+}
// TODO TFLMul