#include <TFShapeInferenceHelper.h>
Definition at line 100 of file TFShapeInferenceHelper.h.
◆ fill()
◆ infer()
Definition at line 132 of file TFShapeInferenceHelper.h.
133 {
134 PlaneShape res;
135
136 if (_padding == "VALID")
137 {
138 res.height =
139 (
p.input.height.value() +
p.stride.height.value() -
p.effective_window.height.value()) /
140 p.stride.height.value();
141 res.width =
142 (
p.input.width.value() +
p.stride.width.value() -
p.effective_window.width.value()) /
143 p.stride.width.value();
144 }
145 else if (_padding == "SAME")
146 {
147 res.height = (
p.input.height.value() +
p.stride.height.value() - 1) /
p.stride.height.value();
148 res.width = (
p.input.width.value() +
p.stride.width.value() - 1) /
p.stride.width.value();
149 }
150 else
151 assert(false);
152
153 return res;
154 }
References moco::PlaneShape::height, p, loco::Dimension::value(), and moco::PlaneShape::width.
◆ operator()()
◆ padding()
void moco::PlaneInference::padding |
( |
const TFPadding & |
value | ) |
|
|
inline |
◆ stride()
void moco::PlaneInference::stride |
( |
const loco::Stride< 2 > |
value | ) |
|
|
inline |
◆ window()
void moco::PlaneInference::window |
( |
const loco::Window< 2 > |
value | ) |
|
|
inline |
The documentation for this class was generated from the following file: