Hacker News new | ask | show | jobs
by x3tm 2702 days ago
How about tf.keras though?

Im just starting with TF and found keras quite useful to begin with. TF itself feels like assembly language and I'm sure it will evolve to something higher level such as keras in the near future.

I have never used PyTorch though, will check it out. I would appreciate your thoughts on tf.keras vs pytorch.

1 comments

Not flexible enough for research (you still have to deal with the horrible TensorFlow API that's underneath at some point), but good if you just want to implement or use something that already exists. Not good for models in which graph changes dynamically. Actually "flexible" is probably not the right word. You can make it do what you want, but you will spend a lot longer and the result will likely be unreadable.

But a better question is, why bother with Keras at all, if PyTorch gives you a higher performance, more flexible, more "Pythonic" solution? And yes, did I mention performance? PyTorch blows the socks off anything TF based on most training and inference tasks.

Thanks. I admit what made me chose TF is the support from Google which guarantees somehow that the tool will stick around for some time. And the numbers of contributors to the library. Where do you see PyTorch in the near future?
I see it overtaking TF as the framework of choice for researchers and practitioners alike. I also see TF moving closer and closer API-wise to PyTorch's superior API. This is already starting in 2.0 with imperative mode, but due to the amount of legacy code already written for earlier versions, they have a massive brake on their efforts, something PyTorch (which got it more or less "right" from the beginning) does not. Finally, Google is working on Cloud TPU support for PyTorch as we speak.