megengine.utils.comp_graph_tools.GraphInference

class GraphInference(file, outputs=None, profiling=False, optimize_for_inference=False, **kwargs)[源代码]

Loads a serialized computing graph as a GraphInference object which can be used to execute the computing graph.

参数
  • file – 输出文件,可以是文件对象或文件名

  • outputs (Optional[List[str]]) – only compile the subgraph with outputs as its endpoints.

__init__(file, outputs=None, profiling=False, optimize_for_inference=False, **kwargs)[源代码]

方法

__init__(file[, outputs, profiling, ...])

run(*inp_args[, inp_dict])

type inp_args

ndarray