diff --git a/2-Symbolic/README.md b/2-Symbolic/README.md index 9205b6a4..59968c8e 100644 --- a/2-Symbolic/README.md +++ b/2-Symbolic/README.md @@ -228,7 +228,7 @@ Nowadays, AI is often considered to be a synonym for *Machine Learning* or *Neur ## 🚀 Challenge -In the three notebooks associated with this lesson, there are challenges at the end - pick one, and try to solve it! +In the Family Ontology notebook associated to this lesson, there is an opportunity to experiment with other family relations. Try to discover new connections between people in the family tree. ## [Post-lecture quiz](https://black-ground-0cc93280f.1.azurestaticapps.net/quiz/4) diff --git a/3-NeuralNetworks/04-OwnFramework/README.md b/3-NeuralNetworks/04-OwnFramework/README.md index 89116b28..d2846e01 100644 --- a/3-NeuralNetworks/04-OwnFramework/README.md +++ b/3-NeuralNetworks/04-OwnFramework/README.md @@ -1,14 +1,16 @@ # Introduction to Neural Networks. Multi-Layered Perceptron -In the previous section, we have learnt about simplest neural network model - one-layered perceptron. It was a liner two-class classification model. +In the previous section, you learned about the simplest neural network model - one-layered perceptron, a linear two-class classification model. -In this section we will extend this model into more flexible framework, allowing us to: +In this section we will extend this model into a more flexible framework, allowing us to: * perform **multi-class classification** in addition to two-class * solve **regression problems** in addition to classification * separate classes that are not linearly separable -We will also develop our own modular framework in Python that will allows us to construct different neural network architectures. +We will also develop our own modular framework in Python that will allow us to construct different neural network architectures. + +## [Pre-lecture quiz](https://black-ground-0cc93280f.1.azurestaticapps.net/quiz/7) ## Formalization of Machine Learning @@ -23,7 +25,7 @@ For one-level perceptron, function *f* was defined as a linear function *f(x)=wx In the definition of *f* above, *w* and *b* are called **parameters** θ=⟨*w,b*⟩. Given the dataset ⟨**X**,**Y**⟩, we can compute an overall error on the whole dataset as a function of parameters θ. -**The goal of neural network training is to minimize the error by varying parameters θ** +> ✅ **The goal of neural network training is to minimize the error by varying parameters θ** ## Gradient Descent Optimization @@ -38,32 +40,45 @@ During training, the optimization steps are supposed to be calculated considerin ## Multi-Layered Perceptrons and Back Propagation -One-layer network, as we have seen above, is capable of classifying linearly separable classes. To build reacher model, we can combine several layers of the network. Mathematically it would just mean that the function *f* would have more complex form, and will be computed in several steps: +One-layer network, as we have seen above, is capable of classifying linearly separable classes. To build a richer model, we can combine several layers of the network. Mathematically it would mean that the function *f* would have a more complex form, and will be computed in several steps: * z1=w1x+b1 * z2=w2α(z1)+b2 * f = σ(z2) Here, α is a **non-linear activation function**, σ is a softmax function, and parameters θ=<*w1,b1,w2,b2*>. -The gradient descent algorithm would remain the same, but it would be more difficult to calculate gradients. Given the - chain differentiation rule, we can calculate derivatives as: +The gradient descent algorithm would remain the same, but it would be more difficult to calculate gradients. Given the chain differentiation rule, we can calculate derivatives as: * ∂ℒ/∂w2 = (∂ℒ/∂σ)(∂σ/∂z2)(∂z2/∂w2) * ∂ℒ/∂w1 = (∂ℒ/∂σ)(∂σ/∂z2)(∂z2/∂α)(∂α/∂z1)(∂z1/∂w1) -Note that the left-most part of all those expressions is the same, and thus we can effectively calculate derivatives starting from the loss function and going "backwards" through the computational graph. Thus the method of training multi-layered perceptron is called **back propagation**. +> ✅ The chain differentiation rule is used to calculate derivatives of the loss function with respect to parameters. - +Note that the left-most part of all those expressions is the same, and thus we can effectively calculate derivatives starting from the loss function and going "backwards" through the computational graph. Thus the method of training a multi-layered perceptron is called **backpropagation**, or 'backprop'. -We will cover back prop in much more detail in our notebook example. +compute graph -## [Proceed to Notebook](OwnFramework.ipynb) +> TODO: image citation -In the accompanying notebook, we will implement our own framework for building and training multi-layered perceptrons. You will be able to see in detail how modern neural networks operate. Proceed to [OwnFramework](OwnFramework.ipynb) notebook. +> ✅ We will cover backprop in much more detail in our notebook example. -## [Lab](lab/README.md) +## Conclusion -In this lesson, we have our own neural network library, and we have used for a simple two-dimensional classification task. In this lab, you are asked to use this framework to solve MNIST handwritten digit classification. +In this lesson, we have built our own neural network library, and we have used it for a simple two-dimensional classification task. + +## 🚀 Challenge + +In the accompanying notebook, you will implement your own framework for building and training multi-layered perceptrons. You will be able to see in detail how modern neural networks operate. Proceed to the [OwnFramework](OwnFramework.ipynb) notebook and work through it + +## [Post-lecture quiz](https://black-ground-0cc93280f.1.azurestaticapps.net/quiz/8) + +## Review & Self Study + +Backpropagation is a common algorithm used in AI and ML, worth studying [in more detail](https://wikipedia.org/wiki/Backpropagation) + +## [Assignment](lab/README.md) + +In this lab, you are asked to use the framework you constructed in this lesson to solve MNIST handwritten digit classification. * [Instructions](lab/README.md) * [Notebook](lab/MyFW_MNIST.ipynb) \ No newline at end of file diff --git a/README.md b/README.md index 5ca6bce2..b4d7e408 100644 --- a/README.md +++ b/README.md @@ -139,13 +139,13 @@ We have chosen two pedagogical tenets while building this curriculum: ensuring t By ensuring that the content aligns with projects, the process is made more engaging for students and retention of concepts will be augmented. In addition, a low-stakes quiz before a class sets the intention of the student towards learning a topic, while a second quiz after class ensures further retention. This curriculum was designed to be flexible and fun and can be taken in whole or in part. The projects start small and become increasingly complex by the end of the 12 week cycle. -> Find our [Code of Conduct](etc/CODE_OF_CONDUCT.md), [Contributing](etc/CONTRIBUTING.md), and [Translation](etc/TRANSLATIONS.md) guidelines. Find our [Support Documentation here[(etc/SUPPORT.md). We welcome your constructive feedback! +> Find our [Code of Conduct](etc/CODE_OF_CONDUCT.md), [Contributing](etc/CONTRIBUTING.md), and [Translation](etc/TRANSLATIONS.md) guidelines. Find our [Support Documentation here](etc/SUPPORT.md) and [security information here](etc/SECURITY.md). We welcome your constructive feedback! > **A note about quizzes**: All quizzes are contained [in this app](https://black-ground-0cc93280f.1.azurestaticapps.net/), for 50 total quizzes of three questions each. They are linked from within the lessons but the quiz app can be run locally; follow the instruction in the `etc/quiz-app` folder. ## Offline access -You can run this documentation offline by using [Docsify](https://docsify.js.org/#/). Fork this repo, [install Docsify](https://docsify.js.org/#/quickstart) on your local machine, and then in the root folder of this repo, type `docsify serve`. The website will be served on port 3000 on your localhost: `localhost:3000`. +You can run this documentation offline by using [Docsify](https://docsify.js.org/#/). Fork this repo, [install Docsify](https://docsify.js.org/#/quickstart) on your local machine, and then in the `etc/docsify` folder of this repo, type `docsify serve`. The website will be served on port 3000 on your localhost: `localhost:3000`. ## Help Wanted! diff --git a/SECURITY.md b/etc/SECURITY.md similarity index 100% rename from SECURITY.md rename to etc/SECURITY.md diff --git a/.nojekyll b/etc/docsify/.nojekyll similarity index 100% rename from .nojekyll rename to etc/docsify/.nojekyll diff --git a/docs/_sidebar.md b/etc/docsify/docs/_sidebar.md similarity index 100% rename from docs/_sidebar.md rename to etc/docsify/docs/_sidebar.md diff --git a/docsifytopdf.js b/etc/docsify/docsifytopdf.js similarity index 100% rename from docsifytopdf.js rename to etc/docsify/docsifytopdf.js diff --git a/index.html b/etc/docsify/index.html similarity index 85% rename from index.html rename to etc/docsify/index.html index 55a0db8a..8ae047d1 100644 --- a/index.html +++ b/etc/docsify/index.html @@ -18,7 +18,9 @@ window.$docsify = { name: 'AI for Beginners', repo: 'https://github.com/Microsoft/AI-For-Beginners', - relativePath: true + relativePath: false, + basePath: 'https://raw.githubusercontent.com/microsoft/ai-for-beginners/main/', + auto2top: true } diff --git a/package-lock.json b/etc/docsify/package-lock.json similarity index 100% rename from package-lock.json rename to etc/docsify/package-lock.json diff --git a/package.json b/etc/docsify/package.json similarity index 100% rename from package.json rename to etc/docsify/package.json diff --git a/pdf/readme.pdf b/etc/pdf/readme.pdf similarity index 100% rename from pdf/readme.pdf rename to etc/pdf/readme.pdf diff --git a/etc/quiz-app/package-lock.json b/etc/quiz-app/package-lock.json index df1e6b8f..dff6f697 100644 --- a/etc/quiz-app/package-lock.json +++ b/etc/quiz-app/package-lock.json @@ -2915,9 +2915,9 @@ } }, "node_modules/async": { - "version": "2.6.3", - "resolved": "https://registry.npmjs.org/async/-/async-2.6.3.tgz", - "integrity": "sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg==", + "version": "2.6.4", + "resolved": "https://registry.npmjs.org/async/-/async-2.6.4.tgz", + "integrity": "sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA==", "dev": true, "dependencies": { "lodash": "^4.17.14" @@ -17010,9 +17010,9 @@ "dev": true }, "async": { - "version": "2.6.3", - "resolved": "https://registry.npmjs.org/async/-/async-2.6.3.tgz", - "integrity": "sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg==", + "version": "2.6.4", + "resolved": "https://registry.npmjs.org/async/-/async-2.6.4.tgz", + "integrity": "sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA==", "dev": true, "requires": { "lodash": "^4.17.14"