Serving Model Trained with PyTorch

(Kaiyin Zhong) #21

@Eugenio_Culurciello Could you post a link to your pytorch exporter? Thanks!


ping @Eugenio_Culurciello. I would also love to see the exporter you are building.

(Eugenio Culurciello) #23

see, it is included there

(Eugenio Culurciello) #24

but looks like things have changed in the pytorch format and this may not work now.
I am not sure what is the best way to convert from pytorch to other framworks

(hopeful Liu) #25

I try to get all the parameter’s value to reconstruct the graph in C++ and serve.
I used to get the Parameter Instance by Variable.creator’s previous_functions, so I can export it’s shape and value.and other attributes in special layer(dropout’s P for example).
now I update my pytorch from master branch, and use grad_fn’s next_functions instead, but get some XXBackwards stuffs, how could I get the parameter again (eg. the Linear Layers’ weight and bias value)

(Herleeyandi Markoni) #26

Hello can I doing something like this?

  1. I am creating CNN network and model which is trained in Pytorch (this is static with the fixed size and fixed number of layer)
  2. Then in deploying process, I am using C/C++ language to load the model and code the network so it can be run in C
    So just the deploying part is in C/C++, the train is in Pytorch, and can I also do it in windows?, If it possibly done, may I know the starting point to learn it, because I really new in this kind of stuff.
    -Thank you-

(Daniil Pakhomov) #27

This might be useful:


I think this link would be helpful:
[Feature Request] Deployment in c++ project