Is it production ready for serving PyTorch models? How about if I wanted to use something like Go to serve those models? That's fairly straightforward with Keras (Python) trained TF models.
In our team, We serve PyTorch models in production using libtorch. A C++ library for loading models. You can easily call the C++ code in Go if you wrap it in a C interface.
Last I checked there was basically zero serving story for pytorch. The trade off seems all to common, tensorflow optimizes for enormous production applications first while pytorch optimizes for developer ease first.
If you are trying to apply one of these libraries to a production system that doesn’t get a lot of throughput you probably shouldn’t be using them (try a linear model first). If you have a high throughput application you probably want tensorflow and just deal with the shittyness.
Re:Tensorflow 2.0
by applecrazy on Monday September 30, 2019 @02:44PM
(#21118432)
I'm actually looking to learn PyTorch. Where's the best place to start?
Re:Tensorflow 2.0
by rm_-rf_slash on Monday September 30, 2019 @03:20PM
(#21118763)
If you have any existing ML/DL experience, picking up PyTorch is a breeze. You could get a pretty solid understanding of the framework with an MNIST handwritten digit recognition model over the course of an afternoon, so don’t sweat looking for the “right” tutorial.
Re:Tensorflow 2.0
by applecrazy on Monday September 30, 2019 @03:38PM
(#21118935)
Awesome, I've done some ML before. I'll just dive into the docs.
Re:Tensorflow 2.0
by mitchellgoffpc on Monday September 30, 2019 @05:51PM
(#21120031)
Highly recommend it! I love pytorch so much, it's basically numpy with automatic backprop and CUDA support. It evaluates eagerly by default, which makes debugging a lot easier since you can just print your tensors, and IMO it's much simpler to jump between high-level and low-level details in pytorch than in tensorflow+keras. Just as one example, activation functions in pytorch are applied by calling a python function on your layer, instead of passing a string argument with the function name to the layer constructor, so you write
layer = F.relu(Linear()(input))
instead of layer = Dense(activation_fn='relu')(input)
As a result, it's a lot more straightforward to try out custom activation functions in PyTorch.
Re:Tensorflow 2.0
by travisporter on Monday September 30, 2019 @03:03PM
(#21118607)
Pytorch website has a “blitz” tutorial that was fantastic.
- that’s exactly what we did and we don’t regret that decision