title
Keras Tutorial For Beginners | Creating Deep Learning Models Using Keras In Python | Edureka

description
** AI & Deep Learning Training: https://www.edureka.co/ai-deep-learning-with-tensorflow ** This Edureka Tutorial on "Keras Tutorial" (Deep Learning Blog Series: https://goo.gl/4zxMfU) provides you a quick and insightful tutorial on the working of Keras along with an interesting use-case! We will be checking out the following topics: 00:27 Agenda 00:59 What is Keras? 01:52 Who makes Keras? 02:28 Who uses Keras? 02:54 What Makes Keras special? 05:47 Working principle of Keras 06:54 Keras Models 09:02 Understanding Execution 09:56 Implementing a Neural Network 11:36 Use-Case with Keras 15:54 Coding in Colaboratory 26:08 Session in a minute Do subscribe to our channel and hit the bell icon to never miss an update from us in the future: https://goo.gl/6ohpTV Check out our Deep Learning blog series: https://bit.ly/2xVIMe1 Check out our complete Youtube playlist here: https://bit.ly/2OhZEpz PG in Artificial Intelligence and Machine Learning with NIT Warangal : https://www.edureka.co/post-graduate/machine-learning-and-ai Post Graduate Certification in Data Science with IIT Guwahati - https://www.edureka.co/post-graduate/data-science-program (450+ Hrs || 9 Months || 20+ Projects & 100+ Case studies) ------------------------------------- Instagram: https://www.instagram.com/edureka_learning/ Facebook: https://www.facebook.com/edurekaIN/ Twitter: https://twitter.com/edurekain LinkedIn: https://www.linkedin.com/company/edureka #Keras #KerasTutorial #DeepLearning #Python ------------------------------------- Got a question on the topic? Please share it in the comment section below and our experts will answer it for you. About the Course Edureka's Deep learning with Tensorflow course will help you to learn the basic concepts of TensorFlow, the main functions, operations and the execution pipeline. Starting with a simple “Hello Word” example, throughout the course you will be able to see how TensorFlow can be used in curve fitting, regression, classification and minimization of error functions. This concept is then explored in the Deep Learning world. You will evaluate the common, and not so common, deep neural networks and see how these can be exploited in the real world with complex raw data using TensorFlow. In addition, you will learn how to apply TensorFlow for backpropagation to tune the weights and biases while the Neural Networks are being trained. Finally, the course covers different types of Deep Architectures, such as Convolutional Networks, Recurrent Networks and Autoencoders. Delve into neural networks, implement Deep Learning algorithms, and explore layers of data abstraction with the help of this Deep Learning with TensorFlow course. - - - - - - - - - - - - - - Who should go for this course? The following professionals can go for this course: 1. Developers aspiring to be a 'Data Scientist' 2. Analytics Managers who are leading a team of analysts 3. Business Analysts who want to understand Deep Learning (ML) Techniques 4. Information Architects who want to gain expertise in Predictive Analytics 5. Professionals who want to captivate and analyze Big Data 6. Analysts wanting to understand Data Science methodologies However, Deep learning is not just focused to one particular industry or skill set, it can be used by anyone to enhance their portfolio. - - - - - - - - - - - - - - Why Learn Deep Learning With TensorFlow? TensorFlow is one of the best libraries to implement Deep Learning. TensorFlow is a software library for numerical computation of mathematical expressions, using data flow graphs. Nodes in the graph represent mathematical operations, while the edges represent the multidimensional data arrays (tensors) that flow between them. It was created by Google and tailored for Machine Learning. In fact, it is being widely used to develop solutions with Deep Learning. How it Works? 1. This is 21 hrs of Online Live Instructor-led course. Weekend class: 7 sessions of 3 hours each. 2. We have a 24x7 One-on-One LIVE Technical Support to help you with any problems you might face or any clarifications you may require during the course. 3. At the end of the training you will have to undergo a 2-hour LIVE Practical Exam based on which we will provide you a Grade and a Verifiable Certificate! - - - - - - - - - - - - - - Got a question on the topic? Please share it in the comment section below and our experts will answer it for you. For more information, please write back to us at sales@edureka.co or call us at IND: 9606058406 / US: 18338555775 (toll-free).

detail
{'title': 'Keras Tutorial For Beginners | Creating Deep Learning Models Using Keras In Python | Edureka', 'heatmap': [{'end': 480.197, 'start': 444.429, 'weight': 1}, {'end': 530.508, 'start': 505.858, 'weight': 0.713}], 'summary': 'Introduces keras, a popular deep learning framework, highlighting its simplicity, active development, high performance, and widespread adoption, aiming to kickstart the learning for deep learning enthusiasts. it also explains keras api, model comparison, execution types, and implementing neural networks, and demonstrates setting up tensorflow and keras for machine learning, building wide models for wine price prediction, and constructing wide and deep models, achieving an average prediction difference of $10 for every wine bottle and an accuracy improvement from 0.02 to 0.0994 over 10 epochs.', 'chapters': [{'end': 226.226, 'segs': [{'end': 91.707, 'src': 'embed', 'start': 64.155, 'weight': 2, 'content': [{'end': 69.378, 'text': 'Well Keras is a python-based deep learning framework, which is actually the high-level API of TensorFlow.', 'start': 64.155, 'duration': 5.223}, {'end': 72.186, 'text': 'And now I have four major highlights for you guys.', 'start': 70.083, 'duration': 2.103}, {'end': 73.467, 'text': "So let's check it out from the start.", 'start': 72.226, 'duration': 1.241}, {'end': 78.133, 'text': 'Well, Kiras basically runs on top of Tiano TensorFlow or CNT game.', 'start': 73.708, 'duration': 4.425}, {'end': 82.999, 'text': 'since it runs on top of any of these frameworks, Kiras is amazingly simple to work with.', 'start': 78.133, 'duration': 4.866}, {'end': 84.56, 'text': 'you might be wondering why.', 'start': 82.999, 'duration': 1.561}, {'end': 88.906, 'text': 'well, building models are as simple as stacking layers and later connecting these graphs.', 'start': 84.56, 'duration': 4.346}, {'end': 91.707, 'text': 'Guys Kiras attracts a lot of attention.', 'start': 89.366, 'duration': 2.341}], 'summary': 'Keras, a high-level api of tensorflow, is simple to work with, running on top of tensorflow, tiano, or cnt game, making model building as easy as stacking layers and connecting graphs. it has garnered a lot of attention.', 'duration': 27.552, 'max_score': 64.155, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY64155.jpg'}, {'end': 140.735, 'src': 'embed', 'start': 120.163, 'weight': 0, 'content': [{'end': 130.389, 'text': 'Well guys Kiras had over 4800 contributors during its launch and the initial stages and now that number has gone up to 250, 000 active developers.', 'start': 120.163, 'duration': 10.226}, {'end': 136.452, 'text': 'Well, what amuses me is that there is a 2x growth ever since, every year since its launch.', 'start': 130.809, 'duration': 5.643}, {'end': 140.735, 'text': 'also, it holds a really good amount of traction among multiple startups.', 'start': 136.452, 'duration': 4.283}], 'summary': 'Kiras had over 4800 contributors at launch, now 250,000 active developers, with 2x growth annually, gaining traction among startups.', 'duration': 20.572, 'max_score': 120.163, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY120163.jpg'}, {'end': 202.535, 'src': 'embed', 'start': 177.66, 'weight': 1, 'content': [{'end': 184.022, 'text': 'Well guys the focus on user experience has always been the major part of Keras and next large adoption in the industry.', 'start': 177.66, 'duration': 6.362}, {'end': 188.243, 'text': 'Definitely. We just checked out all of the industry traction it gets, and this holds well.', 'start': 184.202, 'duration': 4.041}, {'end': 191.424, 'text': 'and next it is multi backend and supports multi-platform as well.', 'start': 188.243, 'duration': 3.181}, {'end': 194.365, 'text': 'This helps all the coders come together and code easily.', 'start': 191.804, 'duration': 2.561}, {'end': 199.733, 'text': 'Next up the research community present for Kiras is amazing along with the production community.', 'start': 195.169, 'duration': 4.564}, {'end': 201.274, 'text': 'So this is a win-win for me guys.', 'start': 199.773, 'duration': 1.501}, {'end': 202.535, 'text': 'So what do you think?', 'start': 201.294, 'duration': 1.241}], 'summary': 'Keras prioritizes user experience, with widespread adoption, multi-platform support, and strong community presence.', 'duration': 24.875, 'max_score': 177.66, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY177660.jpg'}], 'start': 11.451, 'title': 'Introduction to keras - a deep learning framework', 'summary': 'Introduces keras, a popular deep learning framework, emphasizing its simplicity, active development, high performance, and widespread adoption with over 250,000 active developers and 2x growth annually, aiming to kickstart the learning for deep learning enthusiasts.', 'chapters': [{'end': 63.795, 'start': 11.451, 'title': 'Introduction to keras', 'summary': 'Introduces keras, a popular deep learning framework, providing insights on its contributors, offered models, steps for implementing a neural network, and a use case, aiming to kickstart the learning for deep learning enthusiasts.', 'duration': 52.344, 'highlights': ['Keras is a popular and widely used deep learning framework, suitable for anyone considering to kickstart learning about Keras and gain insight about the framework.', 'The session covers the contributors, models offered, steps to implement a neural network, and a use case, providing comprehensive insights into Keras for deep learning enthusiasts.', 'The agenda includes understanding what Keras actually is, contributors, models, steps for implementing a neural network, and a use case, focusing on approaching the framework for deep learning enthusiasts.']}, {'end': 140.735, 'start': 64.155, 'title': 'Introduction to keras - a deep learning framework', 'summary': 'Introduces keras, a high-level api of tensorflow, emphasizing its simplicity, active development, high performance, and widespread adoption with over 250,000 active developers and 2x growth annually.', 'duration': 76.58, 'highlights': ['Keras had over 4800 contributors during its launch and now has 250,000 active developers, with a 2x growth annually, showcasing its significant traction and adoption among startups.', 'Keras is an API used to specify and train differentiable programs, leading to high performance, making it simple to work with and attracting considerable attention due to its active open-source development and extensive documentation.', 'Keras runs on top of TensorFlow, Tiano, or CNT game, making it remarkably simple to work with by allowing the easy building of models through stacking and connecting layers, emphasizing its user-friendly design.', 'Keras is open source and actively developed by contributors worldwide, with extensive documentation and high performance, making it a highly attractive deep learning framework.']}, {'end': 226.226, 'start': 140.735, 'title': 'Keras: a game changer in industry', 'summary': 'Highlights how big players like microsoft, google, nvidia, and amazon actively contribute to the development of keras, which is widely used by popular firms like netflix, uber, and expedia due to its user experience focus, multi-backend support, strong community presence, ease of grasping concepts, and seamless cpu and gpu processing, making it a game changer in the industry.', 'duration': 85.491, 'highlights': ['Keras is widely used by popular firms like Netflix, Uber, and Expedia due to its user experience focus, multi-backend support, and strong community presence.', 'Big players like Microsoft, Google, Nvidia, and Amazon actively contribute to the development of Keras.', 'Keras supports fast processing, making it highly efficient.', 'Keras runs seamlessly on both the CPU and the GPU and has support for both Nvidia and AMD.', 'Keras provides the freedom to design on any architecture and then later implement it as an API for projects.']}], 'duration': 214.775, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY11451.jpg', 'highlights': ['Keras had over 4800 contributors during its launch and now has 250,000 active developers, with a 2x growth annually, showcasing its significant traction and adoption among startups.', 'Keras is widely used by popular firms like Netflix, Uber, and Expedia due to its user experience focus, multi-backend support, and strong community presence.', 'Keras is open source and actively developed by contributors worldwide, with extensive documentation and high performance, making it a highly attractive deep learning framework.', 'Keras runs on top of TensorFlow, Tiano, or CNT game, making it remarkably simple to work with by allowing the easy building of models through stacking and connecting layers, emphasizing its user-friendly design.', 'Keras supports fast processing, making it highly efficient.']}, {'end': 542.078, 'segs': [{'end': 273.464, 'src': 'embed', 'start': 247.59, 'weight': 2, 'content': [{'end': 252.953, 'text': 'Well in my opinion, this is very important for anyone who wants to know more about Keras or better.', 'start': 247.59, 'duration': 5.363}, {'end': 255.775, 'text': 'They want to start creating their own neural nets using Keras.', 'start': 253.034, 'duration': 2.741}, {'end': 258.877, 'text': 'So clearly Keras is an API designed for humans.', 'start': 256.236, 'duration': 2.641}, {'end': 260.338, 'text': 'Well, why so?', 'start': 259.278, 'duration': 1.06}, {'end': 268.224, 'text': 'because it follows the best practices for reducing cognitive load, which ensures that the models are consistent and the corresponding APIs are simple.', 'start': 260.338, 'duration': 7.886}, {'end': 273.464, 'text': 'and moving on, Kiras provides clear feedback upon occurrence of any error,', 'start': 268.9, 'duration': 4.564}], 'summary': 'Keras is important for creating neural nets, designed for humans, follows best practices, and provides clear feedback.', 'duration': 25.874, 'max_score': 247.59, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY247590.jpg'}, {'end': 316.779, 'src': 'embed', 'start': 288.898, 'weight': 3, 'content': [{'end': 293.54, 'text': 'It integrates with lower level deep learning framework languages like TensorFlow or Tiano.', 'start': 288.898, 'duration': 4.642}, {'end': 300.102, 'text': 'So guys this ensures that you can implement anything in Keras which you actually built in your base language, which is amazing.', 'start': 293.96, 'duration': 6.142}, {'end': 307.715, 'text': 'So next up we need to talk about how Keras supports the claim of being able to support multi-platform and lets us work with multiple backends.', 'start': 300.791, 'duration': 6.924}, {'end': 316.779, 'text': 'You can develop Keras in Python as well as are the code can be run with tensorflow CNTK Tiano or MX net totally based on your requirement.', 'start': 308.295, 'duration': 8.484}], 'summary': 'Keras supports multi-platform, compatible with tensorflow, cntk, tiano, mxnet.', 'duration': 27.881, 'max_score': 288.898, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY288898.jpg'}, {'end': 484.5, 'src': 'heatmap', 'start': 430.222, 'weight': 1, 'content': [{'end': 436.905, 'text': 'It is majorly useful for building simple classification Network and encoder, decoder model, guys, and definitely, yes,', 'start': 430.222, 'duration': 6.683}, {'end': 438.886, 'text': 'this is the model which we all know and love.', 'start': 436.905, 'duration': 1.981}, {'end': 443.889, 'text': 'So here we basically treat every layer as an object that feeds into the next layer and so on.', 'start': 439.026, 'duration': 4.863}, {'end': 447.354, 'text': 'and now in the simple code will import Keras into Python.', 'start': 444.429, 'duration': 2.925}, {'end': 450.298, 'text': 'We define the model as sequential and with the hidden layers.', 'start': 447.594, 'duration': 2.704}, {'end': 454.825, 'text': 'We have 20 neurons and will be using a relu here relu is rectified linear unit guys.', 'start': 450.338, 'duration': 4.487}, {'end': 456.287, 'text': 'It is one of the activation functions.', 'start': 454.845, 'duration': 1.442}, {'end': 459.732, 'text': "We'll be using well model dot fit is used to train the network.", 'start': 456.307, 'duration': 3.425}, {'end': 461.26, 'text': 'Here by Epoch.', 'start': 460.319, 'duration': 0.941}, {'end': 463.363, 'text': "I'm sure all of you guys are familiar with it already.", 'start': 461.28, 'duration': 2.083}, {'end': 470.37, 'text': 'So it is basically the forward and the backward pass of all of our training examples and batch size is really straightforward as well.', 'start': 463.763, 'duration': 6.607}, {'end': 474.495, 'text': 'It is the number of training examples in one forward and backward pass guys.', 'start': 470.751, 'duration': 3.744}, {'end': 477.238, 'text': 'So higher the batch size the more the memory you need.', 'start': 474.895, 'duration': 2.343}, {'end': 480.197, 'text': 'So next we need to check out the functional model.', 'start': 478.155, 'duration': 2.042}, {'end': 484.5, 'text': 'It is widely used and it holds good for about 95% of the use cases.', 'start': 480.517, 'duration': 3.983}], 'summary': 'Keras is useful for building classification networks, with 20 neurons in hidden layers and a widely used functional model achieving 95% use cases.', 'duration': 54.278, 'max_score': 430.222, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY430222.jpg'}, {'end': 518.679, 'src': 'embed', 'start': 490.145, 'weight': 0, 'content': [{'end': 491.766, 'text': "It's pretty much the same here as well.", 'start': 490.145, 'duration': 1.621}, {'end': 498.611, 'text': 'Well the highlights of the functional model is that it supports multi input multi output and an arbitrary static graph topology.', 'start': 492.126, 'duration': 6.485}, {'end': 499.752, 'text': 'We have branches.', 'start': 498.992, 'duration': 0.76}, {'end': 505.337, 'text': 'So whenever we have a complex model, the model is forward into two or more branches based on the requirement guys.', 'start': 500.073, 'duration': 5.264}, {'end': 511.572, 'text': 'The code which we have here is pretty much similar to the previous one, but with subtle changes we first import the models.', 'start': 505.858, 'duration': 5.714}, {'end': 514.62, 'text': 'We work on its architecture and lastly we train the network.', 'start': 511.713, 'duration': 2.907}, {'end': 516.577, 'text': 'Well with functional models.', 'start': 515.436, 'duration': 1.141}, {'end': 518.679, 'text': 'We have this concept called as domain adaption.', 'start': 516.616, 'duration': 2.063}], 'summary': 'Functional model supports multi input/output & static graph topology, with domain adaption concept.', 'duration': 28.534, 'max_score': 490.145, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY490145.jpg'}, {'end': 549.009, 'src': 'heatmap', 'start': 505.858, 'weight': 4, 'content': [{'end': 511.572, 'text': 'The code which we have here is pretty much similar to the previous one, but with subtle changes we first import the models.', 'start': 505.858, 'duration': 5.714}, {'end': 514.62, 'text': 'We work on its architecture and lastly we train the network.', 'start': 511.713, 'duration': 2.907}, {'end': 516.577, 'text': 'Well with functional models.', 'start': 515.436, 'duration': 1.141}, {'end': 518.679, 'text': 'We have this concept called as domain adaption.', 'start': 516.616, 'duration': 2.063}, {'end': 524.163, 'text': 'So, guys, what we did until this stage is that we train a model on one domain but test it on the other.', 'start': 519.119, 'duration': 5.044}, {'end': 530.508, 'text': 'this definitely results in poor performance on the overall test data set, because the data is different for each of the domains, right?', 'start': 524.163, 'duration': 6.345}, {'end': 532.15, 'text': "So what's the solution for this?", 'start': 530.889, 'duration': 1.261}, {'end': 540.897, 'text': 'Well, we adapt the model to work on both the domains at the same time and guys will be looking at a very interesting use case using the functional models in the upcoming slides.', 'start': 532.57, 'duration': 8.327}, {'end': 542.078, 'text': 'So stay tuned for that.', 'start': 541.197, 'duration': 0.881}, {'end': 549.009, 'text': 'So moving on we need to understand about the two basic types of execution in Keras deferred and eager execution.', 'start': 543.067, 'duration': 5.942}], 'summary': 'Adapt model for different domains, train and test on both. discuss keras execution types.', 'duration': 43.151, 'max_score': 505.858, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY505858.jpg'}], 'start': 226.826, 'title': 'Keras api and model comparison', 'summary': 'Explains how keras simplifies model production and provides a user-friendly api, supporting multi-platform, and compares sequential and functional models in terms of capabilities and use cases, emphasizing domain adaptation.', 'chapters': [{'end': 414.177, 'start': 226.826, 'title': 'Understanding keras api and user experience', 'summary': 'Highlights how keras simplifies model production and provides a user-friendly api for creating neural nets, supporting multi-platform, and explaining the working principle through computation graphs.', 'duration': 187.351, 'highlights': ['Keras simplifies model production and provides a user-friendly API for creating neural nets', 'Supports multi-platform and multiple backends', 'Explains the working principle through computation graphs']}, {'end': 542.078, 'start': 415.194, 'title': 'Comparing sequential and functional models', 'summary': 'Compares the sequential model, useful for simple classification and encoder-decoder models, with the functional model, which supports multi-input, multi-output, and static graph topology, with a focus on domain adaptation.', 'duration': 126.884, 'highlights': ['The functional model supports multi-input, multi-output, and arbitrary static graph topology, making it widely applicable for about 95% of use cases.', 'The concept of domain adaptation in functional models allows the model to work on multiple domains simultaneously, addressing the issue of poor performance when a model trained on one domain is tested on another.', 'The sequential model is useful for building simple classification networks and encoder-decoder models, treating every layer as an object that feeds into the next layer.', 'In the sequential model, the code involves importing Keras into Python, defining the model as sequential, adding hidden layers with 20 neurons using the rectified linear unit (relu) as an activation function, and training the network using model.fit with the specified batch size and epochs.']}], 'duration': 315.252, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY226826.jpg', 'highlights': ['The functional model supports multi-input, multi-output, and arbitrary static graph topology, applicable for about 95% of use cases.', 'The sequential model is useful for building simple classification networks and encoder-decoder models.', 'Keras simplifies model production and provides a user-friendly API for creating neural nets.', 'Supports multi-platform and multiple backends.', 'The concept of domain adaptation in functional models allows the model to work on multiple domains simultaneously.']}, {'end': 905.112, 'segs': [{'end': 584.246, 'src': 'embed', 'start': 543.067, 'weight': 0, 'content': [{'end': 549.009, 'text': 'So moving on we need to understand about the two basic types of execution in Keras deferred and eager execution.', 'start': 543.067, 'duration': 5.942}, {'end': 552.291, 'text': 'It is also called a symbolic and imperative execution as well.', 'start': 549.33, 'duration': 2.961}, {'end': 553.551, 'text': 'Well with deferred.', 'start': 552.651, 'duration': 0.9}, {'end': 561.734, 'text': 'we use Python to build a computation graph first, like we previously discussed, and then this compiled graph gets executed well with eager execution.', 'start': 553.551, 'duration': 8.183}, {'end': 563.075, 'text': 'There is a slight change guys.', 'start': 561.774, 'duration': 1.301}, {'end': 567.857, 'text': 'It is here that the Python runtime itself becomes the execution runtime for all of the models.', 'start': 563.415, 'duration': 4.442}, {'end': 570.723, 'text': 'It is very similar to execution with numpy.', 'start': 568.562, 'duration': 2.161}, {'end': 573.443, 'text': "So if you're familiar with numpy then it's a cakewalk guys.", 'start': 570.783, 'duration': 2.66}, {'end': 574.624, 'text': 'So on the whole.', 'start': 573.864, 'duration': 0.76}, {'end': 575.984, 'text': 'here is a quick note.', 'start': 574.624, 'duration': 1.36}, {'end': 584.246, 'text': "symbolic tensors don't have a value in the Python code as of yet, but eager tensors will have a value in the Python code and with eager execution.", 'start': 575.984, 'duration': 8.262}], 'summary': 'Keras has two types of execution: deferred (symbolic) and eager (imperative), with eager execution resembling numpy.', 'duration': 41.179, 'max_score': 543.067, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY543067.jpg'}, {'end': 815.916, 'src': 'embed', 'start': 787.505, 'weight': 2, 'content': [{'end': 792.409, 'text': "So what's the data? Well, it's basically 12 columns of data and it's as follows here.", 'start': 787.505, 'duration': 4.904}, {'end': 794.27, 'text': "We'll be talking about the country that the virus.", 'start': 792.449, 'duration': 1.821}, {'end': 796.291, 'text': 'from next up is description.', 'start': 794.27, 'duration': 2.021}, {'end': 801.074, 'text': 'a few sentences from the sommelier Descripting the wines taste, smell, look and feel.', 'start': 796.291, 'duration': 4.783}, {'end': 803.736, 'text': 'a sommelier as a person who is a professional wine taster.', 'start': 801.074, 'duration': 2.662}, {'end': 809.18, 'text': 'guys, next up is designation the vineyard within the winery where the grapes at the wine has been made from.', 'start': 803.736, 'duration': 5.444}, {'end': 815.916, 'text': 'Next up is points the number of points that the wine enthusiasts rated the wine on a scale of 1 to 10..', 'start': 810.114, 'duration': 5.802}], 'summary': 'The data consists of 12 columns, including country, description, designation, and points rated on a scale of 1 to 10.', 'duration': 28.411, 'max_score': 787.505, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY787505.jpg'}], 'start': 543.067, 'title': 'Keras execution types and implementing neural network', 'summary': 'Explains deferred and eager execution in keras, where deferred execution involves building computation graph in python, and eager execution uses python runtime to directly execute models. it also details steps to implement a neural network in keras, including preparing inputs, defining the model, specifying optimizer and loss function, training the network, and testing using a wine classifier use case.', 'chapters': [{'end': 584.246, 'start': 543.067, 'title': 'Keras execution types', 'summary': 'Explains the differences between deferred and eager execution in keras, with deferred execution involving building a computation graph in python, and eager execution utilizing the python runtime to directly execute models, similar to numpy.', 'duration': 41.179, 'highlights': ['Eager execution involves using Python runtime as the execution runtime for all models, similar to execution with numpy, making it easier for those familiar with numpy.', 'Deferred execution involves building a computation graph in Python first, followed by its execution.', "Symbolic tensors in deferred execution don't have a value in the Python code yet, while eager tensors do have a value in the Python code."]}, {'end': 905.112, 'start': 584.286, 'title': 'Implementing neural network with keras', 'summary': 'Explains the steps to implement a neural network using keras, including preparing inputs, defining the model, specifying the optimizer and loss function, training the network, and testing the model using a wine classifier use case.', 'duration': 320.826, 'highlights': ['The chapter explains the steps to implement a neural network using Keras, including preparing inputs, defining the model, specifying the optimizer and loss function, training the network, and testing the model using a wine classifier use case.', 'The neural network implementation involves preparing inputs such as images, videos, text, or audio, specifying the optimizer to simplify the learning process, and defining the loss function to reduce losses in each training pass.', 'The use case involves building a wide and deep network using Keras and TensorFlow to predict the price of a bottle of wine based on its description and variety, suitable for wide and deep learning networks.', "The wine data set used for the use case includes 12 columns of data, such as country, description, designation, points, price, province, region, taster's name, title, variety, and winery, offering opportunities for sentiment analysis and text-related predictive models."]}], 'duration': 362.045, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY543067.jpg', 'highlights': ['Eager execution uses Python runtime for all models, similar to numpy execution.', 'Deferred execution involves building a computation graph in Python first.', 'The wine data set used for the use case includes 12 columns of data.']}, {'end': 1241.387, 'segs': [{'end': 931.564, 'src': 'embed', 'start': 905.613, 'weight': 0, 'content': [{'end': 912.078, 'text': "So, basically, we need to check out some of the prerequisites before jumping into the code, since you're working with python, will require pandas,", 'start': 905.613, 'duration': 6.465}, {'end': 914.92, 'text': 'will require numpy, Skykit, learn and Jupiter notebook.', 'start': 912.078, 'duration': 2.842}, {'end': 917.681, 'text': 'So yes Keras works on top of TensorFlow.', 'start': 915.36, 'duration': 2.321}, {'end': 921.001, 'text': 'So we will require both Keras and TensorFlow to be installed on the machine.', 'start': 917.721, 'duration': 3.28}, {'end': 922.882, 'text': "So now that that's done moving on.", 'start': 921.462, 'duration': 1.42}, {'end': 924.342, 'text': "Let's look at a small piece of code.", 'start': 922.922, 'duration': 1.42}, {'end': 927.543, 'text': 'Here are all the inputs that will require to build the model.', 'start': 924.882, 'duration': 2.661}, {'end': 931.564, 'text': 'And lastly we test the presence of TensorFlow by printing the installed version.', 'start': 927.883, 'duration': 3.681}], 'summary': 'Prerequisites for python code: pandas, numpy, scikit-learn, and jupyter notebook. keras works on top of tensorflow. both keras and tensorflow need to be installed. the code includes model inputs and tests tensorflow version.', 'duration': 25.951, 'max_score': 905.613, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY905613.jpg'}, {'end': 971.716, 'src': 'embed', 'start': 943.767, 'weight': 4, 'content': [{'end': 948.649, 'text': "I'll quickly open up Google collaboratory, which is basically a Jupiter notebook hosted on their Google Cloud.", 'start': 943.767, 'duration': 4.882}, {'end': 954.131, 'text': "You can actually do this on your local machine as well by installing all of the frameworks that I've previously mentioned.", 'start': 949.009, 'duration': 5.122}, {'end': 957.513, 'text': "So let me go ahead and open collaboratory and let's begin guys.", 'start': 954.652, 'duration': 2.861}, {'end': 961.775, 'text': 'So guys will be executing each of these blocks and will be going on from there.', 'start': 958.173, 'duration': 3.602}, {'end': 963.415, 'text': 'So let us check out the first block.', 'start': 962.075, 'duration': 1.34}, {'end': 966.296, 'text': 'So here we import all of the modules that we require.', 'start': 963.715, 'duration': 2.581}, {'end': 967.337, 'text': 'So guys, let me run it.', 'start': 966.377, 'duration': 0.96}, {'end': 968.554, 'text': "and that's done.", 'start': 967.933, 'duration': 0.621}, {'end': 971.716, 'text': 'So next we need to install the latest version of tensorflow.', 'start': 968.874, 'duration': 2.842}], 'summary': 'Demonstration of opening google collaboratory and running code blocks to import modules and install tensorflow.', 'duration': 27.949, 'max_score': 943.767, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY943767.jpg'}, {'end': 1005.229, 'src': 'embed', 'start': 981.742, 'weight': 3, 'content': [{'end': 989.564, 'text': "we need to import the models that we'll use to build the model and after that we'll actually run the code to check the version output of the TensorFlow that we just installed.", 'start': 981.742, 'duration': 7.822}, {'end': 995.686, 'text': "and the output we're supposed to be expecting is version 1.7, because 1.7 is the TensorFlow version that we installed.", 'start': 989.564, 'duration': 6.122}, {'end': 999.627, 'text': 'as you can check out the output, you have TensorFlow version 1.7, so beautiful.', 'start': 995.686, 'duration': 3.941}, {'end': 1003.849, 'text': 'So moving on we need to download the data which is from a CSV file hosted on the cloud.', 'start': 999.907, 'duration': 3.942}, {'end': 1005.229, 'text': "So let's go ahead and do that.", 'start': 1004.169, 'duration': 1.06}], 'summary': 'Import models, check tensorflow version 1.7, and download data from csv file.', 'duration': 23.487, 'max_score': 981.742, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY981742.jpg'}, {'end': 1186.117, 'src': 'embed', 'start': 1163.074, 'weight': 2, 'content': [{'end': 1171.165, 'text': 'We did a bit of pre-processing to keep only the top 40 varieties well around 65% of the original data set or 96 K total examples.', 'start': 1163.074, 'duration': 8.091}, {'end': 1178.791, 'text': "Well, we use a keras utility to convert each of these varieties to integer representation and then we'll create 40 element wide,", 'start': 1171.665, 'duration': 7.126}, {'end': 1181.733, 'text': 'one hot vectors for each input to indicate the variety.', 'start': 1178.791, 'duration': 2.942}, {'end': 1183.695, 'text': 'So let me go ahead and run it guys.', 'start': 1182.173, 'duration': 1.522}, {'end': 1186.117, 'text': "So now that that's run guys at this stage.", 'start': 1184.175, 'duration': 1.942}], 'summary': 'Pre-processed top 40 varieties to 65% of data, 96k examples. used keras to convert to integer representation and created one hot vectors for each input.', 'duration': 23.043, 'max_score': 1163.074, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY1163074.jpg'}, {'end': 1234.942, 'src': 'embed', 'start': 1207.497, 'weight': 1, 'content': [{'end': 1210.16, 'text': 'We can Define our wide model in just a few lines of code.', 'start': 1207.497, 'duration': 2.663}, {'end': 1217.147, 'text': 'as you see well, first we need to Define our input layer as a 12k element vector well for each word in our vocabulary,', 'start': 1210.16, 'duration': 6.987}, {'end': 1220.911, 'text': "and then we'll connect this to our dense output layer to generate the price prediction.", 'start': 1217.147, 'duration': 3.764}, {'end': 1222.132, 'text': 'So let me go ahead and run this.', 'start': 1220.971, 'duration': 1.161}, {'end': 1229.117, 'text': "Well now that that's done will compile the model so that it is ready to use if we were using the wide model all on its own.", 'start': 1222.652, 'duration': 6.465}, {'end': 1234.942, 'text': "This is when we'd actually start training it with the fit function and evaluate later with the evaluate function.", 'start': 1229.377, 'duration': 5.565}], 'summary': 'Define wide model with 12k element vector for price prediction.', 'duration': 27.445, 'max_score': 1207.497, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY1207497.jpg'}], 'start': 905.613, 'title': 'Setting up tensorflow and keras for machine learning and building wide models for wine price prediction', 'summary': 'Discusses the prerequisites for setting up tensorflow and keras for machine learning, including the required libraries and frameworks, and demonstrates the installation process and testing of tensorflow, ultimately confirming the successful installation of version 1.7. additionally, it details the process of downloading, preprocessing, and building a wide model for predicting wine prices, involving data conversion to a pandas dataframe, shuffling data, pre-processing to limit the number of varieties, splitting data into training and testing sets, and creating a wide model using keras functional api with 12k element vector input.', 'chapters': [{'end': 999.627, 'start': 905.613, 'title': 'Setting up tensorflow and keras for machine learning', 'summary': 'Discusses the prerequisites for setting up tensorflow and keras for machine learning, including the required libraries and frameworks, and demonstrates the installation process and testing of tensorflow, ultimately confirming the successful installation of version 1.7.', 'duration': 94.014, 'highlights': ['The chapter emphasizes the prerequisites for setting up TensorFlow and Keras, including the required libraries and frameworks such as pandas, numpy, scikit-learn, and Jupyter notebook.', 'It demonstrates the installation process of TensorFlow and Keras, with a specific focus on confirming the successful installation of TensorFlow version 1.7.', 'The chapter showcases the use of Google Colaboratory, a Jupiter notebook hosted on Google Cloud, as a platform for implementing the code and executing the necessary blocks for setting up TensorFlow and Keras.']}, {'end': 1241.387, 'start': 999.907, 'title': 'Building wide models for wine price prediction', 'summary': 'Details the process of downloading, preprocessing, and building a wide model for predicting wine prices, involving data conversion to a pandas dataframe, shuffling data, pre-processing to limit the number of varieties, splitting data into training and testing sets, and creating a wide model using keras functional api with 12k element vector input.', 'duration': 241.48, 'highlights': ['Using a Keras utility, the data set was pre-processed to limit the number of wine varieties to the top 40, resulting in around 65% of the original data set or 96K total examples.', 'The process involved creating a wide model using Keras functional API with an input layer as a 12k element vector connected to a dense output layer for generating price prediction.', 'The transcript details the process of downloading, preprocessing, and building a wide model for predicting wine prices, involving data conversion to a pandas dataframe, shuffling data, and splitting data into training and testing sets.']}], 'duration': 335.774, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY905613.jpg', 'highlights': ['The chapter emphasizes the prerequisites for setting up TensorFlow and Keras, including required libraries and frameworks.', 'The process involved creating a wide model using Keras functional API with an input layer as a 12k element vector connected to a dense output layer for generating price prediction.', 'Using a Keras utility, the data set was pre-processed to limit the number of wine varieties to the top 40, resulting in around 65% of the original data set or 96K total examples.', 'It demonstrates the installation process of TensorFlow and Keras, with a specific focus on confirming the successful installation of TensorFlow version 1.7.', 'The chapter showcases the use of Google Colaboratory, a Jupiter notebook hosted on Google Cloud, as a platform for implementing the code and executing the necessary blocks for setting up TensorFlow and Keras.']}, {'end': 1635.574, 'segs': [{'end': 1270.812, 'src': 'embed', 'start': 1241.827, 'weight': 4, 'content': [{'end': 1243.088, 'text': 'So let me go ahead and execute this.', 'start': 1241.827, 'duration': 1.261}, {'end': 1244.349, 'text': 'So we define our wide model.', 'start': 1243.108, 'duration': 1.241}, {'end': 1247.712, 'text': 'And yep, our wide model is done.', 'start': 1246.09, 'duration': 1.622}, {'end': 1250.594, 'text': "Let's go ahead and print out a summary from the wide model.", 'start': 1248.092, 'duration': 2.502}, {'end': 1257.425, 'text': 'Well now that we have a summary we can realize the total number of trainable parameters and non-trainable parameters.', 'start': 1252.262, 'duration': 5.163}, {'end': 1260.586, 'text': 'Well in our case the non-trainable parameters are zero guys.', 'start': 1257.745, 'duration': 2.841}, {'end': 1264.849, 'text': "So guys that's the end to the construction of the white model and it's time to build our deep model.", 'start': 1260.947, 'duration': 3.902}, {'end': 1270.812, 'text': "So let's go ahead and check that well to create a deep representation of the wines description will represent it as an embedding.", 'start': 1264.869, 'duration': 5.943}], 'summary': 'Constructed wide model with 0 non-trainable parameters, now building deep model.', 'duration': 28.985, 'max_score': 1241.827, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY1241827.jpg'}, {'end': 1375.478, 'src': 'embed', 'start': 1347.528, 'weight': 3, 'content': [{'end': 1352.472, 'text': "then we'll feed it into the embedding layer, and here I'm using an embedding layer with eight dimensions.", 'start': 1347.528, 'duration': 4.944}, {'end': 1358.216, 'text': 'Well, you can experiment this with tweaking the dimensionality of your embedding layer as per your choice,', 'start': 1352.812, 'duration': 5.404}, {'end': 1362.099, 'text': 'and the output of the embedding layer will be a three-dimensional vectors with the following shape', 'start': 1358.216, 'duration': 3.883}, {'end': 1365.341, 'text': "Well, it'll have a bath size a sequence length.", 'start': 1362.819, 'duration': 2.522}, {'end': 1369.854, 'text': "Well in our case the sequence length is 170 It'll have an embedding dimension.", 'start': 1365.481, 'duration': 4.373}, {'end': 1375.478, 'text': 'It is 8 in our example and in order to connect our embedding layer to the dense fully connected output layer.', 'start': 1370.014, 'duration': 5.464}], 'summary': 'Using an 8-dimensional embedding layer with a sequence length of 170 for connecting to the output layer.', 'duration': 27.95, 'max_score': 1347.528, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY1347528.jpg'}, {'end': 1446.611, 'src': 'embed', 'start': 1418.917, 'weight': 0, 'content': [{'end': 1425.642, 'text': 'Well, obviously since each model is predicting the same thing, which is the price the output or the labels from each one will be the same.', 'start': 1418.917, 'duration': 6.725}, {'end': 1429.964, 'text': 'Also guys do know that since the output of our model is a numeric value.', 'start': 1426.202, 'duration': 3.762}, {'end': 1434.006, 'text': "We will not need to do any pre-processing and it's already in the right format as well.", 'start': 1430.064, 'duration': 3.942}, {'end': 1439.368, 'text': "How cool is that? Well that that's done guys.", 'start': 1434.106, 'duration': 5.262}, {'end': 1441.289, 'text': "It's time for the training and the evaluation.", 'start': 1439.428, 'duration': 1.861}, {'end': 1446.611, 'text': 'Well, you can experiment with the number of training epochs and the batch size that works best for your data set.', 'start': 1441.689, 'duration': 4.922}], 'summary': 'Models predict price, no pre-processing needed. experiment with training epochs and batch size.', 'duration': 27.694, 'max_score': 1418.917, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY1418917.jpg'}, {'end': 1538.733, 'src': 'embed', 'start': 1509.458, 'weight': 1, 'content': [{'end': 1510.699, 'text': "So let's go ahead and do just that.", 'start': 1509.458, 'duration': 1.241}, {'end': 1514.443, 'text': "Well now that that's done.", 'start': 1513.343, 'duration': 1.1}, {'end': 1519.185, 'text': "We'll have to compare the predictions to the actual values for the first 15 wines from our test data set.", 'start': 1514.483, 'duration': 4.702}, {'end': 1524.047, 'text': 'So guys as you can see we have a set of predictions from the description and the predicted value is about $24.', 'start': 1519.585, 'duration': 4.462}, {'end': 1527.468, 'text': 'Well, the actual value is $22 next up.', 'start': 1524.047, 'duration': 3.421}, {'end': 1530.529, 'text': 'We have $34 as a predicted one while the average is 70.', 'start': 1527.508, 'duration': 3.021}, {'end': 1533.27, 'text': "Well, this is not a really good case, but okay, that's tolerable.", 'start': 1530.529, 'duration': 2.741}, {'end': 1538.733, 'text': 'and next up we predicted 11.9 when the actual values tell Wow, that is actually really close.', 'start': 1533.73, 'duration': 5.003}], 'summary': 'Comparing predictions to actual values for 15 wines, with some discrepancies and some close matches.', 'duration': 29.275, 'max_score': 1509.458, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY1509458.jpg'}], 'start': 1241.827, 'title': 'Building wide and deep models', 'summary': 'Covers the construction of wide and deep models, including the creation of word embeddings, model compilation, training, evaluation, and performance analysis, achieving an average prediction difference of $10 for every wine bottle and an accuracy improvement from 0.02 to 0.0994 over 10 epochs.', 'chapters': [{'end': 1635.574, 'start': 1241.827, 'title': 'Building wide and deep models', 'summary': 'Covers the construction of wide and deep models, including the creation of word embeddings, model compilation, training, evaluation, and performance analysis, achieving an average prediction difference of $10 for every wine bottle and an accuracy improvement from 0.02 to 0.0994 over 10 epochs.', 'duration': 393.747, 'highlights': ['The training process involved 10 epochs, with a reduction in loss from 1100 to 130 and an accuracy improvement from 0.02 to 0.0994, representing a significant breakthrough for just 10 passes.', "The average prediction difference between the actual price and the model's predicted price is about $10 for every wine bottle, indicating a strong performance of the model in predicting wine prices.", 'The creation of wide and deep models involved defining input shapes, embedding layers, flattening, model compiling with mean squared error loss function and Adam optimizer, and combining the outputs from each model into a fully connected dense layer.', "The process of converting text descriptions to an embedding layer involved the use of Keras' text-to-sequence method and padding sequences to ensure they are all the same length, with a max length of 170.", "The evaluation of the trained model showed a close relationship between the wines' descriptions and prices, with an average prediction difference of $10 for every wine bottle, demonstrating the model's ability to predict wine prices effectively."]}], 'duration': 393.747, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/XNKeayZW4dY/pics/XNKeayZW4dY1241827.jpg', 'highlights': ['The training process involved 10 epochs, with a reduction in loss from 1100 to 130 and an accuracy improvement from 0.02 to 0.0994, representing a significant breakthrough for just 10 passes.', "The average prediction difference between the actual price and the model's predicted price is about $10 for every wine bottle, indicating a strong performance of the model in predicting wine prices.", "The evaluation of the trained model showed a close relationship between the wines' descriptions and prices, with an average prediction difference of $10 for every wine bottle, demonstrating the model's ability to predict wine prices effectively.", 'The creation of wide and deep models involved defining input shapes, embedding layers, flattening, model compiling with mean squared error loss function and Adam optimizer, and combining the outputs from each model into a fully connected dense layer.', "The process of converting text descriptions to an embedding layer involved the use of Keras' text-to-sequence method and padding sequences to ensure they are all the same length, with a max length of 170."]}], 'highlights': ['Keras had over 4800 contributors during its launch and now has 250,000 active developers, with a 2x growth annually, showcasing its significant traction and adoption among startups.', 'The training process involved 10 epochs, with a reduction in loss from 1100 to 130 and an accuracy improvement from 0.02 to 0.0994, representing a significant breakthrough for just 10 passes.', "The average prediction difference between the actual price and the model's predicted price is about $10 for every wine bottle, indicating a strong performance of the model in predicting wine prices.", 'Keras is widely used by popular firms like Netflix, Uber, and Expedia due to its user experience focus, multi-backend support, and strong community presence.', 'The process involved creating a wide model using Keras functional API with an input layer as a 12k element vector connected to a dense output layer for generating price prediction.']}