PyTorch + Golang?

I’m aware that PyTorch 1.0 now supports deployment to C++ using tracing, etc. and there’s also ONNX for cross-framework deployments. I’m wondering if there’s any recommendation about running models in a production Golang API?

The only option I could think of would be PyTorch->ONNX->TensorFlow to use TF’s Go bindings, which seems like a very indirect path.

Any additional tips would be helpful!

6 Likes

at the moment that’s your best bet. Alternatively writing Go -> PyTorch C++ bindings for the functions you want, but that seems like it’ll be maintenance overhead for you.

4 Likes

Thanks Soumith! I hope that Go bindings (and generally more language bindings) might be on the roadmap for future PyTorch! :slight_smile:

5 Likes
4 Likes