Thanks, it seems to me the best to way to fix this issue is not to require 
users to supply the correct input names, since this is an impl detail of torch 
and we can figure out the names in `from_pytorch`.
 Instead, users should just supply a list of input shapes in correct order. We 
call `get_graph_input_names()` after we run `_run_jit_passes` as you proposed, 
and zip names with a list of shape to get  `input_shapes`. This way, users 
don't have to bother with input names anymore and we can also remove 
`_check_input_names`.

The only downside is that the API would deviate from other frontends. 
Personally I don't think that is an issue and we should an make API that most 
makes sense for Torch. Since Torch frontend is still new, we can fix it now.

What do you think? cc @alexwong @zhiics  @pyjhzwh If we all agree to change the 
API (`input_shapes` would become a list of shapes, not a dict as in other 
frontend), we can proceed to fix it.





---
[Visit 
Topic](https://discuss.tvm.ai/t/pytorch-frontend-graph-input-names-can-change-using-loaded-torchscript/6055/2)
 to respond.

You are receiving this because you enabled mailing list mode.

To unsubscribe from these emails, [click 
here](https://discuss.tvm.ai/email/unsubscribe/a40ade0a31644c5f61ce1b2b4f2cad5e716dc43864beba7add66cf78e00be565).

Reply via email to