ONE - On-device Neural Engine
Loading...
Searching...
No Matches
luci::sinf::Rule Struct Reference

#include <CircleShapeInference.h>

Public Member Functions

bool infer (const luci::CircleNode *, loco::TensorShape &) const
 

Detailed Description

Definition at line 33 of file CircleShapeInference.h.

Member Function Documentation

◆ infer()

bool luci::sinf::Rule::infer ( const luci::CircleNode circle_node,
loco::TensorShape shape 
) const

Definition at line 67 of file CircleShapeInference.cpp.

68{
69 LOGGER(l);
70 VERBOSE(l, 1) << "[CircleShapeInference] " << circle_node->name();
71 VERBOSE(l, 1) << " before: " << circle_shape(circle_node);
72
73 if (!inputs_shape_ready(circle_node))
74 {
75 VERBOSE(l, 1) << " after: Some inputs are not ready for inference";
76 return false;
77 }
78
79 Algorithm alg;
80 shape = circle_node->accept(&alg);
81 VERBOSE(l, 1) << " after: " << shape;
82
83 return true;
84}
#define LOGGER(name)
Definition Log.h:65
#define VERBOSE(name, lv)
Definition Log.h:71
Algorithm
Definition kuma.h:28
loco::TensorShape circle_shape(const luci::CircleNode *node)
NodeName name(void) const
T accept(CircleNodeVisitorBase< T > *) const

References luci::CircleNode::accept(), luci::sinf::circle_shape(), LOGGER, luci::CircleNode::name(), and VERBOSE.

Referenced by luci::CircleShapeInferencePass::run().


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