Interface: TorchFxNode
Defined in: ml/model.ts:180
One node of a traced torch.fx graph. Produce it in Python with:
python
gm = torch.fx.symbolic_trace(model)
[{"name": n.name, "op": n.op, "target": str(n.target),
"args": [a.name for a in n.all_input_nodes]} for n in gm.graph.nodes]Properties
args?
ts
optional args?: string[];Defined in: ml/model.ts:187
Names of the input nodes ([a.name for a in n.all_input_nodes]).
flops?
ts
optional flops?: number;Defined in: ml/model.ts:192
moduleType?
ts
optional moduleType?: string;Defined in: ml/model.ts:189
type(module).__name__ for call_module nodes — the nicest display type.
name
ts
name: string;Defined in: ml/model.ts:181
op
ts
op: string;Defined in: ml/model.ts:183
placeholder | call_module | call_function | call_method | get_attr | output.
params?
ts
optional params?: number;Defined in: ml/model.ts:191
shape?
ts
optional shape?: number[];Defined in: ml/model.ts:190
target?
ts
optional target?: string;Defined in: ml/model.ts:185
Module path or function name.