Add const iterate method to Linear
Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
return tensor_builders;
}
+void Linear::iterate(const std::function<void(const graph::operation::Node *)> &fn) const
+{
+ for (const auto op : _operations)
+ {
+ fn(op);
+ }
+}
+
} // namespace linear
} // namespace neurun
// TODO Should not return TensorBuilderSet
backend::TensorBuilderSet planTensors();
+ void iterate(const std::function<void(const graph::operation::Node *)> &fn) const;
+
private:
const graph::Graph &_graph;
std::vector<const graph::operation::Node *> _operations;