7 #include "core/framework/session_options.h"
8 #include <unordered_set>
10 namespace onnxruntime {
12 struct IndexedSubGraph;
15 namespace onnxruntime {
146 #if !defined(ORT_MINIMAL_BUILD)
173 #if !defined(ORT_MINIMAL_BUILD) || defined(ORT_EXTENDED_MINIMAL_BUILD)
190 #if !defined(ORT_MINIMAL_BUILD)
195 ORT_DISALLOW_COPY_ASSIGNMENT_AND_MOVE(
GraphViewer);
202 std::vector<NodeIndex> nodes_in_topological_order_;
204 #if !defined(ORT_MINIMAL_BUILD)
206 std::vector<NodeIndex> nodes_in_topological_order_with_priority_;
210 std::vector<NodeIndex> root_nodes_;
215 using FilteredNodeSet = InlinedHashSet<NodeIndex>;
216 FilteredNodeSet filtered_node_indices_;
217 std::vector<const NodeArg*> filtered_node_inputs_;
218 std::vector<const NodeArg*> filtered_node_inputs_including_initializers_;
219 std::vector<const NodeArg*> filtered_node_outputs_;
std::unordered_map< std::string, const ONNX_NAMESPACE::TensorProto * > InitializedTensorSet
const IndexedSubGraph * GetFilterInfo() const
const Node * ParentNode() const noexcept
IOnnxRuntimeOpSchemaCollectionPtr GetSchemaRegistry() const
bool IsConstantInitializer(const std::string &name, bool check_outer_scope) const
std::shared_ptr< IOnnxRuntimeOpSchemaCollection > IOnnxRuntimeOpSchemaCollectionPtr
const InitializedTensorSet & GetAllInitializedTensors() const noexcept
bool operator()(const Node *n1, const Node *n2) const
const std::vector< const NodeArg * > & GetInputs() const noexcept
GLsizei const GLchar *const * string
int NumberOfNodes() const noexcept
const Node * ParentNode() const
bool NodeProducesGraphOutput(const Node &node) const
const std::unordered_map< std::string, int > & DomainToVersionMap() const noexcept
bool IsInitializedTensor(const std::string &name) const
const Path & ModelPath() const noexcept
int MaxNodeIndex() const noexcept
const ONNX_NAMESPACE::TensorProto * GetConstantInitializer(const std::string &name, bool check_outer_scope) const
const std::string & Description() const noexcept
const std::string & Name() const noexcept
IOnnxRuntimeOpSchemaCollectionPtr GetSchemaRegistry() const
GraphViewer(const Graph &graph)
const Node * GetProducerNode(const std::string &node_arg_name) const
const ConstGraphNodes & Nodes() const noexcept
const std::unordered_set< const NodeArg * > & GetValueInfo() const noexcept
const std::vector< NodeIndex > & GetRootNodes() const
GLdouble GLdouble GLint GLint order
GLuint const GLchar * name
bool CanOverrideInitializer() const noexcept
const std::vector< const NodeArg * > & GetInputsIncludingInitializers() const noexcept
const Node * GetProducerNode(const std::string &node_arg_name) const
const std::unordered_set< std::string > & GetOuterScopeNodeArgNames() const noexcept
const std::vector< const NodeArg * > & GetOutputs() const noexcept
const Path & ModelPath() const
std::vector< const Node * > GetConsumerNodes(const std::string &node_arg_name) const
const Node * GetNode(NodeIndex node_index) const
const Graph & GetGraph() const
const NodeArg * GetNodeArg(const std::string &name) const
std::unordered_map< std::string, int > DomainToVersionMap
const std::vector< NodeIndex > & GetNodesInTopologicalOrder(ExecutionOrder order=ExecutionOrder::DEFAULT) const
std::vector< const Node * > GetConsumerNodes(const std::string &node_arg_name) const
bool GetInitializedTensor(const std::string &tensor_name, const ONNX_NAMESPACE::TensorProto *&value) const