base
torch_to_nnef.inference_target.base
InferenceTarget
Base abstract class to implement a new inference engine target.
Init InferenceTarget.
Each inference engine is supposed to have at least a version and a way to check output given an input.
has_dynamic_axes
property
Define if user request dynamic axes to be in the NNEF graph.
Some inference engines may not support it hence False by default.
post_export
post_export(model: nn.Module, nnef_graph: NGraph, args: T.List[T.Any], exported_filepath: Path, debug_bundle_path: T.Optional[Path] = None)
Get called after NNEF model asset is generated.
This is typically where check_io is effectively applied.
post_trace
Get called just after PyTorch graph is parsed.