<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Ouail Mohammed Oucherif on Medium]]></title>
        <description><![CDATA[Stories by Ouail Mohammed Oucherif on Medium]]></description>
        <link>https://medium.com/@m.ouail.oucherif?source=rss-ca181863d96d------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*5hWSqPGeFNqFfKtMKssO5Q.jpeg</url>
            <title>Stories by Ouail Mohammed Oucherif on Medium</title>
            <link>https://medium.com/@m.ouail.oucherif?source=rss-ca181863d96d------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 01:53:06 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@m.ouail.oucherif/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Basics to Breakthroughs: Exploring Deep RL’s New Frontiers]]></title>
            <link>https://medium.com/@m.ouail.oucherif/basics-to-breakthroughs-exploring-deep-rls-new-frontiers-6fac7cbf1ff2?source=rss-ca181863d96d------2</link>
            <guid isPermaLink="false">https://medium.com/p/6fac7cbf1ff2</guid>
            <category><![CDATA[reinforcement-learning]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[deep-reinforcement]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[deep-learning]]></category>
            <dc:creator><![CDATA[Ouail Mohammed Oucherif]]></dc:creator>
            <pubDate>Sat, 02 Nov 2024 11:15:23 GMT</pubDate>
            <atom:updated>2024-11-02T11:15:23.716Z</atom:updated>
            <content:encoded><![CDATA[<h4>A review of <em>Deep Reinforcement Learning Hands-On, Third Edition Book By Maxim Lapan</em></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/648/1*E7U40UOO50EMmzjvV6bOiA.png" /><figcaption>Book’s cover</figcaption></figure><h3>Table of content</h3><p>· <a href="#6490">Introduction: Why This Book Matters in Today’s RL Landscape</a><br>· <a href="#afd6">Approach of the Book: A Structured Path Through RL</a><br> ∘ <a href="#f082">Part 1: Introduction to RL</a><br> ∘ <a href="#3a37">Part 2: Value-Based Methods</a><br> ∘ <a href="#b823">Part 3: Policy-Based Methods</a><br> ∘ <a href="#7eb6">Part 4: Advanced Topics</a><br> ∘ <a href="#4cca">Theory Meets Practical Implementation</a><br>· <a href="#2d9a">Comparison with Other RL Books: Where It Excels and Adds Value</a><br>· <a href="#60eb">Ideal Audience: Who Will Benefit the Most from This Book?</a><br>· <a href="#a29e">A Reader’s Journey</a><br>· <a href="#d1d6">Conclusion and Recommendation</a></p><h3><a href="#0f4e">Introduction: Why This Book Matters in Today’s RL Landscape</a></h3><p>Reinforcement Learning (RL) is a subdomain of artificial intelligence focused on teaching agents to make sequential decisions in an environment with the goal of maximizing rewards over time. In this framework, agents learn to perform actions through trial and error, developing strategies to autonomously solve complex tasks. For example, an RL algorithm might control the moves of a character (the agent) in a video game (the environment), aiming to maximize the score (the reward).</p><p>From <strong><em>DeepMind’s DQN</em> </strong>surpassing human-level Atari performance to <strong><em>AlphaGo </em></strong>mastering the complex game of Go and <strong><em>OpenAI’s Five</em> </strong>defeating world champions in Dota 2, RL has proven capable of solving <strong>highly intricate tasks</strong>. Today, RL’s applications span industries from <strong>finance </strong>to <strong>healthcare </strong>and are even integral to training <strong>large language models </strong>like <em>ChatGPT</em>.</p><p>This is where <em>Deep Reinforcement Learning Hands-On, Third Edition</em> comes in. Covering everything from the basics to advanced topics like <em>MuZero</em>, reinforcement learning from human feedback (<em>RLHF</em>), and transformers, this edition provides a balanced mix of theory and practical implementation in PyTorch, meeting today’s RL trends.</p><p>In this review, I’ll share what this book offers and how it has enhanced my own journey in RL.</p><p>Let’s explore its key strengths and unique approach together !</p><h3>Approach of the Book: A Structured Path Through RL</h3><p><em>Deep Reinforcement Learning Hands-On, Third Edition</em> provides a clear, structured approach to RL, moving from <strong>fundamental concepts</strong> to <strong>advanced techniques</strong> across four parts: Introduction to RL, Value-Based Methods, Policy-Based Methods, and Advanced Topics. With <strong>every algorithm implemented from scratch in PyTorch</strong>, the book prioritizes a hands-on, transparent learning experience.</p><h4>Part 1: Introduction to RL</h4><p>The book begins with four introductory chapters covering RL basics, PyTorch essentials, and OpenAI’s Gym, making RL accessible even to beginners. This section ensures readers are comfortable with essential tools and concepts before advancing.</p><h4>Part 2: Value-Based Methods</h4><p>Next, the book introduces <strong>value-based methods</strong>, where the model learns to estimate the value of actions. It starts with tabular learning, progressing to Deep Q-Networks (DQNs) and their advanced versions, following the historical development of these algorithms. A standout chapter here covers essential <strong>techniques for speeding up RL algorithms</strong> for real-world applications.</p><h4>Part 3: Policy-Based Methods</h4><p>The book then explores <strong>policy-based methods</strong>, where the model learns an action-taking strategy directly. Starting from REINFORCE, it builds to A2C and A3C, applying these to diverse environments. This section also follows the chronological development of RL research, showing the evolution of policy-based techniques.</p><h4>Part 4: Advanced Topics</h4><p>In the final part, the book covers cutting-edge RL topics, including Proximal Policy Optimization (PPO), advanced exploration methods, RL from human feedback, model-based methods like MuZero, and applications in multi-agent environments. These topics represent the latest advancements in RL and their applications in complex settings.</p><h4>Theory Meets Practical Implementation</h4><p>What sets this book apart is its emphasis on practical coding. With each algorithm built from scratch in PyTorch, the book’s GitHub repository offers clean code, emphasizing object-oriented programming and best practices in Python. This approach not only enhanced my understanding but also provided valuable guidance on structuring RL projects effectively.</p><p>This blend of theory, historical context, and hands-on coding makes <em>Deep Reinforcement Learning Hands-On, Third Edition</em> an excellent guide for mastering RL. In the next sections, I’ll compare it with other books in the field.</p><h3>Comparison with Other RL Books: Where It Excels and Adds Value</h3><p><strong>How It Stands Out</strong>: As the most recent deep RL book, <em>Deep Reinforcement Learning Hands-On, Third Edition</em> sets itself apart by integrating cutting-edge topics like <em>RLHF </em>and <em>MuZero</em>, ensuring it reflects the latest trends in the field.</p><p><strong>Balanced Theory and Practice</strong>: This book excels at marrying a strong theoretical foundation with practical implementations in <em>PyTorch</em>. Unlike many resources that either overwhelm with theory or rely heavily on API calls, this book builds every algorithm from scratch. This hands-on approach deepens understanding and reinforces learning.</p><p><strong>Reliable, Engineering-Focused Code</strong>: The well-maintained GitHub repository further enhances its value. Unlike older books with outdated or buggy code, this repository offers a modular, clean codebase designed with engineering principles in mind, making it easy to adapt for real-world applications.</p><p><strong>Broad Applicability</strong>: By covering a wide range of environments — from basic setups to advanced topics like multi-agent systems and model-based RL — this book equips readers with a comprehensive toolkit to apply their knowledge across various scenarios.</p><p>With this unique balance, the book caters well to a particular audience.</p><h3>Ideal Audience: Who Will Benefit the Most from This Book?</h3><p>This book is designed to cater to a diverse audience, making it a worthwhile resource for:</p><ul><li><strong>Beginners in Machine Learning</strong>: If you’re new to the field, the clear explanations and structured approach will help you grasp foundational concepts in deep reinforcement learning.</li><li><strong>Experienced Practitioners</strong>: For those already familiar with machine learning, the book offers practical examples that can deepen your understanding of advanced RL techniques.</li><li><strong>Academics and Researchers</strong>: Educators and researchers can benefit from its comprehensive coverage of current trends in RL, including topics like <em>RLHF </em>and <em>MuZero</em>.</li></ul><p>Overall, the book is ideal for machine learning engineers, software developers, and data scientists looking to apply deep reinforcement learning in real-world scenarios. It assumes a basic familiarity with Python, calculus, and machine learning concepts, making it accessible yet insightful for a range of readers.</p><p>Let us now see the book from my perspective</p><h3>A Reader’s Journey</h3><p>Having a background in machine learning and deep learning, primarily focused on computer vision, I was eager to expand my knowledge into what I believe is one of the most exciting fields in AI right now: reinforcement learning. I explored various books and resources, but none matched the depth and clarity of the second edition of this book.</p><p>I started reading it last summer and dedicated many days to immersing myself in the material. I thoroughly enjoyed implementing algorithms from scratch and building fascinating agents. One of the most inspiring moments came when I successfully implemented the Rainbow DQN algorithm after studying its chapter; I was thrilled to see convergence in such a short time.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/538/1*V_G29eHGtanFhipkAtcbGQ.gif" /><figcaption>My green pong agent is winning X)</figcaption></figure><p>Another memorable experience was when I tackled the Distributed Deep Deterministic Policy Gradient (DDPG) algorithm, which is relatively complex compared to others. Witnessing my four-legged robot learn to balance its motors and maintain stability was incredibly rewarding.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/926/1*0jEvpqaMb-mEj1-X4P21uQ.gif" /><figcaption>My Mars rover exploring new ways to balance itself !</figcaption></figure><p>Recently, I had the honor of receiving early access to the third edition of the book, which includes new chapters covering the latest trends, particularly RLHF and MuZero, along with other valuable topics like advanced exploration methods.</p><p>This book has not only taught me deep reinforcement learning but has also ignited a passion for the field. I am now excited to apply my RL knowledge in future projects and explore research opportunities within this dynamic domain.</p><h3>Conclusion and Recommendation</h3><p>It is safe to say that this book is currently the best deep reinforcement learning resource in the industry. I want to extend my gratitude to <strong>Maxim Lapan </strong>for his incredible effort in engineering such a great book and also <strong>Packt</strong> for providing me with early access to review it.</p><p>Finally, I invite you to connect with me in LinkedIn for further discussion. Your journey in reinforcement learning can start here, and I am excited to hear about your experiences in learning &amp; advancing in such field !</p><p>Link to the book : <a href="https://www.packtpub.com/en-us/product/deep-reinforcement-learning-hands-on-9781835882702?type=subscription"><strong>https://www.packtpub.com/en-us/product/deep-reinforcement-learning-hands-on-9781835882702?type=subscription</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6fac7cbf1ff2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Mathematics for Machine Learning: A Comprehensive Guide]]></title>
            <link>https://medium.com/@m.ouail.oucherif/mathematics-for-machine-learning-a-comprehensive-guide-eae8ee856464?source=rss-ca181863d96d------2</link>
            <guid isPermaLink="false">https://medium.com/p/eae8ee856464</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[linear-algebra]]></category>
            <category><![CDATA[mathematics]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <dc:creator><![CDATA[Ouail Mohammed Oucherif]]></dc:creator>
            <pubDate>Tue, 30 Jul 2024 11:20:27 GMT</pubDate>
            <atom:updated>2024-07-30T11:20:27.001Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/590/1*2QZhJQi_UVHjtVGejcaABg.png" /><figcaption>Book cover of ‘Mathematics for Machine Learning’ by Marc Peter Deisenroth, A. Aldo Faisal, and Cheng Soon Ong</figcaption></figure><h3>1. Introduction</h3><ul><li>Diving deep into the mathematics behind AI is essential for mastering machine learning algorithms. Many topics can be difficult to organize and understand. <em>‘Mathematics for Machine Learning’</em> by <strong>Marc Peter Deisenroth</strong>, <strong>A. Aldo Faisal</strong>, and <strong>Cheng Soon Ong</strong> excels in providing a rigorous approach to these complex subjects. The book is available for free on the <a href="https://mml-book.github.io/">official website</a>, making it an accessible resource for those looking to deepen their understanding of machine learning mathematics.</li><li>In this article, we will explore the insights and benefits of this exceptional book, covering its approach, key chapters, and additional resources that can enhance your understanding.</li></ul><h3>Table of content :</h3><p>· <a href="#dbe0">1. Introduction</a><br>· <a href="#bc04">2. Overview of the Book</a><br>· <a href="#855d">3. Approach &amp; Chapters of the Book</a><br> ∘ <a href="#d16c">3.1 Mathematical Foundations</a><br> ∘ <a href="#727d">3.2 Central Machine Learning Problems</a><br>· <a href="#918e">4. Beneficial Resources for the Book</a><br>· <a href="#feba">5. Conclusion</a></p><h3>2. Overview of the Book</h3><p>The book authored by <strong>Marc Peter Deisenroth</strong>, <strong>A. Aldo Faisal</strong>, and <strong>Cheng Soon Ong</strong> is structured in a modular way to distinctly separate foundational mathematical concepts from their applications, addressing the key question, “What do we mean by good models?” .It identifies three major components of a machine learning system: <em>data</em>, <em>models</em>, and <em>learning</em>. A guiding principle is that good models should generalize well, performing effectively on unseen data. To address this question rigorously, the book is divided into two parts:</p><ul><li><strong>Part I</strong>: This section lays the mathematical foundations necessary for understanding machine learning, covering topics such as linear algebra, probability, and calculus.</li><li><strong>Part II</strong>: This section applies the mathematical concepts from Part I to fundamental machine learning problems: regression, dimensionality reduction, density estimation, and classification.</li></ul><p>Next part of article, we will delve into the chapters of the book and its approach, highlighting how each part contributes to a comprehensive understanding of machine learning.</p><h3>3. Approach &amp; Chapters of the Book</h3><p>As previously noted, the book is divided into two parts: the first covers the mathematical foundations essential for understanding machine learning algorithms, while the second applies these concepts to key ML algorithms .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/914/1*IDWkBKFwvlnPoYobm4Odog.png" /><figcaption>Figure 1.1: The foundations and four pillars of machine learning (Marc Peter Deisenroth, A. Aldo Faisal, and Cheng Soon Ong, 2020, p. 14).</figcaption></figure><h4>3.1 Mathematical Foundations</h4><p><strong>Linear Algebra, Matrix Decomposition, and Analytic Geometry</strong>:</p><ul><li>To effectively use data in AI models, it must be represented numerically and manipulated mathematically. <strong>Linear algebra</strong> provides the tools for representing data as vectors and matrices. To assess the similarity between vectors, <strong>analytic geometry</strong> introduces operations to measure distances and similarities, which is essential for making predictions (Chapter 3). Building on these concepts, <strong>matrix decomposition</strong> (Chapter 4) allows for intuitive data interpretation and enhances learning efficiency in machine learning.</li></ul><p><strong>Probability &amp; statistics :</strong></p><ul><li>In machine learning, data is often seen as noisy snapshots of an underlying truth. To uncover the true signal amidst this noise, we need methods to measure and manage noise and uncertainty using Probability theory&amp; statistics <strong>.</strong></li><li>Probabilistic models address this by treating predictions as outcomes with associated probabilities. This approach allows us to quantify our confidence in predictions and handle uncertainty more effectively.</li></ul><p><strong>Vector calculus &amp; optimization :</strong></p><ul><li>To train machine learning models, we often adjust parameters to improve performance. This process relies on gradients, which show us the direction to search for the best solution. Chapter 5 covers the basics of gradients using vector calculus, and Chapter 7 builds on this by applying these concepts to optimization for finding the best parameters.</li></ul><h4>3.2 Central Machine Learning Problems</h4><p>The first part of the book covered the fundamental mathematics essential for understanding machine learning. With this foundation, the second part introduces four key pillars of machine learning, applying the mathematical concepts we’ve learned to discuss and explore these core areas</p><p><strong>3.2.1 When Models Meet Data:</strong></p><p>Chapter 8, “When Models Meet Data,” serves as a crucial link between rigorous mathematical concepts and theory with practical insights and machine learning algorithms. This chapter covers many important concepts that link the basis of machine learning algorithms: “model, data, and learning” in a mathematical way:</p><ul><li><strong>Empirical Risk Minimization</strong>: This section focuses on defining a hypothesis class, evaluating model performance using a loss function, and applying cross-validation techniques to ensure that the models generalize effectively to new, unseen data.</li><li><strong>Parameter Estimation</strong>: This part discusses methods for estimating model parameters, specifically through Maximum Likelihood Estimation (MLE) and Maximum A Posteriori (MAP). It addresses challenges such as overfitting and underfitting by providing strategies for accurate parameter estimation.</li><li><strong>Probabilistic Models</strong>: This section introduces Bayesian inference techniques for predicting outcomes and quantifying uncertainty. It also covers Latent-Variable Models .</li><li><strong>Graphical Models</strong>: This part explains how to represent probabilistic models using graphical structures. It also covers the concept of d-separation to understand conditional independence between variables, aiding in the interpretation and analysis of complex probabilistic relationships.</li><li><strong>Model Selection</strong>: This section covers various methods for choosing the best model from a set of candidates. It includes techniques such as nested cross-validation for tuning hyperparameters and Bayesian model selection for comparing models based on their fit to the data and their complexity.</li></ul><p><strong>3.2.2 Regression :</strong></p><p>This chapter adopts a probabilistic approach and explicitly models the noise using a Gaussian likelihood function. It builds upon this assumption with parameter estimation via maximum likelihood estimation (MLE) and maximum a posteriori (MAP)and discusses Bayesian linear regression. The chapter concludes with a new geometric intuition of MLE being a projection. Also , this chapter discuses in the end generalized linear models such as Gaussian process and deep learning.</p><p><strong>3.2.3 Dimensionality reduction via</strong> <strong>PCA :</strong></p><p>Dimensionality reduction generally exploits a property of high-dimensional data (e.g., images). Using PCA, we aim to find projections of data points that are as similar to the original data points as possible, but with significantly lower intrinsic dimensions. The chapter provides two approaches to get the same solution and finally adds a probabilistic flavor to the algorithm (probabilistic PCA).</p><p><strong>3.2.4 Density estimation via GMM :</strong></p><p>In density estimation, we represent the data compactly using a density from a parametric family, such as a Gaussian or Beta distribution. The chapter explores a more expressive family of distributions for density estimation: gaussian mixture models, and discusses the Expectation-Maximization (EM) algorithm.</p><p><strong>3.2.5 Classification via SVM :</strong></p><p>In many situations, we want our machine learning algorithm to predict one of several discrete outcomes; this is classification. Using support vector machines (SVM), we can classify data with simple linear boundaries or complex high-dimensional projection methods called kernel methods using the kernel-trick. The chapter discusses this algorithm in a geometric and mathematically rigorous way and concludes with kernelized SVM.</p><h3>4. Beneficial Resources for the Book</h3><p>In this section, I’ll share a selection of resources that have been particularly helpful in deepening my understanding of the concepts covered in “Mathematics for Machine Learning” book:</p><p><strong>Probability &amp; Statistics for Data Science by Carlos Fernandez-Granda :</strong></p><ul><li><strong>Link:</strong> <a href="https://www.youtube.com/watch?v=rm9SYX4MDu0&amp;list=PLBEf5mJtE6KuZ5NBQMuWIMsiOOrV9ibzm">Playlist</a></li><li><strong>Description:</strong> This playlist offers a rigorous approach to studying probability. Mr Carlos Fernandez-Granda provides valuable insights into the intuition behind each concept, which has significantly enhanced my probabilistic reasoning skills.</li></ul><p><strong>Bloomberg’s FOUNDATIONS OF MACHINE LEARNING:</strong></p><ul><li><strong>Link:</strong> <a href="https://bloomberg.github.io/foml/#lectures">Playlist</a></li><li><strong>Description:</strong> This resource covers various machine learning algorithms with a strong emphasis on statistical methods and probability models. It is particularly notable for its rigorous mathematical definitions, including theorems and proofs. It has helped me better understand mathematical concepts such as Lagrange duality used in SVMs.</li></ul><p><strong>Tübingen Machine Learning YouTube Channel :</strong></p><ul><li><strong>Link:</strong> <a href="https://www.youtube.com/c/T%C3%BCbingenML">Channel</a></li><li><strong>Description:</strong> This channel offers comprehensive playlists on different machine learning and deep learning algorithms, approached from a mathematical perspective. It is an extremely valuable resource for understanding the mathematical underpinnings of various ML and DL techniques.</li></ul><p><strong>3Blue1Brown YouTube Channel :</strong></p><ul><li><strong>Link:</strong> <a href="https://www.youtube.com/@3blue1brown">Channel</a></li><li><strong>Description:</strong> A must-watch for any math enthusiast, this channel presents mathematical concepts through engaging visualizations, making complex ideas more accessible and intuitive.</li></ul><h3>5. Conclusion</h3><ul><li>I extend my heartfelt thanks to <strong>Marc Peter Deisenroth</strong>, <strong>A. Aldo Faisal</strong>, and <strong>Cheng Soon Ong</strong> for their invaluable contribution through <em>‘Mathematics for Machine Learning’</em> book. Their work bridges the gap between theory and practice, providing a comprehensive guide to the mathematical foundations of machine learning.</li><li>For those interested in deepening their understanding, I highly recommend reading this book, which is available for free on the official website: <a href="https://mml-book.com/">Mathematics for Machine Learning</a>. Additionally, the resources listed in this article offer further insights and practical applications to enhance learning journey , thanks for reading <em>.</em></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eae8ee856464" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>