title
Lesson 3 - Deep Learning for Coders (2020)
description
NB: We recommend watching these videos through https://course.fast.ai rather than directly on YouTube, to get access to the searchable transcript, interactive notebooks, setup guides, questionnaires, and so forth.
Today we finish creating and deploying our own app. We discuss data augmentation, and look at the most important types of augmentation used in modern computer vision models. We also see how fastai helps you process your images to get them ready for your model.
We look at building GUIs, both for interactive apps inside notebooks, and also for standalone web applications. We discuss how to deploy web applications that incorporate deep learning models. In doing so, we look at the pros and cons of different approaches, such as server-based and edge-device deployment.
Our final area for productionization is looking at what can go wrong, and how to avoid problems, and keep your data product working effectively in practice.
Then we skip over to chapter 4 of the book, and learn about the underlying math and code of Stochastic Gradient Descent, which lies at the heart of neural network training.
0:00 - Recap of Lesson 2 + What's next
1:08 - Resizing Images with DataBlock
8:46 - Data Augmentation and item_tfms vs batch_tfms
12:28 - Training your model, and using it to clean your data
18:07 - Turning your model into an online application
36:12 - Deploying to a mobile phone
38:13 - How to avoid disaster
50:59 - Unforeseen consequences and feedback loops
57:20 - End of Chapter 2 Recap + Blogging
1:04:09 - Starting MNIST from scratch
1:06:58 - untar_data and path explained
1:10:57 - Exploring at the MNIST data
1:12:05 - NumPy Array vs PyTorch Tensor
1:16:00 - Creating a simple baseline model
1:28:38 - Working with arrays and tensors
1:30:50 - Computing metrics with Broadcasting
1:39:46 - Stochastic Gradient Descent (SGD)
1:54:40 - End-to-end Gradient Descent example
2:01:56 - MNIST loss function
2:04:40 - Lesson 3 review
detail
{'title': 'Lesson 3 - Deep Learning for Coders (2020)', 'heatmap': [{'end': 1904.034, 'start': 1820.3, 'weight': 0.765}, {'end': 5086.967, 'start': 4995.214, 'weight': 0.732}, {'end': 6684.917, 'start': 6593.339, 'weight': 0.718}, {'end': 7206.644, 'start': 7044.289, 'weight': 0.798}], 'summary': 'Covers model deployment, neural network training, image resizing, data augmentation, fastai2 and gui implementation, ethical ml deployment, model bias, model deployment and blogging, engaging with ml course material, recognizing handwritten digits with mnist sample, python programming tricks, understanding tensors and rank, numpy, pytorch, model evaluation, broadcasting, model accuracy, and gradient descent.', 'chapters': [{'end': 66.416, 'segs': [{'end': 31.822, 'src': 'embed', 'start': 0.409, 'weight': 0, 'content': [{'end': 6.016, 'text': 'So hello and welcome to lesson three of practical deep learning for coders.', 'start': 0.409, 'duration': 5.607}, {'end': 14.425, 'text': 'We were looking at getting our model into production last week.', 'start': 7.898, 'duration': 6.527}, {'end': 22.353, 'text': "And so we're going to finish off that today and then we're going to start to look behind the scenes at what actually goes on when we train a neural network.", 'start': 15.206, 'duration': 7.147}, {'end': 31.822, 'text': "We're going to look at kind of the math of what's going on and we're going to learn about SGD and some important stuff like that.", 'start': 22.373, 'duration': 9.449}], 'summary': 'Lesson three focuses on getting the model into production and understanding the math behind training a neural network.', 'duration': 31.413, 'max_score': 0.409, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4409.jpg'}, {'end': 77.446, 'src': 'embed', 'start': 44.664, 'weight': 1, 'content': [{'end': 49.225, 'text': "So we're doing lesson four and then lesson three, chapter four and then chapter three I should say.", 'start': 44.664, 'duration': 4.561}, {'end': 53.106, 'text': "You can choose it whichever way you're interested in.", 'start': 50.365, 'duration': 2.741}, {'end': 58.787, 'text': 'Chapter four is the more technical chapter about the foundations of how deep learning really works.', 'start': 53.806, 'duration': 4.981}, {'end': 62.151, 'text': 'Whereas chapter 3 is all about ethics.', 'start': 59.247, 'duration': 2.904}, {'end': 66.416, 'text': "And so with the lessons we'll do that next week.", 'start': 63.753, 'duration': 2.663}, {'end': 77.446, 'text': "So we're looking at 0.2 production notebook and we're going to look at the fastbook version.", 'start': 69.123, 'duration': 8.323}], 'summary': 'Lesson four covers technical foundations, lesson three focuses on ethics.', 'duration': 32.782, 'max_score': 44.664, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC444664.jpg'}], 'start': 0.409, 'title': 'Model deployment and neural network training', 'summary': 'Covers model deployment, the math behind training a neural network, and provides options for further exploration of technical foundations in chapter four or ethics in chapter three.', 'chapters': [{'end': 66.416, 'start': 0.409, 'title': 'Lesson three: model deployment and neural network training', 'summary': 'Covers model deployment, the math behind training a neural network, and the option to choose between studying the technical foundations of deep learning in chapter four or exploring the ethics in chapter three.', 'duration': 66.007, 'highlights': ['The chapter covers model deployment, the math behind training a neural network, and the option to choose between studying the technical foundations of deep learning in chapter four or exploring the ethics in chapter three. It emphasizes the key topics of model deployment, neural network training, and the choice between technical foundations and ethics in deep learning.', 'Chapter four is the more technical chapter about the foundations of how deep learning really works. It highlights that chapter four is focused on the technical foundations of deep learning.', 'Chapter 3 is all about ethics. It mentions that chapter three focuses on the ethical aspects of deep learning.']}], 'duration': 66.007, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4409.jpg', 'highlights': ['The chapter covers model deployment and the math behind training a neural network.', 'Chapter four is focused on the technical foundations of deep learning.', 'Chapter three focuses on the ethical aspects of deep learning.']}, {'end': 661.983, 'segs': [{'end': 148.651, 'src': 'embed', 'start': 122.877, 'weight': 5, 'content': [{'end': 133.559, 'text': 'When you say resize for an item transform, it means each item, so an item in this case is one image, is going to be resized to 128 by 128.', 'start': 122.877, 'duration': 10.682}, {'end': 134.963, 'text': 'by squishing it or stretching it.', 'start': 133.559, 'duration': 1.404}, {'end': 140.135, 'text': 'And so we had a look at, you can always say show batch to see a few examples.', 'start': 135.644, 'duration': 4.491}, {'end': 142.42, 'text': 'And this is what they looked like.', 'start': 140.956, 'duration': 1.464}, {'end': 148.651, 'text': "Squishing and stretching isn't the only way that we can resize.", 'start': 145.47, 'duration': 3.181}], 'summary': 'Images resized to 128x128, with squishing or stretching, shown as examples.', 'duration': 25.774, 'max_score': 122.877, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4122877.jpg'}, {'end': 220.051, 'src': 'embed', 'start': 192.509, 'weight': 3, 'content': [{'end': 203.154, 'text': "and so let's create another data block object and this time with different item transform where we resize using the squish method.", 'start': 192.509, 'duration': 10.645}, {'end': 205.343, 'text': 'We have a question.', 'start': 204.542, 'duration': 0.801}, {'end': 213.816, 'text': "What are the advantages of having square images versus rectangular ones? That's a great question.", 'start': 205.824, 'duration': 7.992}, {'end': 220.051, 'text': "really it's simplicity.", 'start': 219.051, 'duration': 1}], 'summary': 'Creating a data block object with a different item transform for image resizing. discussing the advantages of square images over rectangular ones for simplicity.', 'duration': 27.542, 'max_score': 192.509, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4192509.jpg'}, {'end': 419.091, 'src': 'embed', 'start': 393.972, 'weight': 2, 'content': [{'end': 400.497, 'text': "But on the downside, your neural net's going to have to learn to kind of like recognize when something's been squished or stretched.", 'start': 393.972, 'duration': 6.525}, {'end': 402.618, 'text': "And in some cases it might, it wouldn't even know.", 'start': 400.557, 'duration': 2.061}, {'end': 407.962, 'text': "So if there's two objects you're trying to recognize, one of which tends to be thin and one of which tends to be thick,", 'start': 403.159, 'duration': 4.803}, {'end': 411.544, 'text': "and otherwise they're the same, they could actually be impossible to distinguish.", 'start': 407.962, 'duration': 3.582}, {'end': 419.091, 'text': 'And then the default cropping approach actually removes some information.', 'start': 413.546, 'duration': 5.545}], 'summary': 'Neural net may struggle to recognize squished/stretched objects, leading to impossible distinctions and lost information.', 'duration': 25.119, 'max_score': 393.972, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4393972.jpg'}, {'end': 467.496, 'src': 'embed', 'start': 440.563, 'weight': 0, 'content': [{'end': 446.846, 'text': "So there's something else that you can do, a different approach, which is instead of to say resize, you can say random resize crop.", 'start': 440.563, 'duration': 6.283}, {'end': 448.807, 'text': 'And actually this is the most common approach.', 'start': 447.126, 'duration': 1.681}, {'end': 460.833, 'text': 'And what random resize crop does is each time it actually grabs a different part of the image and kind of zooms into it, right.', 'start': 449.167, 'duration': 11.666}, {'end': 467.496, 'text': "So this is all the same image and we're just grabbing a batch of four different versions of it.", 'start': 461.213, 'duration': 6.283}], 'summary': 'Random resize crop is a common approach, grabbing different parts of the image and zooming into them, creating four different versions.', 'duration': 26.933, 'max_score': 440.563, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4440563.jpg'}, {'end': 573.048, 'src': 'embed', 'start': 541.818, 'weight': 1, 'content': [{'end': 544.1, 'text': 'And this is one type of data augmentation.', 'start': 541.818, 'duration': 2.282}, {'end': 548.444, 'text': "It's probably the most common, but there are others.", 'start': 544.14, 'duration': 4.304}, {'end': 557.596, 'text': 'And one of the best ways to do data augmentation is to use this org transforms function.', 'start': 549.906, 'duration': 7.69}, {'end': 564.845, 'text': 'And what org transforms does is it actually returns a list of different augmentations.', 'start': 557.936, 'duration': 6.909}, {'end': 573.048, 'text': 'And so there are augmentations which change contrast, which change brightness, which warp the perspective.', 'start': 565.965, 'duration': 7.083}], 'summary': 'Data augmentation using org transforms function offers various augmentations like contrast, brightness, and perspective warp.', 'duration': 31.23, 'max_score': 541.818, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4541818.jpg'}], 'start': 69.123, 'title': 'Image resizing and data augmentation', 'summary': 'Covers the importance of item transforms in data preprocessing, including resizing images to a uniform size using the squish method, advantages of square images over rectangular ones, different methods of image resizing, trade-offs, and data augmentation using org transforms with gpu acceleration.', 'chapters': [{'end': 259.869, 'start': 69.123, 'title': 'Data transformation and resizing', 'summary': 'Covers the importance of item transforms in data preprocessing, including resizing images to a uniform size using the squish method and the advantages of having square images over rectangular ones in simplifying the preprocessing process.', 'duration': 190.746, 'highlights': ['The chapter covers the importance of item transforms in data preprocessing. ', 'Resizing images to a uniform size using the squish method is discussed. ', 'The advantages of having square images over rectangular ones in simplifying the preprocessing process are explained. ']}, {'end': 661.983, 'start': 259.869, 'title': 'Image resizing and data augmentation', 'summary': 'Discusses different methods of image resizing, including squishing, stretching, padding, and random resize crop, highlighting their trade-offs and introduces data augmentation using org transforms, which includes various batch transformations for image manipulation and gpu acceleration.', 'duration': 402.114, 'highlights': ['The random resize crop approach is the most common method of image resizing and data augmentation, grabbing different parts of the image each time and zooming into them, reducing overfitting and increasing diversity of the training data.', "The chapter emphasizes the trade-offs of different image resizing methods, such as squish, stretch, and pad, discussing their efficiency, waste of computation, and potential impact on the neural net's ability to recognize objects, providing practical insights into their application and limitations.", 'Org transforms function provides a variety of batch transformations for data augmentation, including contrast and brightness adjustments, perspective warping, and rotation, enhancing the diversity of training data and enabling GPU-accelerated transformations for efficient processing.']}], 'duration': 592.86, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC469123.jpg', 'highlights': ['The random resize crop approach is the most common method of image resizing and data augmentation, grabbing different parts of the image each time and zooming into them, reducing overfitting and increasing diversity of the training data.', 'Org transforms function provides a variety of batch transformations for data augmentation, including contrast and brightness adjustments, perspective warping, and rotation, enhancing the diversity of training data and enabling GPU-accelerated transformations for efficient processing.', "The chapter emphasizes the trade-offs of different image resizing methods, such as squish, stretch, and pad, discussing their efficiency, waste of computation, and potential impact on the neural net's ability to recognize objects, providing practical insights into their application and limitations.", 'Resizing images to a uniform size using the squish method is discussed.', 'The advantages of having square images over rectangular ones in simplifying the preprocessing process are explained.', 'The chapter covers the importance of item transforms in data preprocessing.']}, {'end': 2361.43, 'segs': [{'end': 700.019, 'src': 'embed', 'start': 661.983, 'weight': 0, 'content': [{'end': 669.308, 'text': 'I can rotate, zoom, change the lighting, warp, the perspective and so forth.', 'start': 661.983, 'duration': 7.325}, {'end': 676.814, 'text': 'How can we add different augmentations for train and validation sets?', 'start': 671.09, 'duration': 5.724}, {'end': 688.237, 'text': 'So the cool thing is that automatically FastAI will avoid doing data augmentation on the validation set.', 'start': 677.394, 'duration': 10.843}, {'end': 700.019, 'text': 'So all of these org transforms will only be applied to the training set, with the exception of random resize crop.', 'start': 689.337, 'duration': 10.682}], 'summary': 'Fastai automatically avoids data augmentation on validation set.', 'duration': 38.036, 'max_score': 661.983, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4661983.jpg'}, {'end': 1125.641, 'src': 'embed', 'start': 1098.919, 'weight': 1, 'content': [{'end': 1103.662, 'text': "you can then load that save file and you'll get back a learner that you can call predict on.", 'start': 1098.919, 'duration': 4.743}, {'end': 1118.631, 'text': 'So predict Perhaps the most interesting part of predict is the third thing that it returns, which is a tensor, in this case containing three numbers.', 'start': 1104.442, 'duration': 14.189}, {'end': 1125.641, 'text': "The three numbers, there's three of them because we have three classes, teddy bear, grizzly bear, and black bear.", 'start': 1120.013, 'duration': 5.628}], 'summary': 'The predict function returns a tensor with three numbers for three classes: teddy bear, grizzly bear, and black bear.', 'duration': 26.722, 'max_score': 1098.919, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC41098919.jpg'}, {'end': 1327.289, 'src': 'embed', 'start': 1292.212, 'weight': 2, 'content': [{'end': 1293.914, 'text': "Most data scientists aren't.", 'start': 1292.212, 'duration': 1.702}, {'end': 1300.299, 'text': "but gee, wouldn't it be great if all data scientists could at least like prototype, an application to show off the thing they're working on?", 'start': 1293.914, 'duration': 6.385}, {'end': 1307.842, 'text': "And so we've tried to kind of curate an approach which none of its stuff we've built.", 'start': 1301.259, 'duration': 6.583}, {'end': 1316.445, 'text': "it's really just curated, which shows how you can create a GUI and create a complete application in Jupyter Notebook.", 'start': 1307.842, 'duration': 8.603}, {'end': 1327.289, 'text': 'So the key pieces of technology we use to do this are IPython widgets, which is always called IPy widgets, and voila.', 'start': 1317.585, 'duration': 9.704}], 'summary': 'Data scientists can prototype applications using ipy widgets and voila in jupyter notebook.', 'duration': 35.077, 'max_score': 1292.212, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC41292212.jpg'}, {'end': 1904.034, 'src': 'heatmap', 'start': 1820.3, 'weight': 0.765, 'content': [{'end': 1840.598, 'text': 'And then, when you do that, if you navigate to this notebook but you replace notebooks up here with voila, it actually displays not the notebook but,', 'start': 1820.3, 'duration': 20.298}, {'end': 1843.58, 'text': 'just as I said, the markdown and the widgets.', 'start': 1840.598, 'duration': 2.982}, {'end': 1849.683, 'text': "So here I've got my bear classifier, and I can click upload.", 'start': 1844.361, 'duration': 5.322}, {'end': 1851.691, 'text': "Let's do a grizzly bear this time.", 'start': 1849.703, 'duration': 1.988}, {'end': 1858.288, 'text': 'and this is a slightly different version.', 'start': 1856.887, 'duration': 1.401}, {'end': 1860.309, 'text': "I actually made this so there's no classify button.", 'start': 1858.288, 'duration': 2.021}, {'end': 1867.214, 'text': 'I thought it would be a bit more fancy to make it so when you click upload, it just runs everything, but as you can see there, it all is right.', 'start': 1860.309, 'duration': 6.905}, {'end': 1868.454, 'text': "it's all working.", 'start': 1867.214, 'duration': 1.24}, {'end': 1875.839, 'text': "so this is the world's simplest prototype, but it's it's a proof of concept, right?", 'start': 1868.454, 'duration': 7.385}, {'end': 1885.705, 'text': 'so you can add widgets with drop downs and sliders and charts and you know everything that you can have in a, you know,', 'start': 1875.839, 'duration': 9.866}, {'end': 1887.926, 'text': 'an Angular app or a React app or whatever.', 'start': 1885.705, 'duration': 2.221}, {'end': 1895.569, 'text': "And in fact, there's, there's even stuff which lets you use, for example, the whole Vue.js framework.", 'start': 1888.266, 'duration': 7.303}, {'end': 1904.034, 'text': "If you know that it's a very popular JavaScript framework, the whole Vue.js framework, you can actually use it in widgets and voila.", 'start': 1895.669, 'duration': 8.365}], 'summary': 'Prototype bear classifier with widgets for voila display, showcasing proof of concept and vue.js integration.', 'duration': 83.734, 'max_score': 1820.3, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC41820300.jpg'}, {'end': 2000.494, 'src': 'embed', 'start': 1976.424, 'weight': 3, 'content': [{'end': 1984.907, 'text': 'And so this is, you know, anybody can now use this to take their Voila app and make it a publicly available web application.', 'start': 1976.424, 'duration': 8.483}, {'end': 1987.728, 'text': 'So try it.', 'start': 1984.927, 'duration': 2.801}, {'end': 1994.391, 'text': 'As it mentions here the first time you do this Binder takes about five minutes to build your site,', 'start': 1988.569, 'duration': 5.822}, {'end': 2000.494, 'text': 'because it actually uses something called Docker to deploy the whole fast AI framework and Python and blah, blah, blah.', 'start': 1994.391, 'duration': 6.103}], 'summary': 'Voila app can be made a publicly available web application using binder, which takes about five minutes to build the site.', 'duration': 24.07, 'max_score': 1976.424, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC41976424.jpg'}, {'end': 2090.86, 'src': 'embed', 'start': 2065.385, 'weight': 5, 'content': [{'end': 2070.726, 'text': "So when I pass along that single image I don't have a huge amount of parallel work for a GPU to do.", 'start': 2065.385, 'duration': 5.341}, {'end': 2074.768, 'text': 'This is actually something that a CPU is going to be doing more efficiently.', 'start': 2070.746, 'duration': 4.022}, {'end': 2087.556, 'text': 'So we found that for folks coming through this course, The vast majority of the time they wanted to deploy inference on a CPU, not a GPU,', 'start': 2076.529, 'duration': 11.027}, {'end': 2090.86, 'text': "because they're normally just doing one item at a time.", 'start': 2087.556, 'duration': 3.304}], 'summary': 'Most learners prefer cpu over gpu for inference, as they usually process one item at a time.', 'duration': 25.475, 'max_score': 2065.385, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42065385.jpg'}, {'end': 2233.656, 'src': 'embed', 'start': 2198.583, 'weight': 6, 'content': [{'end': 2199.744, 'text': 'It makes life super easy.', 'start': 2198.583, 'duration': 1.161}, {'end': 2209.935, 'text': "When you try to run a PyTorch app on a phone, you're suddenly now not in an environment where PyTorch will run natively.", 'start': 2201.165, 'duration': 8.77}, {'end': 2214.339, 'text': "And so you'll have to like convert your program into some other form.", 'start': 2210.375, 'duration': 3.964}, {'end': 2220.765, 'text': 'And there are other forms, and the main form that you convert it to is something called ONNX,', 'start': 2215.22, 'duration': 5.545}, {'end': 2233.656, 'text': 'which is specifically designed for kind of super high-speed, high-performance approach that can run on both servers or on mobile phones.', 'start': 2220.765, 'duration': 12.891}], 'summary': 'Converting pytorch apps to onnx allows high-speed, high-performance on servers and mobile phones.', 'duration': 35.073, 'max_score': 2198.583, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42198583.jpg'}], 'start': 661.983, 'title': 'Fastai2 and gui implementation', 'summary': 'Covers data augmentation, custom gui implementation in jupyter notebook, fastai2 deployment, and building interactive guis using voila and binder. it includes features like automatic avoidance of augmentation on the validation set, custom transformations, exporting and loading pickle files, and deployment considerations for cpus, gpus, and mobile phones.', 'chapters': [{'end': 924.408, 'start': 661.983, 'title': 'Data augmentation in fastai', 'summary': 'Discusses data augmentation in fastai, including automatic avoidance of augmentation on the validation set, custom transformations, and the process of data cleaning after model creation using image classifier cleaner.', 'duration': 262.425, 'highlights': ['FastAI automatically avoids doing data augmentation on the validation set, with the exception of random resize crop. FastAI automatically avoids doing data augmentation on the validation set, ensuring that all org transforms are only applied to the training set, except for random resize crop.', 'Behavior of random resize crop differs for the training and validation sets, with the training set randomly picking a subset and zooming into it, and the validation set grabbing the largest center square. The behavior of random resize crop differs for the training and validation sets, with the training set randomly picking a subset and zooming into it, while the validation set grabs the largest center square.', 'Image Classifier Cleaner is a tool for data cleaning after model creation, allowing the selection of images based on confidence and likelihood of being wrong, with options to delete or mark them for review. The Image Classifier Cleaner tool facilitates data cleaning after model creation by listing images, identifying those most likely to be wrong, and providing options to delete, mark for review, or keep them.']}, {'end': 1197.549, 'start': 924.408, 'title': 'Implementing custom gui in jupyter notebook', 'summary': 'Discusses implementing a custom gui inside jupyter notebook using less than a screen of code, fast.ai being built with notebooks, and the process of exporting and loading a pickle file for inference, with predict returning a tensor containing three numbers corresponding to teddy bear, grizzly bear, and black bear classes.', 'duration': 273.141, 'highlights': ["Predict function returns a tensor containing three numbers representing the activations for teddy bear, grizzly bear, and black bear classes. The predict function returns a tensor with activations for teddy bear, grizzly bear, and black bear classes, providing insights into the model's confidence for each class.", 'Fast.ai is built with notebooks, and the source code can be found in the Fast.ai notebooks in the Fast.ai repo, containing examples and tests. Fast.ai is built with notebooks, and its source code is available in the Fast.ai repo, providing access to examples and tests for learning and understanding the implementation.', 'Creating a custom GUI inside Jupyter Notebook using less than a screen of code. The chapter demonstrates the creation of a custom GUI inside Jupyter Notebook using a minimal amount of code, showcasing the flexibility and ease of implementation.']}, {'end': 1702.442, 'start': 1197.549, 'title': 'Fastai2 deployment in jupyter notebook', 'summary': 'Demonstrates how to deploy a complete application in jupyter notebook using fastai2, ipython widgets, and voila, allowing data scientists to prototype interactive applications for classification and prediction.', 'duration': 504.893, 'highlights': ['The chapter demonstrates how to deploy a complete application in Jupyter Notebook using FastAI2, IPython widgets, and Voila, allowing data scientists to prototype interactive applications for classification and prediction. Deployment of complete application in Jupyter Notebook, usage of FastAI2, IPython widgets, and Voila for prototyping interactive applications', 'The line of code to call once when the application starts up and the line to call every time for inference are shown. Demonstration of the lines of code for application startup and inference', 'The widgets have methods and properties, such as the upload button having a data property containing all uploaded images. Explanation of methods and properties of widgets, including the data property of the upload button', 'The use of output and label widgets to display and manipulate text and images is explained. Explanation of the usage of output and label widgets for text and image display', 'The creation of a VBox to organize and display the widgets is demonstrated. Demonstration of the creation and usage of a VBox to organize and display widgets']}, {'end': 2361.43, 'start': 1702.442, 'title': 'Building interactive guis with voila and binder', 'summary': 'Explores building interactive guis using voila and binder, enabling data scientists to create applications from notebooks, deploy them using voila and make them publicly available using binder, while also discussing considerations for deployment to cpus, gpus, and mobile phones.', 'duration': 658.988, 'highlights': ['Voila and Binder enable data scientists to create interactive GUIs from notebooks and make them publicly available Voila and Binder provide a way for data scientists to convert their notebooks into interactive GUIs and deploy them as publicly accessible web applications.', 'Deployment using Binder provides a free and accessible way to make Voila apps publicly available Binder allows for the creation of interactive running applications from Voila apps, providing a free and accessible method for making them publicly available.', 'Considerations for deployment include the efficiency of deploying inference on a CPU, the need for GPU deployment in specific scenarios, and the recommendation to deploy to a server for mobile phone applications Efficient deployment of inference on a CPU is suitable for processing single images, while specific scenarios, such as processing videos or high request rates, may require deployment to a GPU. For mobile phone applications, deploying to a server is recommended to simplify the process.', 'Using ONNX for deployment to mobile phones provides high-speed performance but comes with complexity and maintenance challenges Deploying to mobile phones using ONNX offers high-speed performance but introduces complexity, debugging challenges, and maintenance difficulties.']}], 'duration': 1699.447, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC4661983.jpg', 'highlights': ['FastAI automatically avoids doing data augmentation on the validation set, ensuring that all org transforms are only applied to the training set, except for random resize crop.', "The predict function returns a tensor with activations for teddy bear, grizzly bear, and black bear classes, providing insights into the model's confidence for each class.", 'The chapter demonstrates the creation of a custom GUI inside Jupyter Notebook using a minimal amount of code, showcasing the flexibility and ease of implementation.', 'Deployment of complete application in Jupyter Notebook, usage of FastAI2, IPython widgets, and Voila for prototyping interactive applications.', 'Voila and Binder provide a way for data scientists to convert their notebooks into interactive GUIs and deploy them as publicly accessible web applications.', 'Efficient deployment of inference on a CPU is suitable for processing single images, while specific scenarios, such as processing videos or high request rates, may require deployment to a GPU.', 'Deploying to mobile phones using ONNX offers high-speed performance but introduces complexity, debugging challenges, and maintenance difficulties.']}, {'end': 2961.475, 'segs': [{'end': 2442.198, 'src': 'embed', 'start': 2414.169, 'weight': 6, 'content': [{'end': 2419.933, 'text': "So that's what your healthy skin classifier would learn to detect.", 'start': 2414.169, 'duration': 5.764}, {'end': 2433.817, 'text': 'right And so this is a great example from Deb Raji and you should check out her paper Actionable Auditing for lots of cool insights about model bias.', 'start': 2420.934, 'duration': 12.883}, {'end': 2442.198, 'text': "But I mean here's like a fascinating example of how, if you weren't looking at your data carefully,", 'start': 2434.337, 'duration': 7.861}], 'summary': "Healthy skin classifier learns to detect bias; check out deb raji's paper for insights on model bias.", 'duration': 28.029, 'max_score': 2414.169, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42414169.jpg'}, {'end': 2522.1, 'src': 'embed', 'start': 2497.041, 'weight': 1, 'content': [{'end': 2502.005, 'text': 'really try hard to gather data that reflects the real world.', 'start': 2497.041, 'duration': 4.964}, {'end': 2503.346, 'text': 'So like just you know.', 'start': 2502.165, 'duration': 1.181}, {'end': 2505.587, 'text': 'so, for example, for the healthy skin example,', 'start': 2503.346, 'duration': 2.241}, {'end': 2511.632, 'text': 'you might go and actually talk to a dermatologist and try and find like 10 examples of healthy and unhealthy skin or something.', 'start': 2505.587, 'duration': 6.045}, {'end': 2514.954, 'text': 'And that would be your kind of gold standard test.', 'start': 2512.612, 'duration': 2.342}, {'end': 2522.1, 'text': "There's all kinds of issues you have to think about in deployment.", 'start': 2519.117, 'duration': 2.983}], 'summary': 'Effort to gather real-world data for testing, like consulting 10 dermatologists for healthy and unhealthy skin examples.', 'duration': 25.059, 'max_score': 2497.041, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42497041.jpg'}, {'end': 2650.673, 'src': 'embed', 'start': 2623.021, 'weight': 7, 'content': [{'end': 2634.725, 'text': 'Out of domain data refers to a situation where the data that you are trying to do inference on is in some way different to the kind of data that you trained with.', 'start': 2623.021, 'duration': 11.704}, {'end': 2641.668, 'text': "And this is actually, there's no perfect way to answer this question.", 'start': 2636.445, 'duration': 5.223}, {'end': 2650.112, 'text': "And when we look at ethics, we'll talk about some really helpful ways to minimize how much this happens.", 'start': 2642.208, 'duration': 7.904}, {'end': 2650.673, 'text': 'For example,', 'start': 2650.132, 'duration': 0.541}], 'summary': 'Out-of-domain data poses challenge in inference; ethics guide mitigation.', 'duration': 27.652, 'max_score': 2623.021, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42623021.jpg'}, {'end': 2754.862, 'src': 'embed', 'start': 2710.313, 'weight': 0, 'content': [{'end': 2730.206, 'text': "And that a lot of the proposals around addressing this have kind of been converging to this idea and that you see in papers like Timnit Gebru's data sheets for data sets of just writing down a lot of the details about your data set and how it was gathered and in which situations it's appropriate to use and how it was maintained.", 'start': 2710.313, 'duration': 19.893}, {'end': 2737.852, 'text': "And so there that's not that you've totally eliminated bias, but that you're just very aware of the attributes of your data set,", 'start': 2730.867, 'duration': 6.985}, {'end': 2739.814, 'text': "so that you won't be blindsided by them later.", 'start': 2737.852, 'duration': 1.962}, {'end': 2745.842, 'text': 'And there have been kind of several proposals in that school of thought, which I really like,', 'start': 2740.735, 'duration': 5.107}, {'end': 2752.01, 'text': 'around this idea of just kind of understanding how your data was gathered and what its limitations are.', 'start': 2745.842, 'duration': 6.168}, {'end': 2754.862, 'text': 'Thanks, Rachel.', 'start': 2754.182, 'duration': 0.68}], 'summary': 'Proposals suggest detailing dataset attributes to mitigate bias and limitations.', 'duration': 44.549, 'max_score': 2710.313, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42710313.jpg'}, {'end': 2834.74, 'src': 'embed', 'start': 2807.179, 'weight': 4, 'content': [{'end': 2813.926, 'text': "And so the natural downside is you can't expect the process that the thing is using to do that to be describable for you,", 'start': 2807.179, 'duration': 6.747}, {'end': 2814.947, 'text': 'for you to be able to understand it.', 'start': 2813.926, 'duration': 1.021}, {'end': 2824.953, 'text': "So our recommendation for kind of dealing with these issues is a very careful deployment strategy, which I've summarized in this little graph,", 'start': 2815.607, 'duration': 9.346}, {'end': 2826.034, 'text': 'this little chart, here.', 'start': 2824.953, 'duration': 1.081}, {'end': 2834.74, 'text': "The idea would be first of all, whatever it is that you're going to use the model for, start out by doing it manually.", 'start': 2827.615, 'duration': 7.125}], 'summary': 'Recommend careful deployment strategy for understanding and using the model.', 'duration': 27.561, 'max_score': 2807.179, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42807179.jpg'}], 'start': 2362.21, 'title': 'Model bias and ethical ml deployment', 'summary': 'Emphasizes the importance of examining training data to avoid model bias and discusses challenges in deploying ml models, addressing issues such as domain shift, bias, and providing a careful deployment strategy.', 'chapters': [{'end': 2522.1, 'start': 2362.21, 'title': 'Model bias in training data', 'summary': 'Highlights the importance of carefully examining training data to avoid model bias, with an example of a healthy skin classifier learning biased definitions from search results and emphasizes the need for real-world reflective test data.', 'duration': 159.89, 'highlights': ['Examining training data to avoid model bias is crucial for algorithm training.', 'The example of a healthy skin classifier learning biased definitions from search results underscores the importance of checking training data carefully.', 'The need for real-world reflective test data is emphasized for accurate model evaluation.', 'Gathering a gold standard test set with input from dermatologists is recommended for validation purposes.', 'The importance of being cautious and gathering diverse data for algorithm training and deployment is emphasized.']}, {'end': 2961.475, 'start': 2522.24, 'title': 'Ethical considerations in ml deployment', 'summary': 'Discusses the challenges of deploying machine learning models, addressing issues such as out of domain data, domain shift, bias in data, and the limitations of understanding neural network behavior, and provides a careful deployment strategy.', 'duration': 439.235, 'highlights': ['The chapter discusses the challenges of deploying machine learning models, addressing issues such as out of domain data, domain shift, bias in data, and the limitations of understanding neural network behavior. The transcript addresses the challenges of deploying machine learning models, covering topics like out of domain data, domain shift, bias in data, and the limitations of understanding neural network behavior.', "The chapter provides a careful deployment strategy, including manual verification, time and geography limited deployment, and gradual scaling. A careful deployment strategy is outlined, involving manual verification, time and geography limited deployment, and gradual scaling to ensure the model's performance and mitigate risks.", "The importance of understanding the limitations and biases in the dataset is emphasized, with proposals such as data sheets for datasets and maintaining awareness of the data's attributes. The importance of understanding dataset limitations and biases is stressed, with proposals like data sheets for datasets and maintaining awareness of the data's attributes for mitigating biases."]}], 'duration': 599.265, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42362210.jpg', 'highlights': ['The importance of examining training data to avoid model bias is crucial for algorithm training.', 'The need for real-world reflective test data is emphasized for accurate model evaluation.', 'Gathering a gold standard test set with input from dermatologists is recommended for validation purposes.', 'The importance of being cautious and gathering diverse data for algorithm training and deployment is emphasized.', 'The chapter provides a careful deployment strategy, including manual verification, time and geography limited deployment, and gradual scaling.', "The importance of understanding the limitations and biases in the dataset is emphasized, with proposals such as data sheets for datasets and maintaining awareness of the data's attributes.", 'The example of a healthy skin classifier learning biased definitions from search results underscores the importance of checking training data carefully.', 'The chapter discusses the challenges of deploying machine learning models, addressing issues such as out of domain data, domain shift, bias in data, and the limitations of understanding neural network behavior.']}, {'end': 3819.237, 'segs': [{'end': 3013.42, 'src': 'embed', 'start': 2961.535, 'weight': 0, 'content': [{'end': 2970.395, 'text': "And you've got to make sure that, when you're doing this, that you have a lot of really good reporting systems in place that you can recognize.", 'start': 2961.535, 'duration': 8.86}, {'end': 2972.577, 'text': 'are your customers yelling at you?', 'start': 2970.395, 'duration': 2.182}, {'end': 2975.639, 'text': 'are your computers burning up?', 'start': 2972.577, 'duration': 3.062}, {'end': 2981.324, 'text': 'you know, are your computers burning up?', 'start': 2975.639, 'duration': 5.685}, {'end': 2985.107, 'text': 'are your costs spiraling out of control, and so forth?', 'start': 2981.324, 'duration': 3.783}, {'end': 2990.212, 'text': 'So it really requires great reporting systems.', 'start': 2985.508, 'duration': 4.704}, {'end': 2996.566, 'text': 'Does FastAI have methods built in that provide for incremental learning?', 'start': 2992.52, 'duration': 4.046}, {'end': 3000.492, 'text': 'i.e.. improving the model slowly over time, with a single data point each time?', 'start': 2996.566, 'duration': 3.926}, {'end': 3002.933, 'text': "Yeah, that's a great question.", 'start': 3001.892, 'duration': 1.041}, {'end': 3012.599, 'text': 'So this is a little bit different, which is, this is really about dealing with domain shift and similar issues by continuing to train your model,', 'start': 3003.353, 'duration': 9.246}, {'end': 3013.42, 'text': 'as you do inference.', 'start': 3012.599, 'duration': 0.821}], 'summary': 'Implement good reporting systems, and fastai supports incremental learning for addressing domain shift and similar issues.', 'duration': 51.885, 'max_score': 2961.535, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42961535.jpg'}, {'end': 3082.826, 'src': 'embed', 'start': 3060.273, 'weight': 2, 'content': [{'end': 3071.459, 'text': "So as you roll out your model, one thing to be thinking about super carefully is that it might change the behavior of the system that it's a part of.", 'start': 3060.273, 'duration': 11.186}, {'end': 3075.081, 'text': 'And this can create something called a feedback loop.', 'start': 3072.62, 'duration': 2.461}, {'end': 3082.826, 'text': 'And feedback loops are one of the most challenging things for real-world model deployment, particularly of machine learning models.', 'start': 3075.522, 'duration': 7.304}], 'summary': 'Model deployment requires careful consideration to avoid feedback loops.', 'duration': 22.553, 'max_score': 3060.273, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43060273.jpg'}, {'end': 3384.808, 'src': 'embed', 'start': 3360.168, 'weight': 3, 'content': [{'end': 3367.993, 'text': "If you can decrease the amount of human involvement by like 90%, you've got almost all of the economic upside of automating it completely,", 'start': 3360.168, 'duration': 7.825}, {'end': 3370.975, 'text': 'but you still have the room to put human circuit breakers in place.', 'start': 3367.993, 'duration': 2.982}, {'end': 3374.497, 'text': 'You need these appeals processes, you need the monitoring.', 'start': 3370.995, 'duration': 3.502}, {'end': 3379.462, 'text': "You need humans involved to kind of go, hey, that's weird.", 'start': 3374.838, 'duration': 4.624}, {'end': 3380.563, 'text': "I don't think that's what we want.", 'start': 3379.642, 'duration': 0.921}, {'end': 3384.808, 'text': 'Okay Yes, Rachel.', 'start': 3380.583, 'duration': 4.225}], 'summary': 'Automating processes by 90% retains economic upside while allowing human oversight.', 'duration': 24.64, 'max_score': 3360.168, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43360168.jpg'}, {'end': 3565.517, 'src': 'embed', 'start': 3527.698, 'weight': 7, 'content': [{'end': 3533.224, 'text': "So I actually suggest you read Emmanuel's book, that book I showed you to understand the kind of the ideas.", 'start': 3527.698, 'duration': 5.526}, {'end': 3538.61, 'text': 'And if people are interested in this, I can also point you at some academic research about this as well.', 'start': 3534.285, 'duration': 4.325}, {'end': 3543.816, 'text': "There's not as much as there should be, but there is some good work in this area.", 'start': 3539.111, 'duration': 4.705}, {'end': 3558.549, 'text': 'Okay, so the reason we mentioned writing at this point in our journey is because you know things are going to start to get more and more heavy,', 'start': 3546.937, 'duration': 11.612}, {'end': 3565.517, 'text': "more and more complicated, and a really good way to make sure that you're on top of it is to try to write down what you've learned.", 'start': 3558.549, 'duration': 6.968}], 'summary': "Suggest reading emmanuel's book for understanding ideas, with academic research available. writing down learned content helps manage complexity.", 'duration': 37.819, 'max_score': 3527.698, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43527698.jpg'}, {'end': 3624.407, 'src': 'embed', 'start': 3596.077, 'weight': 4, 'content': [{'end': 3602.118, 'text': 'So Rachel says But the top advice she would give her younger self is to start blogging sooner.', 'start': 3596.077, 'duration': 6.041}, {'end': 3611.141, 'text': 'So Rachel has a math PhD and this kind of idea of like blogging was not exactly something I think they had a lot of in the PhD program.', 'start': 3602.759, 'duration': 8.382}, {'end': 3617.384, 'text': "But actually it's like it's a really great way of finding jobs.", 'start': 3612.162, 'duration': 5.222}, {'end': 3624.407, 'text': 'In fact, most of my students who have got the best jobs are students that have good blog posts.', 'start': 3617.504, 'duration': 6.903}], 'summary': 'Starting a blog earlier could have led to better job opportunities for students with good blog posts.', 'duration': 28.33, 'max_score': 3596.077, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43596077.jpg'}, {'end': 3728.922, 'src': 'embed', 'start': 3702.087, 'weight': 5, 'content': [{'end': 3706.212, 'text': 'And so you can go to fast pages and see for yourself how to do it.', 'start': 3702.087, 'duration': 4.125}, {'end': 3710.938, 'text': 'But the basic idea is that, like you, literally click one button,', 'start': 3706.252, 'duration': 4.686}, {'end': 3724.04, 'text': 'it sets up a blog for you and then you dump your notebooks into a folder called underscore notebooks and they get turned into blog posts.', 'start': 3712.395, 'duration': 11.645}, {'end': 3728.922, 'text': "It's basically like magic and Hamill's done this amazing job of this,", 'start': 3724.42, 'duration': 4.502}], 'summary': 'Fast pages allows users to set up a blog with one click, converting notebooks into blog posts like magic.', 'duration': 26.835, 'max_score': 3702.087, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43702087.jpg'}, {'end': 3833.686, 'src': 'embed', 'start': 3802.772, 'weight': 6, 'content': [{'end': 3804.552, 'text': 'because you were there six months ago.', 'start': 3802.772, 'duration': 1.78}, {'end': 3811.474, 'text': 'So try and write something which the six months ago version of you would have been like super interesting,', 'start': 3804.852, 'duration': 6.622}, {'end': 3813.755, 'text': 'full of little tidbits you would have loved.', 'start': 3811.474, 'duration': 2.281}, {'end': 3814.615, 'text': 'you know that you would have.', 'start': 3813.755, 'duration': 0.86}, {'end': 3815.796, 'text': 'that would have delighted you.', 'start': 3814.615, 'duration': 1.181}, {'end': 3819.237, 'text': 'That six months ago version of you.', 'start': 3815.816, 'duration': 3.421}, {'end': 3830.905, 'text': "Okay, so once again, don't move on until you've had a go at the questionnaire to make sure that you, you know,", 'start': 3820.982, 'duration': 9.923}, {'end': 3833.686, 'text': 'understand the key things we think that you need to understand.', 'start': 3830.905, 'duration': 2.781}], 'summary': 'Encourage writing with interesting tidbits for past self.', 'duration': 30.914, 'max_score': 3802.772, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43802772.jpg'}], 'start': 2961.535, 'title': 'Model deployment and blogging', 'summary': "Discusses real-world model deployment emphasizing reporting systems, incremental learning, and risks of feedback loops, and also emphasizes the importance of blogging for learning and job opportunities, citing rachel's article, creation of fast pages, and advice on writing for a similar audience.", 'chapters': [{'end': 3527.017, 'start': 2961.535, 'title': 'Real-world model deployment', 'summary': 'Discusses the importance of reporting systems, incremental learning, and the risks of feedback loops in real-world model deployment, highlighting the need for careful monitoring and human involvement.', 'duration': 565.482, 'highlights': ['The importance of reporting systems for recognizing customer feedback and controlling costs is emphasized. Having good reporting systems in place to recognize customer feedback and control costs is crucial for successful model deployment.', 'The concept of incremental learning and the need for domain shift adaptation through continued model training is explained, with a suggested approach of nightly model updates. Incremental learning is discussed as a method for adapting to domain shift through continued model training, with a recommended approach of nightly model updates using transfer learning.', 'The risks of feedback loops in model deployment, particularly in the context of predictive policing algorithms, are detailed, emphasizing the potential amplification of biases and the need for careful oversight. The risks of feedback loops in model deployment, particularly in the context of predictive policing algorithms, are highlighted, emphasizing the potential amplification of biases and the need for careful oversight.', 'The importance of human involvement, appeals processes, and monitoring in mitigating feedback loops is emphasized, with integration between trust and safety, product, and engineering teams highlighted as essential. The importance of human involvement, appeals processes, and monitoring in mitigating feedback loops is emphasized, with integration between trust and safety, product, and engineering teams highlighted as essential for effective mitigation.']}, {'end': 3819.237, 'start': 3527.698, 'title': 'Blogging for learning and job opportunities', 'summary': "Emphasizes the importance of blogging for learning and job opportunities, citing rachel's article on the benefits of blogging, the creation of fast pages for easy blogging with jupyter notebooks, and the advice to write for an audience similar to oneself.", 'duration': 291.539, 'highlights': ["Rachel's article highlights the benefits of blogging for job opportunities, with the majority of students securing the best jobs through good blog posts.", 'The creation of Fast Pages simplifies blogging with Jupyter Notebooks by allowing users to set up a blog with one click and convert notebooks into blog posts, enabling the inclusion of charts, tables, images, and markdown-formatted text.', 'The advice to write blog posts for an audience similar to oneself, focusing on content that would have been interesting and helpful to the writer six months ago.', 'Emphasizing the importance of writing down what is learned to manage increasing complexity in learning, which is also supported by academic research.', "The suggestion to read Emmanuel's book to understand the ideas related to blogging and finding academic research on the topic."]}], 'duration': 857.702, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC42961535.jpg', 'highlights': ['Good reporting systems are crucial for successful model deployment.', 'Incremental learning is discussed as a method for adapting to domain shift through continued model training.', 'The risks of feedback loops in model deployment are highlighted, emphasizing the potential amplification of biases and the need for careful oversight.', 'The importance of human involvement, appeals processes, and monitoring in mitigating feedback loops is emphasized.', "Rachel's article highlights the benefits of blogging for job opportunities.", 'The creation of Fast Pages simplifies blogging with Jupyter Notebooks by allowing users to set up a blog with one click and convert notebooks into blog posts.', 'The advice to write blog posts for an audience similar to oneself, focusing on content that would have been interesting and helpful to the writer six months ago.', 'Emphasizing the importance of writing down what is learned to manage increasing complexity in learning.', "The suggestion to read Emmanuel's book to understand the ideas related to blogging and finding academic research on the topic."]}, {'end': 4697.849, 'segs': [{'end': 3985.799, 'src': 'embed', 'start': 3958.988, 'weight': 0, 'content': [{'end': 3965.834, 'text': 'It contains handwritten digits and it was collated into a machine learning data set by a guy called John LeCun.', 'start': 3958.988, 'duration': 6.846}, {'end': 3971.095, 'text': 'and some colleagues, and they use that to demonstrate one of the you know,', 'start': 3967.074, 'duration': 4.021}, {'end': 3976.877, 'text': 'probably the first computer system to provide really practically useful scalable recognition of handwritten digits.', 'start': 3971.095, 'duration': 5.782}, {'end': 3985.799, 'text': 'Lynette 5 with the system was actually used to automatically process like 10% of the checks in the US.', 'start': 3977.437, 'duration': 8.362}], 'summary': 'John lecun and colleagues created a system that processed 10% of us checks, demonstrating practical scalable recognition of handwritten digits.', 'duration': 26.811, 'max_score': 3958.988, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43958988.jpg'}, {'end': 4033.707, 'src': 'embed', 'start': 4006.035, 'weight': 3, 'content': [{'end': 4010.298, 'text': 'Okay, so this is a good starting point to make sure that we can kind of do something easy.', 'start': 4006.035, 'duration': 4.263}, {'end': 4013.4, 'text': "I picked threes and sevens for MNIST sample because they're very different.", 'start': 4010.378, 'duration': 3.022}, {'end': 4017.383, 'text': "I feel like if we can't do this, we're going to have trouble recognizing every digit.", 'start': 4014.161, 'duration': 3.222}, {'end': 4023.78, 'text': 'So step one is to call untar data.', 'start': 4021.579, 'duration': 2.201}, {'end': 4033.707, 'text': "Untar data is the fastai function, which takes a URL, checks whether you've already downloaded it.", 'start': 4023.921, 'duration': 9.786}], 'summary': 'Using threes and sevens for mnist sample to recognize every digit.', 'duration': 27.672, 'max_score': 4006.035, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44006035.jpg'}, {'end': 4464.106, 'src': 'embed', 'start': 4439.935, 'weight': 2, 'content': [{'end': 4447.179, 'text': 'But the key thing is that a PyTorch tensor can also be computed on a GPU, not just a CPU.', 'start': 4439.935, 'duration': 7.244}, {'end': 4457.943, 'text': 'So in our work and in the book and in the notebooks, in our code we tend to use tensors, PyTorch tensors, much more often than NumPy arrays,', 'start': 4447.739, 'duration': 10.204}, {'end': 4464.106, 'text': 'because they kind of have nearly all the benefits of NumPy arrays, plus all the benefits of GPU computation,', 'start': 4457.943, 'duration': 6.163}], 'summary': 'Pytorch tensors can be computed on gpu, offering benefits of numpy arrays and gpu computation.', 'duration': 24.171, 'max_score': 4439.935, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44439935.jpg'}, {'end': 4662.74, 'src': 'embed', 'start': 4635.731, 'weight': 1, 'content': [{'end': 4645.019, 'text': "And then, so when we then grab something from the validation set to classify, we'll say like oh, Is this image closer to the ideal threes,", 'start': 4635.731, 'duration': 9.288}, {'end': 4647.964, 'text': 'the ideal three, the mean of the threes, or the ideal seven?', 'start': 4645.019, 'duration': 2.945}, {'end': 4650.187, 'text': 'This is my idea.', 'start': 4649.406, 'duration': 0.781}, {'end': 4653.251, 'text': "And so I'm going to call this the pixel similarity approach.", 'start': 4650.688, 'duration': 2.563}, {'end': 4655.775, 'text': "I'm describing this as a baseline.", 'start': 4654.092, 'duration': 1.683}, {'end': 4662.74, 'text': 'A baseline is like super simple model that should be pretty easy to program from scratch with very little magic.', 'start': 4656.296, 'duration': 6.444}], 'summary': 'Proposing a pixel similarity approach as a simple baseline for image classification.', 'duration': 27.009, 'max_score': 4635.731, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44635731.jpg'}], 'start': 3820.982, 'title': 'Engaging with machine learning course material and recognizing handwritten digits with mnist sample', 'summary': "Emphasizes the importance of understanding key concepts before diving into technical aspects, along with recognizing handwritten digits using the mnist sample dataset, which was used to process 10% of the checks in the us. it covers untarring the data, exploring the folder hierarchy, converting images into arrays and tensors, and creating a baseline 'pixel similarity' approach for classification.", 'chapters': [{'end': 3932.922, 'start': 3820.982, 'title': 'Engaging with machine learning course material', 'summary': 'Emphasizes the importance of completing the questionnaire and considering further research questions to understand key concepts before diving into more technical aspects of the course, while highlighting the transition from non-technical to technical content.', 'duration': 111.94, 'highlights': ['Completing the questionnaire and considering further research questions are emphasized to ensure understanding of key course concepts.', "The chapter marks a transition from non-technical to technical content, with a shift from minimal code and no math to 'diving deep' into more technical aspects of the course.", 'Students are encouraged to skip to the next lesson about ethics if they are not interested in the technical aspects of the course.']}, {'end': 4697.849, 'start': 3932.922, 'title': 'Recognizing handwritten digits with mnist sample', 'summary': "Discusses recognizing handwritten digits using the mnist sample dataset, which was used to demonstrate the first computer system for scalable recognition of handwritten digits and was later used to process 10% of the checks in the us. it covers the process of untarring the data, exploring the folder hierarchy, converting images into arrays and tensors, and creating a baseline 'pixel similarity' approach for classification.", 'duration': 764.927, 'highlights': ['The MNIST sample dataset was used to demonstrate the first computer system for scalable recognition of handwritten digits and later used to process 10% of the checks in the US. MNIST sample dataset demonstrated the first scalable recognition system for handwritten digits and processed 10% of US checks.', "The process of untarring the data and exploring the folder hierarchy using the fastai function 'untar data' is explained. The untar data function is used to download and uncompress the dataset, and the folder hierarchy is explored.", 'Converting images into arrays and tensors using the Python imaging library (PIL) and NumPy is discussed, along with the benefits of using PyTorch tensors for GPU computation. Images are converted into arrays and tensors using PIL and NumPy. The benefits of using PyTorch tensors for GPU computation are highlighted.', "Creating a baseline 'pixel similarity' approach for classification, which involves taking the average of pixels for threes and sevens, is introduced as a simple model for classification. The 'pixel similarity' approach is described as a simple baseline model for classification, involving the averaging of pixels for threes and sevens."]}], 'duration': 876.867, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC43820982.jpg', 'highlights': ['The MNIST sample dataset was used to demonstrate the first computer system for scalable recognition of handwritten digits and later used to process 10% of the checks in the US.', "Creating a baseline 'pixel similarity' approach for classification, which involves taking the average of pixels for threes and sevens, is introduced as a simple model for classification.", 'Converting images into arrays and tensors using the Python imaging library (PIL) and NumPy is discussed, along with the benefits of using PyTorch tensors for GPU computation.', "The process of untarring the data and exploring the folder hierarchy using the fastai function 'untar data' is explained."]}, {'end': 5396.824, 'segs': [{'end': 4723.05, 'src': 'embed', 'start': 4697.849, 'weight': 2, 'content': [{'end': 4706.336, 'text': "and they'll say oh look, the accuracy is 80%, and then I'll say, okay, let's see what happens if we create a model where we always predict the mean,", 'start': 4697.849, 'duration': 8.487}, {'end': 4713.341, 'text': "oh look, that's 85%, and people get pretty disheartened when they discover this right.", 'start': 4706.336, 'duration': 7.005}, {'end': 4717.645, 'text': 'and so make sure you start with a reasonable baseline and then gradually build on top of it.', 'start': 4713.341, 'duration': 4.304}, {'end': 4723.05, 'text': 'So we need to get the average of the pixels.', 'start': 4719.269, 'duration': 3.781}], 'summary': 'Start with a reasonable baseline, like predicting the mean (85% accuracy), to build on top of.', 'duration': 25.201, 'max_score': 4697.849, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44697849.jpg'}, {'end': 4826.82, 'src': 'embed', 'start': 4798.747, 'weight': 0, 'content': [{'end': 4807.574, 'text': "So Silva and I use list and dictionary comprehensions every day and so you should definitely spend some time checking it out if you haven't already.", 'start': 4798.747, 'duration': 8.827}, {'end': 4818.698, 'text': "So now that we've got a list of all of the threes as tensors, let's just grab one of them and display it.", 'start': 4809.096, 'duration': 9.602}, {'end': 4823.759, 'text': 'So remember, this is a tensor, not a PIL image object.', 'start': 4820.058, 'duration': 3.701}, {'end': 4826.82, 'text': "So Jupyter doesn't know how to display it.", 'start': 4825.119, 'duration': 1.701}], 'summary': 'Use list and dictionary comprehensions daily for tensor operations.', 'duration': 28.073, 'max_score': 4798.747, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44798747.jpg'}, {'end': 4934.006, 'src': 'embed', 'start': 4868.136, 'weight': 1, 'content': [{'end': 4878.701, 'text': 'So this is this is the rows by columns the size of this thing, right? But three tensors itself just a list.', 'start': 4868.136, 'duration': 10.565}, {'end': 4882.803, 'text': "So I can't really easily do mathematical computations on that.", 'start': 4879.482, 'duration': 3.321}, {'end': 4893.207, 'text': 'So what we could do is we could stack all of these 28 by 28 images on top of each other to create a, like a 3D cube of images.', 'start': 4883.323, 'duration': 9.884}, {'end': 4895.168, 'text': "And that's still called a tensor.", 'start': 4893.807, 'duration': 1.361}, {'end': 4899.27, 'text': 'So a tensor can have as many of these axes or dimensions as you like.', 'start': 4895.508, 'duration': 3.762}, {'end': 4901.991, 'text': 'And to stack them up you use funnily enough.', 'start': 4899.85, 'duration': 2.141}, {'end': 4912.256, 'text': 'So this is going to turn the list into a tensor and, as you can see, the shape of it is now 6131 by 28 by 28..', 'start': 4904.292, 'duration': 7.964}, {'end': 4926.922, 'text': "So it's kind of like a cube of height 6131 by 28 by 28.", 'start': 4912.256, 'duration': 14.666}, {'end': 4934.006, 'text': "The other thing we want to do is if we're going to take the mean, we want to turn them into floating point values,", 'start': 4926.922, 'duration': 7.084}], 'summary': 'Tensors can have multiple axes, as shown by a 6131x28x28 cube of images.', 'duration': 65.87, 'max_score': 4868.136, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44868136.jpg'}, {'end': 4993.747, 'src': 'embed', 'start': 4964.98, 'weight': 3, 'content': [{'end': 4967.661, 'text': 'So these three things here are called the axes.', 'start': 4964.98, 'duration': 2.681}, {'end': 4970.421, 'text': 'First axis, second axis, third axis.', 'start': 4968.281, 'duration': 2.14}, {'end': 4976.823, 'text': 'And overall we would say that this is a rank three tensor.', 'start': 4972.682, 'duration': 4.141}, {'end': 4979.203, 'text': 'It has three axes.', 'start': 4977.523, 'duration': 1.68}, {'end': 4984.225, 'text': 'So this one here was a rank two tensor.', 'start': 4979.763, 'duration': 4.462}, {'end': 4986.185, 'text': 'It has two axes.', 'start': 4985.305, 'duration': 0.88}, {'end': 4992.166, 'text': 'So you can get the rank from a tensor by just taking the length of its shape.', 'start': 4988.506, 'duration': 3.66}, {'end': 4993.747, 'text': 'One, two, three.', 'start': 4993.027, 'duration': 0.72}], 'summary': 'Introduction to tensors: rank three tensor with three axes, and rank two tensor with two axes.', 'duration': 28.767, 'max_score': 4964.98, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44964980.jpg'}, {'end': 5086.967, 'src': 'heatmap', 'start': 4995.214, 'weight': 0.732, 'content': [{'end': 5007.165, 'text': "Okay, you can also get that from, so the word I've been using the word axis, you can also use the word dimension.", 'start': 4995.214, 'duration': 11.951}, {'end': 5012.09, 'text': 'I think numpy tends to call axis, pytorch tends to call it dimension.', 'start': 5007.185, 'duration': 4.905}, {'end': 5017.795, 'text': 'So the rank is also the number of dimensions and dim.', 'start': 5013.111, 'duration': 4.684}, {'end': 5024.313, 'text': 'So you need to make sure that you remember this word.', 'start': 5020.532, 'duration': 3.781}, {'end': 5033.436, 'text': 'rank is the number of axes or dimensions in a tensor, and the shape is a list containing the size of each axis in a tensor.', 'start': 5024.313, 'duration': 9.123}, {'end': 5042.039, 'text': 'So we can now say stack3s.mean.', 'start': 5037.738, 'duration': 4.301}, {'end': 5049.727, 'text': 'Now if we just say stack3s.mean that returns a single number.', 'start': 5042.539, 'duration': 7.188}, {'end': 5054.754, 'text': "That's the average pixel across that whole cube, that whole rank three tensor.", 'start': 5050.168, 'duration': 4.586}, {'end': 5060.401, 'text': 'But if we say mean zero, that is take the mean over this axis.', 'start': 5055.535, 'duration': 4.866}, {'end': 5063.545, 'text': "That's the mean across the images.", 'start': 5060.942, 'duration': 2.603}, {'end': 5077.446, 'text': "And so that's now 28 by 28 again because we kind of like reduced over this 6, 1, 3, 1 axis.", 'start': 5065.027, 'duration': 12.419}, {'end': 5079.946, 'text': 'We took the mean across that axis.', 'start': 5077.846, 'duration': 2.1}, {'end': 5086.967, 'text': 'And so we can show that image and here is our ideal 3.', 'start': 5080.786, 'duration': 6.181}], 'summary': 'Understanding tensor rank, shape, and mean calculations in python libraries like numpy and pytorch.', 'duration': 91.753, 'max_score': 4995.214, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44995214.jpg'}, {'end': 5203.755, 'src': 'embed', 'start': 5171.323, 'weight': 4, 'content': [{'end': 5172.383, 'text': "So let's have a look.", 'start': 5171.323, 'duration': 1.06}, {'end': 5175.948, 'text': "Let's take a 3.", 'start': 5172.863, 'duration': 3.085}, {'end': 5192.032, 'text': 'and subtract from it the mean of the threes and take the absolute value and take the mean and call that the distance using absolute value of the three to a three and that there is the number 0.1..', 'start': 5175.948, 'duration': 16.084}, {'end': 5195.033, 'text': 'So this is the mean absolute difference or L1 norm.', 'start': 5192.032, 'duration': 3.001}, {'end': 5203.755, 'text': "So, when you see a word like L1 norm, if you haven't seen it before, it may sound pretty fancy, but all these math terms that we see, you know.", 'start': 5195.793, 'duration': 7.962}], 'summary': 'The l1 norm is the mean absolute difference, denoted by the number 0.1.', 'duration': 32.432, 'max_score': 5171.323, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45171323.jpg'}, {'end': 5306.055, 'src': 'embed', 'start': 5273.92, 'weight': 5, 'content': [{'end': 5277.935, 'text': 'So this is like a machine learning model, kind of.', 'start': 5273.92, 'duration': 4.015}, {'end': 5282.197, 'text': "It's a data-driven model which attempts to recognize threes versus sevens.", 'start': 5278.135, 'duration': 4.062}, {'end': 5284.558, 'text': 'And so this is a good baseline.', 'start': 5283.438, 'duration': 1.12}, {'end': 5287.52, 'text': "I mean it's a reasonable baseline.", 'start': 5285.799, 'duration': 1.721}, {'end': 5290.942, 'text': "It's going to be better than random.", 'start': 5287.54, 'duration': 3.402}, {'end': 5295.124, 'text': "We don't actually have to write out minus abs mean.", 'start': 5291.382, 'duration': 3.742}, {'end': 5299.327, 'text': 'We can just actually use L1 loss.', 'start': 5296.725, 'duration': 2.602}, {'end': 5301.708, 'text': 'L1 loss does exactly that.', 'start': 5299.887, 'duration': 1.821}, {'end': 5306.055, 'text': "We don't have to write minus squared.", 'start': 5304.172, 'duration': 1.883}], 'summary': 'A data-driven model for recognizing threes versus sevens using l1 loss as a baseline.', 'duration': 32.135, 'max_score': 5273.92, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45273920.jpg'}, {'end': 5366.491, 'src': 'embed', 'start': 5336.537, 'weight': 6, 'content': [{'end': 5345.432, 'text': 'we can convert it into an array or into a tensor, we can display it and they look almost the same.', 'start': 5336.537, 'duration': 8.895}, {'end': 5348.655, 'text': 'You can index into a single row.', 'start': 5346.793, 'duration': 1.862}, {'end': 5352.038, 'text': 'You can index into a single column.', 'start': 5350.396, 'duration': 1.642}, {'end': 5353.999, 'text': "And so it's important to know.", 'start': 5352.818, 'duration': 1.181}, {'end': 5355.261, 'text': 'this is very important.', 'start': 5353.999, 'duration': 1.262}, {'end': 5362.247, 'text': 'colon means every row, because I put it in the first spot right?', 'start': 5355.261, 'duration': 6.986}, {'end': 5366.491, 'text': 'So if I put it in the second spot, it would mean every column.', 'start': 5362.687, 'duration': 3.804}], 'summary': 'Data can be converted into array or tensor, and indexed by row or column.', 'duration': 29.954, 'max_score': 5336.537, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45336537.jpg'}], 'start': 4697.849, 'title': 'Python programming tricks for data analysis and understanding tensors and rank', 'summary': 'Covers python programming tricks including list comprehension and image manipulation, as well as understanding tensors, ranks, and distance computation using l1 norm and l2 norm, which are crucial in data analysis and machine learning.', 'chapters': [{'end': 4962.022, 'start': 4697.849, 'title': 'Python programming tricks for data analysis', 'summary': 'Discusses the importance of starting with a reasonable baseline, using list comprehension to manipulate data, and converting images into tensors to calculate the average, demonstrating a technique to represent images in pytorch.', 'duration': 264.173, 'highlights': ['Using list comprehension to convert a list of images into tensors, allowing for efficient manipulation and analysis of the data.', 'Demonstrating the process of converting images into tensors, stacking them to create a 3D cube of images, and converting them into floating point values, providing valuable insights into data preprocessing and representation in PyTorch.', 'Emphasizing the significance of starting with a reasonable baseline before building more complex models, showcasing the practical approach to model evaluation and development.']}, {'end': 5396.824, 'start': 4964.98, 'title': 'Understanding tensors and rank in data analysis', 'summary': 'Provides an overview of tensors and ranks, explaining how to determine the rank of a tensor, the concept of mean across different axes, and the computation of distance using l1 norm and l2 norm for comparing data, all of which are essential in data analysis and machine learning.', 'duration': 431.844, 'highlights': ["Explaining the concept of rank and dimension in tensors, highlighting the determination of rank by the length of its shape and the interchangeability of the terms 'axis' and 'dimension'. Rank is determined by the length of the shape of a tensor, interchangeability of the terms 'axis' and 'dimension'.", 'Illustrating the calculation of mean across different axes of a tensor and its impact on the resulting dimensions, with a practical example of calculating the mean across images resulting in a 28x28 output. Calculation of mean across different axes, practical example resulting in 28x28 output.', 'Detailing the methods for computing distance using L1 norm and L2 norm, emphasizing the importance of transforming differences into positive numbers and providing practical examples to demonstrate the calculation of distance using absolute value and square root methods. Methods for computing distance using L1 norm and L2 norm, importance of transforming differences into positive numbers.', 'Demonstrating the application of L1 loss for calculating distance and the significance of understanding mathematical concepts in code implementation, with examples showcasing the comparison of values using L1 and L2 loss. Application of L1 loss for calculating distance, significance of understanding mathematical concepts in code implementation.', 'Highlighting the importance of being comfortable with working with arrays and tensors, explaining the similarities, conversion between array and tensor, and the significance of understanding indexing and colon representation in data manipulation. Importance of being comfortable with working with arrays and tensors, significance of understanding indexing and colon representation in data manipulation.']}], 'duration': 698.975, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC44697849.jpg', 'highlights': ['Using list comprehension to convert a list of images into tensors, allowing for efficient manipulation and analysis of the data.', 'Demonstrating the process of converting images into tensors, stacking them to create a 3D cube of images, and converting them into floating point values, providing valuable insights into data preprocessing and representation in PyTorch.', 'Emphasizing the significance of starting with a reasonable baseline before building more complex models, showcasing the practical approach to model evaluation and development.', "Explaining the concept of rank and dimension in tensors, highlighting the determination of rank by the length of its shape and the interchangeability of the terms 'axis' and 'dimension'.", 'Detailing the methods for computing distance using L1 norm and L2 norm, emphasizing the importance of transforming differences into positive numbers and providing practical examples to demonstrate the calculation of distance using absolute value and square root methods.', 'Demonstrating the application of L1 loss for calculating distance and the significance of understanding mathematical concepts in code implementation, with examples showcasing the comparison of values using L1 and L2 loss.', 'Highlighting the importance of being comfortable with working with arrays and tensors, explaining the similarities, conversion between array and tensor, and the significance of understanding indexing and colon representation in data manipulation.', 'Illustrating the calculation of mean across different axes of a tensor and its impact on the resulting dimensions, with a practical example of calculating the mean across images resulting in a 28x28 output.']}, {'end': 5938.394, 'segs': [{'end': 5448.144, 'src': 'embed', 'start': 5397.205, 'weight': 2, 'content': [{'end': 5402.531, 'text': 'So give me the first row and everything from the first up to but not including the third column.', 'start': 5397.205, 'duration': 5.326}, {'end': 5405.174, 'text': "So there's that five, six.", 'start': 5404.172, 'duration': 1.002}, {'end': 5410.459, 'text': 'You can add stuff to them, you can check their type.', 'start': 5407.636, 'duration': 2.823}, {'end': 5421.202, 'text': "Notice that this is different to the Python, the Python So type is a function, just tells you it's a tensor.", 'start': 5410.92, 'duration': 10.282}, {'end': 5424.768, 'text': 'If you want to know what kind of tensor, you have to use type as a method.', 'start': 5421.983, 'duration': 2.785}, {'end': 5426.151, 'text': "So it's a long tensor.", 'start': 5425.149, 'duration': 1.002}, {'end': 5432.613, 'text': 'You can multiply them by a float, turns it into a float, you know.', 'start': 5429.071, 'duration': 3.542}, {'end': 5433.714, 'text': 'So have a fiddle around.', 'start': 5432.793, 'duration': 0.921}, {'end': 5442.741, 'text': "If you haven't done much stuff with numpy or pytorch before, this is a good opportunity to just go crazy.", 'start': 5433.754, 'duration': 8.987}, {'end': 5443.841, 'text': 'Try things out.', 'start': 5442.801, 'duration': 1.04}, {'end': 5448.144, 'text': 'Try things that you think might not work and see if you actually get an error message, you know.', 'start': 5443.921, 'duration': 4.223}], 'summary': 'Introduction to manipulating tensors in pytorch, encouraging experimentation with numpy and pytorch.', 'duration': 50.939, 'max_score': 5397.205, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45397205.jpg'}, {'end': 5634.26, 'src': 'embed', 'start': 5604.893, 'weight': 1, 'content': [{'end': 5610.638, 'text': "So we need to do this for every image in the validation set, because we're trying to find the overall metric.", 'start': 5604.893, 'duration': 5.745}, {'end': 5614.341, 'text': 'Remember the metric is the thing we look at to say how good is our model.', 'start': 5610.798, 'duration': 3.543}, {'end': 5616.703, 'text': "So here's something crazy.", 'start': 5615.823, 'duration': 0.88}, {'end': 5627.814, 'text': 'We can call mnistDistance not just on r3, but on the entire validation set against the main3.', 'start': 5617.424, 'duration': 10.39}, {'end': 5630.516, 'text': "So that's wild.", 'start': 5629.735, 'duration': 0.781}, {'end': 5634.26, 'text': "Like there's no normal programming that we would do,", 'start': 5631.177, 'duration': 3.083}], 'summary': 'Using mnistdistance on the entire validation set to assess model performance.', 'duration': 29.367, 'max_score': 5604.893, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45604893.jpg'}, {'end': 5938.394, 'src': 'embed', 'start': 5914.366, 'weight': 0, 'content': [{'end': 5921.148, 'text': 'thanks to broadcasting we can do it for that entire set, right? So this is so cool.', 'start': 5914.366, 'duration': 6.782}, {'end': 5922.569, 'text': 'We basically get rid of loops.', 'start': 5921.268, 'duration': 1.301}, {'end': 5928.771, 'text': 'In, in, in, in this kind of programming you should have very few, very, very few loops.', 'start': 5923.949, 'duration': 4.822}, {'end': 5935.593, 'text': 'Loops make things much harder to read and, and hundreds of thousands of times slower.', 'start': 5928.891, 'duration': 6.702}, {'end': 5938.394, 'text': 'On the GPU potentially tens of millions of times slower.', 'start': 5935.994, 'duration': 2.4}], 'summary': 'Broadcasting reduces loops, making code more efficient by up to millions of times.', 'duration': 24.028, 'max_score': 5914.366, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45914366.jpg'}], 'start': 5397.205, 'title': 'Numpy, pytorch, model evaluation, and broadcasting', 'summary': 'Covers array manipulation in numpy and pytorch, model evaluation on a validation set, distance function usage, and broadcasting for efficient computation, resulting in speed improvements and code simplification.', 'chapters': [{'end': 5448.144, 'start': 5397.205, 'title': 'Introduction to numpy and pytorch', 'summary': 'Introduces how to manipulate and explore arrays in numpy and pytorch, including accessing elements, checking their type, and performing operations like multiplication, encouraging experimentation and error testing.', 'duration': 50.939, 'highlights': ['You can access elements of arrays and check their type using Numpy and PyTorch.', 'Performing operations like multiplication can change the type of the array, for example, turning an integer into a float.', 'The chapter encourages experimentation and error testing to gain a deeper understanding of array manipulation in Numpy and PyTorch.']}, {'end': 5938.394, 'start': 5451.311, 'title': 'Model evaluation and broadcasting', 'summary': "Discusses evaluating the model's performance on a validation set, using a distance function to compare images with ideal digits, and leveraging broadcasting for efficient computation, resulting in significant speed improvements and simplification of code.", 'duration': 487.083, 'highlights': ["The process of evaluating the model's performance on a validation set and comparing images with ideal digits using a distance function is highlighted, emphasizing the importance of assessing the model's accuracy on unseen data.", 'The concept of broadcasting is explained as a powerful tool for efficient computation and speed improvements, enabling the comparison of entire sets of data without the need for loops, resulting in significant performance gains on the GPU.']}], 'duration': 541.189, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45397205.jpg', 'highlights': ['The concept of broadcasting is explained as a powerful tool for efficient computation and speed improvements, enabling the comparison of entire sets of data without the need for loops, resulting in significant performance gains on the GPU.', "The process of evaluating the model's performance on a validation set and comparing images with ideal digits using a distance function is highlighted, emphasizing the importance of assessing the model's accuracy on unseen data.", 'You can access elements of arrays and check their type using Numpy and PyTorch.', 'Performing operations like multiplication can change the type of the array, for example, turning an integer into a float.', 'The chapter encourages experimentation and error testing to gain a deeper understanding of array manipulation in Numpy and PyTorch.']}, {'end': 7581.665, 'segs': [{'end': 5994.94, 'src': 'embed', 'start': 5959.108, 'weight': 0, 'content': [{'end': 5965.032, 'text': 'The accuracy on sevens is about ninety eight percent and the average of those two is about ninety five percent.', 'start': 5959.108, 'duration': 5.924}, {'end': 5972.454, 'text': "So here we have a model that's 95% accurate at recognizing 3s from 7s.", 'start': 5965.652, 'duration': 6.802}, {'end': 5984.818, 'text': "It might surprise you that we can do that using nothing but arithmetic, right? So that's what I mean by getting a good baseline.", 'start': 5974.014, 'duration': 10.804}, {'end': 5994.94, 'text': "Now, the thing is, It's not obvious how we kind of improve this, right?", 'start': 5987.858, 'duration': 7.082}], 'summary': 'Model achieves 95% accuracy in recognizing 3s from 7s using arithmetic.', 'duration': 35.832, 'max_score': 5959.108, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45959108.jpg'}, {'end': 6308.8, 'src': 'embed', 'start': 6281.178, 'weight': 2, 'content': [{'end': 6293.737, 'text': 'So these seven steps, one, two, three, four, five, six, These seven steps are the key to training all deep learning models.', 'start': 6281.178, 'duration': 12.559}, {'end': 6296.521, 'text': 'This technique is called Stochastic Gradient Descent.', 'start': 6294.157, 'duration': 2.364}, {'end': 6298.084, 'text': "Well, it's called gradient descent.", 'start': 6296.902, 'duration': 1.182}, {'end': 6300.187, 'text': "We'll see the stochastic bit very soon.", 'start': 6298.184, 'duration': 2.003}, {'end': 6308.8, 'text': "And for each of these seven steps there's lots of choices around exactly how to do it, right?", 'start': 6302.054, 'duration': 6.746}], 'summary': 'Seven steps are key to training deep learning models using stochastic gradient descent.', 'duration': 27.622, 'max_score': 6281.178, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC46281178.jpg'}, {'end': 6570.44, 'src': 'embed', 'start': 6539.889, 'weight': 4, 'content': [{'end': 6546.554, 'text': 'PyTorch has an engine built in that can take derivatives and find the gradient of functions.', 'start': 6539.889, 'duration': 6.665}, {'end': 6560.231, 'text': "So to do that We start with a tensor, let's say, and in this case we're going to modify this tensor with this special method called requiresGrad.", 'start': 6547.775, 'duration': 12.456}, {'end': 6570.44, 'text': 'And what this does is it tells PyTorch that anytime I do a calculation with this xt, it should remember what calculation it does,', 'start': 6560.872, 'duration': 9.568}], 'summary': "Pytorch's built-in engine can find gradients using requiresgrad method on tensors.", 'duration': 30.551, 'max_score': 6539.889, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC46539889.jpg'}, {'end': 6684.917, 'src': 'heatmap', 'start': 6593.339, 'weight': 0.718, 'content': [{'end': 6599.223, 'text': "So that means it's just going to have to keep track of all of the computations we do so that it can calculate the derivative later.", 'start': 6593.339, 'duration': 5.884}, {'end': 6609.846, 'text': "Okay, so we've got the number three, and let's say we then call f on it.", 'start': 6603.28, 'duration': 6.566}, {'end': 6611.848, 'text': 'Remember f is just squaring it.', 'start': 6609.906, 'duration': 1.942}, {'end': 6613.79, 'text': 'So three squared is nine.', 'start': 6612.489, 'duration': 1.301}, {'end': 6622.759, 'text': "But the value is not just nine, it's nine accompanied with a grad function, which is that it knows that a power operation has been taken.", 'start': 6614.811, 'duration': 7.948}, {'end': 6627.343, 'text': 'So we can now call a special method backward.', 'start': 6623.72, 'duration': 3.623}, {'end': 6636.142, 'text': "and backward, which refers to backpropagation, which we'll learn about, which basically means take the derivative.", 'start': 6628.92, 'duration': 7.222}, {'end': 6644.724, 'text': 'And so once it does that, we can now look inside xt, because we said requires grad, and find out its gradient.', 'start': 6637.382, 'duration': 7.342}, {'end': 6649.065, 'text': 'And remember the derivative of x squared is 2x.', 'start': 6646.184, 'duration': 2.881}, {'end': 6651.905, 'text': 'In this case that was 3.', 'start': 6651.125, 'duration': 0.78}, {'end': 6655.615, 'text': '2 times 3 is 6.', 'start': 6651.905, 'duration': 3.71}, {'end': 6660.399, 'text': "right? So we didn't have to figure out the derivative.", 'start': 6655.615, 'duration': 4.784}, {'end': 6665.202, 'text': 'We just call backward and then get the grad attribute to get the derivative.', 'start': 6660.459, 'duration': 4.743}, {'end': 6669.385, 'text': "So that's how easy it is to do calculus in PyTorch.", 'start': 6666.043, 'duration': 3.342}, {'end': 6679.012, 'text': 'So what you need to know about calculus is not how to take a derivative, but what it means.', 'start': 6670.046, 'duration': 8.966}, {'end': 6684.917, 'text': "And what it means is it's a slope at some point.", 'start': 6679.713, 'duration': 5.204}], 'summary': 'Using pytorch, we can easily calculate derivatives, e.g., for f(3)=9, the derivative is 6.', 'duration': 91.578, 'max_score': 6593.339, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC46593339.jpg'}, {'end': 6873.301, 'src': 'embed', 'start': 6845.441, 'weight': 5, 'content': [{'end': 6851.25, 'text': "And in fact in this case, sorry, in this case we're assuming we're starting here and it's actually so big that it got worse and worse.", 'start': 6845.441, 'duration': 5.809}, {'end': 6860.984, 'text': "Or here's one where we start here and it's like it's not so big it gets worse and worse but it just takes a long time to bounce in and out.", 'start': 6854.154, 'duration': 6.83}, {'end': 6866.795, 'text': 'right. So picking a good learning rate is really important,', 'start': 6862.17, 'duration': 4.625}, {'end': 6873.301, 'text': "both to making sure that it's even possible to solve the problem and that it's possible to solve it in a reasonable amount of time.", 'start': 6866.795, 'duration': 6.506}], 'summary': 'Choosing a good learning rate is crucial for problem-solving and time efficiency.', 'duration': 27.86, 'max_score': 6845.441, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC46845441.jpg'}, {'end': 6988.067, 'src': 'embed', 'start': 6961.477, 'weight': 6, 'content': [{'end': 6967.482, 'text': 'add one and then I add a random number to that or add a random number to every observation.', 'start': 6961.477, 'duration': 6.005}, {'end': 6970.605, 'text': 'so I end up with a quadratic function which is a bit bumpy.', 'start': 6967.482, 'duration': 3.123}, {'end': 6977.414, 'text': 'So this is kind of like what it might look like in real life, because my speedometer kind of testing is not perfect.', 'start': 6971.025, 'duration': 6.389}, {'end': 6988.067, 'text': 'All right, so we want to create a function that estimates at any time what is the speed of the roller coaster.', 'start': 6980.7, 'duration': 7.367}], 'summary': 'Creating a function to estimate roller coaster speed based on quadratic function and imperfect testing.', 'duration': 26.59, 'max_score': 6961.477, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC46961477.jpg'}, {'end': 7206.644, 'src': 'heatmap', 'start': 7044.289, 'weight': 0.798, 'content': [{'end': 7052.811, 'text': 'So the the Arthur Samuel technique for doing this is to next up come up with a loss function, come up with a measurement of how good we are.', 'start': 7044.289, 'duration': 8.522}, {'end': 7061.333, 'text': "So if we've got some predictions that come out of our function and the targets, which are these, you know,", 'start': 7053.491, 'duration': 7.842}, {'end': 7067.474, 'text': 'actual values then we could just do the mean squared error.', 'start': 7061.333, 'duration': 6.141}, {'end': 7070.895, 'text': "Okay so here's that mean squared error we saw before.", 'start': 7068.494, 'duration': 2.401}, {'end': 7072.895, 'text': 'The difference squared and then take the mean.', 'start': 7070.935, 'duration': 1.96}, {'end': 7077.781, 'text': 'So now we need to go through our seven-step process.', 'start': 7074.98, 'duration': 2.801}, {'end': 7083.782, 'text': 'We want to come up with a set of three parameters a, b and c, which are as good as possible.', 'start': 7078.081, 'duration': 5.701}, {'end': 7087.584, 'text': 'So step one is to initialize a, b and c to random values.', 'start': 7083.803, 'duration': 3.781}, {'end': 7091.465, 'text': 'So this is how you get random values, three of them in PyTorch.', 'start': 7088.404, 'duration': 3.061}, {'end': 7095.906, 'text': "And remember we're going to be adjusting them, so we have to tell PyTorch that we want the gradients.", 'start': 7092.125, 'duration': 3.781}, {'end': 7101.936, 'text': "I'm just going to save those away so I can check them later.", 'start': 7099.975, 'duration': 1.961}, {'end': 7108.259, 'text': 'And then I calculate the predictions using that function f, which was this.', 'start': 7102.816, 'duration': 5.443}, {'end': 7117.803, 'text': "And then let's create a little function which just plots how good at this point are our predictions.", 'start': 7112.12, 'duration': 5.683}, {'end': 7124.566, 'text': 'So here is a function that prints in red our predictions and in blue our targets.', 'start': 7118.483, 'duration': 6.083}, {'end': 7126.127, 'text': 'So that looks pretty terrible.', 'start': 7125.146, 'duration': 0.981}, {'end': 7129.208, 'text': "So let's calculate the loss.", 'start': 7128.227, 'duration': 0.981}, {'end': 7132.48, 'text': 'using that mse function we wrote.', 'start': 7131.019, 'duration': 1.461}, {'end': 7135.783, 'text': 'Okay, so now we want to improve this.', 'start': 7132.5, 'duration': 3.283}, {'end': 7139.085, 'text': 'So calculate the gradients using the two steps we saw.', 'start': 7136.583, 'duration': 2.502}, {'end': 7141.027, 'text': 'Call backward and then get grad.', 'start': 7139.706, 'duration': 1.321}, {'end': 7146.891, 'text': "And this says that each of our parameters has a gradient that's negative.", 'start': 7141.947, 'duration': 4.944}, {'end': 7153.116, 'text': "Let's pick a learning rate of 10 to the minus 5.", 'start': 7149.993, 'duration': 3.123}, {'end': 7158.951, 'text': 'So we multiply that by 10 to the minus 5.', 'start': 7153.116, 'duration': 5.835}, {'end': 7160.192, 'text': 'and step the weights.', 'start': 7158.951, 'duration': 1.241}, {'end': 7167.237, 'text': 'And remember step the weights means minus equals learning rate times the gradient.', 'start': 7160.332, 'duration': 6.905}, {'end': 7171.139, 'text': "There's a wonderful trick here which I've called dot data.", 'start': 7168.097, 'duration': 3.042}, {'end': 7182.467, 'text': "The reason I've called dot data is dot data is a special attribute in PyTorch which if you use it then the gradient is not calculated.", 'start': 7171.159, 'duration': 11.308}, {'end': 7189.011, 'text': "and we certainly wouldn't want the gradient to be calculated of the actual step we're doing.", 'start': 7183.107, 'duration': 5.904}, {'end': 7195.196, 'text': 'We only want the gradient to be calculated of our function f.', 'start': 7189.112, 'duration': 6.084}, {'end': 7199.819, 'text': 'So when we step the weights we have to use this special dot data attribute.', 'start': 7195.196, 'duration': 4.623}, {'end': 7206.644, 'text': "After we do that, delete the gradients that we already had, and let's see if loss improved.", 'start': 7200.94, 'duration': 5.704}], 'summary': 'Using the arthur samuel technique, parameters are adjusted to minimize mean squared error, with gradients calculated and weights adjusted accordingly.', 'duration': 162.355, 'max_score': 7044.289, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC47044289.jpg'}, {'end': 7087.584, 'src': 'embed', 'start': 7061.333, 'weight': 7, 'content': [{'end': 7067.474, 'text': 'actual values then we could just do the mean squared error.', 'start': 7061.333, 'duration': 6.141}, {'end': 7070.895, 'text': "Okay so here's that mean squared error we saw before.", 'start': 7068.494, 'duration': 2.401}, {'end': 7072.895, 'text': 'The difference squared and then take the mean.', 'start': 7070.935, 'duration': 1.96}, {'end': 7077.781, 'text': 'So now we need to go through our seven-step process.', 'start': 7074.98, 'duration': 2.801}, {'end': 7083.782, 'text': 'We want to come up with a set of three parameters a, b and c, which are as good as possible.', 'start': 7078.081, 'duration': 5.701}, {'end': 7087.584, 'text': 'So step one is to initialize a, b and c to random values.', 'start': 7083.803, 'duration': 3.781}], 'summary': 'Using mean squared error to evaluate a seven-step parameter optimization process.', 'duration': 26.251, 'max_score': 7061.333, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC47061333.jpg'}, {'end': 7286.452, 'src': 'embed', 'start': 7255.749, 'weight': 8, 'content': [{'end': 7270.466, 'text': 'This is the Arthur Samuel technique for finding a set of parameters that continuously improves by getting feedback from the result of measuring some loss function.', 'start': 7255.749, 'duration': 14.717}, {'end': 7278.748, 'text': 'So that was kind of the key step, right? This is the gradient descent method.', 'start': 7272.165, 'duration': 6.583}, {'end': 7285.211, 'text': "So you should make sure that you kind of go back and feel super comfortable with what's happened.", 'start': 7279.188, 'duration': 6.023}, {'end': 7286.452, 'text': 'And you know.', 'start': 7285.591, 'duration': 0.861}], 'summary': 'Arthur samuel technique uses gradient descent method to continuously improve parameters based on feedback from loss function.', 'duration': 30.703, 'max_score': 7255.749, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC47255749.jpg'}, {'end': 7448.945, 'src': 'embed', 'start': 7421.639, 'weight': 9, 'content': [{'end': 7426.74, 'text': 'because learning rate times gradient is still zero when the gradient is zero for any learning rate.', 'start': 7421.639, 'duration': 5.101}, {'end': 7437.422, 'text': 'So this is why the loss function and the metric are not always the same thing.', 'start': 7428.86, 'duration': 8.562}, {'end': 7445.164, 'text': "we can't use a metric as our loss if that metric has a gradient of zero.", 'start': 7438.562, 'duration': 6.602}, {'end': 7448.945, 'text': 'So we need something different.', 'start': 7448.024, 'duration': 0.921}], 'summary': 'Loss function and metric differ when gradient is zero, necessitating an alternative approach.', 'duration': 27.306, 'max_score': 7421.639, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC47421639.jpg'}, {'end': 7516.063, 'src': 'embed', 'start': 7485.161, 'weight': 10, 'content': [{'end': 7492.21, 'text': "we've kind of we've got to the point here where we understand gradient descent.", 'start': 7485.161, 'duration': 7.049}, {'end': 7495.814, 'text': 'we kind of know how to do it with a simple loss function.', 'start': 7492.21, 'duration': 3.604}, {'end': 7504.675, 'text': "and I actually think before we start looking at the MNIST loss function, we shouldn't move on because we've got so much,", 'start': 7495.814, 'duration': 8.861}, {'end': 7506.716, 'text': 'so much assignments to do for this week already.', 'start': 7504.675, 'duration': 2.041}, {'end': 7516.063, 'text': "so we've got build your web application and we've got go step through, step through this notebook to make sure you fully understand it.", 'start': 7506.716, 'duration': 9.347}], 'summary': 'Understanding gradient descent with simple loss function, focus on current assignments.', 'duration': 30.902, 'max_score': 7485.161, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC47485161.jpg'}, {'end': 7560.894, 'src': 'embed', 'start': 7531.403, 'weight': 11, 'content': [{'end': 7536.644, 'text': "I'm sorry for that last minute change of tack there, but I think this is going to make sense.", 'start': 7531.403, 'duration': 5.241}, {'end': 7540.245, 'text': 'so I hope you have a lot of fun with your web applications.', 'start': 7536.644, 'duration': 3.601}, {'end': 7544.727, 'text': "try and think of something that's really fun, really interesting.", 'start': 7540.245, 'duration': 4.482}, {'end': 7549.708, 'text': "it doesn't have to be like important, it could just be some, you know, cute thing.", 'start': 7544.727, 'duration': 4.981}, {'end': 7552.749, 'text': "we've had students before, a student that I think.", 'start': 7549.708, 'duration': 3.041}, {'end': 7560.894, 'text': 'he said he had 16 different cousins and he created something that would classify a photo based on which of his cousins.', 'start': 7552.749, 'duration': 8.145}], 'summary': 'Create fun and interesting web applications, like classifying photos based on family members, to enjoy the process.', 'duration': 29.491, 'max_score': 7531.403, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC47531403.jpg'}], 'start': 5940.255, 'title': 'Model accuracy and gradient descent', 'summary': "Discusses the model's 95% accuracy in recognizing 3s and 7s, and introduces gradient descent, explaining stochastic gradient descent steps and the importance of learning rates in training deep learning models.", 'chapters': [{'end': 5994.94, 'start': 5940.255, 'title': 'Accuracy of model on recognizing 3s and 7s', 'summary': 'Discusses the accuracy of a model in recognizing 3s and 7s, which averages at 95%, with 91% accuracy for threes and 98% accuracy for sevens.', 'duration': 54.685, 'highlights': ["The accuracy on sevens is about ninety eight percent, and the average of those two is about ninety five percent. So here we have a model that's 95% accurate at recognizing 3s from 7s. It might surprise you that we can do that using nothing but arithmetic, right? So that's what I mean by getting a good baseline.", 'The accuracy across threes is about ninety one and a bit percent.']}, {'end': 6893.353, 'start': 5994.96, 'title': 'Gradient descent and machine learning', 'summary': 'Introduces the concept of gradient descent and machine learning, explaining the key steps of stochastic gradient descent and the use of calculus to calculate gradients, and the importance of learning rates in training deep learning models.', 'duration': 898.393, 'highlights': ['The chapter introduces the concept of gradient descent and machine learning The chapter delves into the concept of gradient descent and its application in machine learning, emphasizing its importance in training deep learning models.', 'Explaining the key steps of stochastic gradient descent The chapter outlines the key steps of stochastic gradient descent, including initializing parameters, making predictions, calculating the loss, computing gradients, and updating weights iteratively.', 'The use of calculus to calculate gradients The chapter highlights the use of calculus, particularly in calculating gradients and finding the slope of the function, demonstrating the application of automatic differentiation in PyTorch.', 'The importance of learning rates in training deep learning models The chapter emphasizes the significance of choosing appropriate learning rates to ensure the effectiveness and efficiency of solving problems using gradient descent, emphasizing the importance of learning about picking learning rates in the course.']}, {'end': 7199.819, 'start': 6895.054, 'title': 'Roller coaster speed estimation', 'summary': 'Discusses the process of estimating the speed of a roller coaster using a quadratic function and the arthur samuels technique, employing a mean squared error loss function and a seven-step process to optimize the parameters a, b, and c.', 'duration': 304.765, 'highlights': ['The chapter discusses the process of estimating the speed of a roller coaster using a quadratic function and the Arthur Samuels technique. The chapter focuses on estimating the speed of a roller coaster using a quadratic function and the Arthur Samuels technique for machine learning.', 'Employing a mean squared error loss function and a seven-step process to optimize the parameters a, b, and c. The chapter utilizes a mean squared error loss function and a seven-step process to optimize the parameters a, b, and c for estimating the roller coaster speed.', 'Explaining the process of initializing parameters a, b, and c to random values and calculating the predictions using the function f. The chapter explains the process of initializing parameters a, b, and c to random values and calculating the predictions using the function f for roller coaster speed estimation.']}, {'end': 7581.665, 'start': 7200.94, 'title': 'Gradient descent and loss functions', 'summary': 'Introduces the arthur samuel technique for continuously improving parameters through gradient descent, highlighting the challenge of using accuracy as a loss function and the need to find a suitable alternative, while emphasizing the importance of understanding the concept before moving on.', 'duration': 380.725, 'highlights': ['The Arthur Samuel technique aims to continuously improve parameters using feedback from measuring a loss function, with the plot of loss significantly improving from 5400 to a much better value through iterative iterations.', 'The challenge arises in using accuracy as a loss function, as the gradient may be zero at many places, hindering parameter changes, thereby necessitating the need for a different function with a non-zero gradient that improves as accuracy does.', 'The importance of understanding gradient descent and the simple loss function is stressed, with a suggestion to halt progress to fully comprehend the concepts before moving on to more complex topics or assignments.', 'Encouragement is given to explore and develop web applications, emphasizing creativity and fun, with examples of previous student projects given, and a recommendation to explore IPyWidgets capabilities.']}], 'duration': 1641.41, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/5L3Ao5KuCC4/pics/5L3Ao5KuCC45940255.jpg', 'highlights': ['The model achieves 95% accuracy in recognizing 3s and 7s.', 'The accuracy on sevens is about 98%, and on threes is about 91%.', 'The chapter introduces gradient descent and its application in machine learning.', 'Stochastic gradient descent steps are outlined, including initializing parameters, making predictions, calculating the loss, computing gradients, and updating weights iteratively.', 'The use of calculus to calculate gradients and the application of automatic differentiation in PyTorch are highlighted.', 'The importance of learning rates in training deep learning models is emphasized.', 'The chapter focuses on estimating the speed of a roller coaster using a quadratic function and the Arthur Samuels technique for machine learning.', 'A mean squared error loss function and a seven-step process are utilized to optimize the parameters for estimating the roller coaster speed.', 'The Arthur Samuel technique aims to continuously improve parameters using feedback from measuring a loss function.', 'The challenge arises in using accuracy as a loss function, necessitating the need for a different function with a non-zero gradient.', 'Understanding gradient descent and the simple loss function is stressed before moving on to more complex topics or assignments.', 'Encouragement is given to explore and develop web applications, emphasizing creativity and fun.']}], 'highlights': ['The chapter covers model deployment and the math behind training a neural network.', 'Chapter four is focused on the technical foundations of deep learning.', 'Chapter three focuses on the ethical aspects of deep learning.', 'The random resize crop approach is the most common method of image resizing and data augmentation, grabbing different parts of the image each time and zooming into them, reducing overfitting and increasing diversity of the training data.', 'Org transforms function provides a variety of batch transformations for data augmentation, including contrast and brightness adjustments, perspective warping, and rotation, enhancing the diversity of training data and enabling GPU-accelerated transformations for efficient processing.', "The chapter emphasizes the trade-offs of different image resizing methods, such as squish, stretch, and pad, discussing their efficiency, waste of computation, and potential impact on the neural net's ability to recognize objects, providing practical insights into their application and limitations.", 'FastAI automatically avoids doing data augmentation on the validation set, ensuring that all org transforms are only applied to the training set, except for random resize crop.', "The predict function returns a tensor with activations for teddy bear, grizzly bear, and black bear classes, providing insights into the model's confidence for each class.", 'The chapter demonstrates the creation of a custom GUI inside Jupyter Notebook using a minimal amount of code, showcasing the flexibility and ease of implementation.', 'Deployment of complete application in Jupyter Notebook, usage of FastAI2, IPython widgets, and Voila for prototyping interactive applications.', 'Voila and Binder provide a way for data scientists to convert their notebooks into interactive GUIs and deploy them as publicly accessible web applications.', 'The importance of examining training data to avoid model bias is crucial for algorithm training.', 'The need for real-world reflective test data is emphasized for accurate model evaluation.', 'Gathering a gold standard test set with input from dermatologists is recommended for validation purposes.', 'The importance of being cautious and gathering diverse data for algorithm training and deployment is emphasized.', 'The chapter provides a careful deployment strategy, including manual verification, time and geography limited deployment, and gradual scaling.', 'Good reporting systems are crucial for successful model deployment.', 'Incremental learning is discussed as a method for adapting to domain shift through continued model training.', 'The risks of feedback loops in model deployment are highlighted, emphasizing the potential amplification of biases and the need for careful oversight.', 'The MNIST sample dataset was used to demonstrate the first computer system for scalable recognition of handwritten digits and later used to process 10% of the checks in the US.', "Creating a baseline 'pixel similarity' approach for classification, which involves taking the average of pixels for threes and sevens, is introduced as a simple model for classification.", 'Converting images into arrays and tensors using the Python imaging library (PIL) and NumPy is discussed, along with the benefits of using PyTorch tensors for GPU computation.', 'Using list comprehension to convert a list of images into tensors, allowing for efficient manipulation and analysis of the data.', 'Demonstrating the process of converting images into tensors, stacking them to create a 3D cube of images, and converting them into floating point values, providing valuable insights into data preprocessing and representation in PyTorch.', 'Emphasizing the significance of starting with a reasonable baseline before building more complex models, showcasing the practical approach to model evaluation and development.', "Explaining the concept of rank and dimension in tensors, highlighting the determination of rank by the length of its shape and the interchangeability of the terms 'axis' and 'dimension'.", 'Detailing the methods for computing distance using L1 norm and L2 norm, emphasizing the importance of transforming differences into positive numbers and providing practical examples to demonstrate the calculation of distance using absolute value and square root methods.', 'The concept of broadcasting is explained as a powerful tool for efficient computation and speed improvements, enabling the comparison of entire sets of data without the need for loops, resulting in significant performance gains on the GPU.', "The process of evaluating the model's performance on a validation set and comparing images with ideal digits using a distance function is highlighted, emphasizing the importance of assessing the model's accuracy on unseen data.", 'The model achieves 95% accuracy in recognizing 3s and 7s.', 'The accuracy on sevens is about 98%, and on threes is about 91%.', 'The chapter introduces gradient descent and its application in machine learning.', 'Stochastic gradient descent steps are outlined, including initializing parameters, making predictions, calculating the loss, computing gradients, and updating weights iteratively.', 'The use of calculus to calculate gradients and the application of automatic differentiation in PyTorch are highlighted.', 'The importance of learning rates in training deep learning models is emphasized.']}