Caffe2 - C++ API
A deep learning, cross platform ML framework
Public Member Functions | Friends
torch::jit::Graph Struct Reference

Public Member Functions

 Graph (ScopePtr scope_root)
at::ArrayRef< Value * > inputs ()
at::ArrayRef< const Value * > inputs () const
at::ArrayRef< Value * > outputs ()
at::ArrayRef< const Value * > outputs () const
graph_node_list nodes ()
const_graph_node_list nodes () const
Nodeparam_node ()
const Nodeparam_node () const
Nodereturn_node ()
const Nodereturn_node () const
const std::unordered_map< std::string, Value * > & uniqueNames () const
void push_scope (const std::string &scope_name)
void pop_scope ()
ScopePtr current_scope ()
void set_current_scope (ScopePtr scope)
ValueaddInput (std::string name="")
ValueinsertInput (size_t i, std::string name="")
void eraseInput (size_t i)
size_t registerOutput (Value *n)
void eraseOutput (size_t i)
TORCH_API Nodecreate (NodeKind kind, size_t num_outputs=1)
TORCH_API Nodecreate (NodeKind kind, ArrayRef< Value * > inputs, size_t num_outputs=1)
TORCH_API NodecreateNone (TypePtr typ)
TORCH_API NodecreateAutogradZero ()
TORCH_API NodecreateFusionGroup ()
TORCH_API NodecreateDifferentiableSubgraph ()
TORCH_API NodecreateTuple (at::ArrayRef< Value * > values, c10::OptNameList field_names=c10::nullopt)
TORCH_API NodecreateTupleUnpack (Value *v)
TORCH_API NodecreateTupleIndex (Value *tup, int64_t index)
TORCH_API NodecreateTupleSlice (Value *tup, int64_t beg, int64_t end)
TORCH_API NodecreateList (const TypePtr &elem_type, at::ArrayRef< Value * > values)
TORCH_API NodecreateListUnpack (Value *v, size_t size)
TORCH_API NodecreateDict (const TypePtr &key_type, const TypePtr &value_type, at::ArrayRef< Value * > keys, at::ArrayRef< Value * > values)
TORCH_API NodecreateDictIndex (Value *dict, Value *index)
TORCH_API NodecreateNumToTensor (Value *value)
TORCH_API NodecreateImplicitTensorToNum (const TypePtr &type, Value *value)
TORCH_API NodecreateObject (const ClassTypePtr &type)
TORCH_API NodecreateSetAttr (Value *obj, const std::string &field, Value *newValue)
TORCH_API NodecreateGetAttr (Value *obj, const std::string &field)
NodecreatePythonOp (THPObjectPtr &&pyobj, const std::string &cconv, pyobj_list &&scalar_args)
TORCH_API NodecreateClone (Node *n, const std::function< Value *(Value *)> &value_map, bool copy_blocks=true)
TORCH_API ValueinsertConstant (IValue val, const TypePtr &result_type=nullptr, c10::optional< SourceRange > loc=c10::nullopt, c10::optional< ScopePtr > scope=c10::nullopt)
TORCH_API Valueinsert (Symbol opname, at::ArrayRef< NamedValue > args, at::ArrayRef< NamedValue > kwargs={}, const c10::optional< SourceRange > &range={})
NodeappendNode (Node *n)
NodeprependNode (Node *n)
NodeinsertNode (Node *n)
void setInsertPoint (Block *b)
void setInsertPoint (Node *n)
NodeinsertPoint ()
Blockblock ()
const Blockblock () const
TORCH_API void lint () const
TORCH_API void dump () const
TORCH_API std::string toString () const
TORCH_API std::ostream & prettyPrint (std::ostream &out)
TORCH_API void dumpPretty ()
TORCH_API std::shared_ptr< Graphcopy ()


struct Node
struct Value
struct Block
TORCH_API std::ostream & operator<< (std::ostream &out, const Graph &g)

Detailed Description

Definition at line 936 of file ir.h.

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