Use costom torch.jit.script

Can you please tell me what are the restrictions on using torch.jit.script?

We use non-trivial imputs from Tuple, how do we pass them to the input?

  • we have append(Tuple[]), is it supported?

now we have error: NotImplementedError: The following operators are not implemented: [‘aten::append’, ‘aten::_set_item’, ‘prim::unchecked_cast’, ‘prim::SetAttr’, ‘aten::cpu’, ‘aten::randint’, ‘prim::TupleIndex’]

torch.jit.script is not recommended precisely because it generates irrelevant garbages like ‘prim::SetAttr’, ‘aten::cpu’ you saw.

1 Like