Keras from Soup to Nuts – An Example Driven Tutorial


Keras, with its intuitive API, has traditionally been one of the easiest ways to get started with building Deep Learning models. In the past, this ease of use came with some major tradeoffs to flexibility. However, through the relentless efforts of its creator and user community, Keras has seen several face-lifts, and the need for tradeoffs have largely been eliminated. Not surprisingly, its one of the most popular platforms used for developing Deep Learning models today.

This workshop hopes to convince participants that Keras is a worthwhile addition to their Machine Learning toolbelt. It teaches them how to build their own Keras models, initially using components already available in Keras, then extend them by customizing some of these components, and finally exploit the underlying Tensorflow platform for maximum flexibility and performance. They will also be able to work with the many cool (sometimes SOTA) models shared by the Keras community.

Session Outline
Part I (45 mins): Learn why Keras deserves your attention, get an example-driven overview of functionality Keras offers out of the box, and learn to use these building blocks to build your own deep learning classifier. Participants will learn how to build a Keras model by the end of this module.

Part II (45 mins): Continue your Keras journey by looking at ways by which you can simplify your code and make your network perform better, by utilizing advanced features of Keras. Also learn about ways in which you can customize and extend Keras. Participants will apply these learnings to improve the model they built in Part I.

Part III (45 mins): Take your Keras skills to the next level by learning how to take advantage of the underlying Tensorflow platform (take over the training loop with GradientTape, speed up computation with @tf.function, train your model using multiple GPUs and work with TPUs on Collab). Reference code illustrating these concepts will be provided. We will also provide pointers to Keras resources for participants to explore on their own after the tutorial.

Background Knowledge
Ability to program in Python. Some knowledge of Machine Learning and/or Deep Learning desired but not required.


Sujit Pal is an applied data scientist at Elsevier Labs, an advanced technology group within the Reed-Elsevier Group of companies. His areas of interests include Semantic Search, Natural Language Processing, Machine Learning and Deep Learning. At Elsevier, he has worked on several machine learning initiatives involving large image and text corpora, and other initiatives around recommendation systems and knowledge graph development. He has co-authored Deep Learning with Keras ( and Deep Learning with Tensorflow 2.x and Keras (, and writes about technology on his blog Salmon Run (