Ammar Yasser Profile picture
I tweet about data science. Trying to make the road to machine learning mastery more navigable to others.
GollyG 💙 Profile picture David Gloyn-Cox  🐉 Profile picture Learning in Public - Coding - DataSci Profile picture 3 subscribed
Apr 27, 2022 10 tweets 4 min read
Deep Learning Mini-Tutorial

▶️The Power of Non-Saturating Activation Functions

One of the reasons deep learning was largely abandoned in the early 2000s is the problem of vanishing gradients.

So, what is the vanishing gradients problem? In a nutshell, a deep network is trained by iteratively updating its parameters.

The update that every parameter receives depends mainly on two things:
1. The gradient of the cost function with respect to that parameter.
2. The learning rate.
Apr 24, 2022 6 tweets 2 min read
Data Analysis Mini-Tutorial

Understanding the distribution of your data is usually a crucial step in the data analysis process.

Having normally distributed (bell-shaped) data makes it a lot easier for most machine learning algorithms to detect patterns. Unfortunately, it's never that easy.

A lot of data are usually skewed, either to the right or to the left.
This is pretty common if you're dealing with financial data, for example.

This usually happens when the data contains a lot of outliers.
Apr 23, 2022 8 tweets 2 min read
Deep Learning Mini-Tutorial

When training deep neural networks, the shape of the cost function is rarely smooth or regular.

Some parts of the cost function will have a steep slope on which gradient descent can move pretty quickly. On the other hand, the cost function commonly contains valleys (flat segments) where gradient descent moves really slow.
Nov 5, 2021 10 tweets 4 min read
How to deal with overplotting in data visualization?

Overplotting happens when there are a large number of data points which results in an undetailed plot with too many overlapping points.

Overplotting makes it really difficult to interpret the plot and detect the patterns. The above code produces the following plot where there is a clear overlapping of the plotted points.

This overlapping makes it really difficult to understand the distribution patterns of the data.

Possible solutions include:
1- Sampling
2- Transparency
3- Heatmap
Nov 3, 2021 14 tweets 4 min read
Weight Initialization Strategies for Deep Neural Networks

Thread Contents:
a. Why do we need better initialization strategies?
b. Weight initialization techniques
c. Implementation in Keras Image In a previous thread, we discussed the vanishing/exploding gradient problem in DNNs, and we mentioned that the two main reasons for this problem are:
1. Improper weight initialization techniques.
2. Saturating activation functions.

Oct 16, 2021 10 tweets 2 min read
Most data scientists spend almost 80% of their time inspecting and cleaning data rather than working on their machine learning models.

But why? According to the "No Free Lunch theorem", most machine learning models have a set of built-in assumptions, and before you start training your model, you have to make sure that your data is in line with the underlying assumptions of your model.
Sep 22, 2021 8 tweets 4 min read
My Favorite Books for Machine Learning and Data Analysis

🧵In this thread, I will try to list some of the books I think every machine learning enthusiast should have. 1. Python for Data Analysis: Data Wrangling with Pandas, NumPy, and IPython (2nd edition).
By @wesmckinn

One of the best resources out there to learn Pandas, Numpy, Matplotlib, and the general workflow of data analysis.

amazon.com/Python-Data-An…
Sep 14, 2021 19 tweets 4 min read
The ABSOLUTE ESSENTIALS of Linear Regression

🧵This thread will cover:
- Intuition behind linear regression.
- Different implementations.
- Comparisons in terms of computational complexity. Introduction

A linear regression model aims to use input features to predict a target numeric value.

For example, training a linear model to predict the price of a set of features such as area, location, number of rooms, etc.
Aug 14, 2021 18 tweets 4 min read
The ABSOLUTE ESSENTIALS of Data Mismatch in Machine Learning

🧵This thread will cover the following concepts:
a. Data Distribution (explanation + examples)
b. Data Mismatch Problem In a previous thread, we discussed that we should split our data into three parts:
- Training Set
- Development Set
- Test Set
👇👇
Jul 28, 2021 8 tweets 3 min read
The ABSOLUTE ESSENTIALS in Machine Learning Series

🧵This thread will contain all of the previous and future "The ABSOLUTE ESSENTIALS" threads so that they can be accessed more easily.

It will be updated frequently.
👇👇
#MachineLearning #DataScience The ABSOLUTE ESSENTIALS of scikit-learn
Jul 26, 2021 20 tweets 5 min read
The ABSOLUTE ESSENTIALS of Bias/Variance Analysis

🧵This thread will cover the following concepts:
a. Bayes Error
b. Bias vs Variance
c. Possible Solutions

(Explanation + Examples)

#MachineLearning #DataScience 📜Introduction
- After training a ML model, it is important to assess its performance before putting it into production.
- We start by measuring the model performance on the training set to evaluate how well the model fits the training data.
Jul 25, 2021 21 tweets 5 min read
The ABSOLUTE ESSENTIALS of Splitting Data for Machine Learning

(Explanation + Scikit-learn Implementation)

🧵 Long Thread 👇👇
#MachineLearning #DataScience 📜Introduction
Why do we need to split our data?
After training the model, you want to test its performance on new data before putting it in production. In other words, you want to measure the generalization error (how well does the model generalize to new data?).
Jul 24, 2021 17 tweets 5 min read
The ABSOLUTE ESSENTIALS of scikit-learn every data scientist should know
(Introduction + Examples)

🧵Long Thread 👇👇
#MachineLearning #DataScience ✍️Introduction
- scikit-learn is one of the most famous python libraries for machine learning.
- scikit-learn allows you to easily build and train machine learning models through its simple and well designed API.
- However, I will try to simplify the API for beginners.
Jul 23, 2021 5 tweets 3 min read
I've written multiple threads on how to get started with #MachineLearning, #DeepLearning , and #DataScience in general.
check them out (Bookmark).
🧵👇👇 1⃣ #DataScience roadmap
Jul 23, 2021 12 tweets 7 min read
#python packages for #DataScience and #MachineLearning
(explanation + resources)

🧵👇 Pandas
- Pandas is probably one of the most powerful and flexible open source data analysis and manipulation tool available in any language.
- It provides a wide range of functions for data wrangling and cleaning.
resources:
1⃣ youtube.com/playlist?list=…
2⃣ Image
Jun 23, 2021 13 tweets 3 min read
The term Machine Learning sounds mysterious and confusing to a lot of people especially beginners.
In this thread, I will try to explain how does a machine learn, and why do we even need machine learning?
🧵👇 In pre-machine learning era, we had what is called "rule-based systems".
This basically means that we provide a machine with a bunch of instructions on how to perform a certain task.
For example, if we need to write a function that returns the square of a number.
Jun 22, 2021 12 tweets 2 min read
If you are planning to get into machine learning, then you are likely to use scikit-learn, one of Python's most famous libraries.
In this thread, I will try to break down scikit-learn's API which could be intimidating in the beginning.
🧵👇
#MachineLearning Estimators
- An estimator is any scikit-learn object that learns some parameters from data.
- All estimators implement "fit()" method to perform the estimation process.
- Estimators can also act as transformers or predictors.
Jun 21, 2021 13 tweets 11 min read
Data Science learning roadmap
If you are looking to get into machine learning, I would like to make your life easier by listing some of my favorite resources in this thread 🧵👇
#MachineLearning 1⃣Python is the most common language for data science (even though there are other great languages like R, C++)
This playlist by @JustinMitchel is a great way to start.
youtube.com/playlist?list=…
Jun 21, 2021 16 tweets 4 min read
Bias/Variance analysis is one of the most important concepts in machine learning as it allows you to measure and improve the performance of your model.
🧵In this thread, I will discuss the basic idea behind it, so let's dive right in.
#MachineLearning #ArtificialIntelligence 1⃣Bias (Underfitting)
What is bias?
In simple terms, bias is the difference between the model predictions and the actual values.
So if a model has a high bias, it means it has underfitted the training data. In other words, the model has a high training set error.
Jun 19, 2021 6 tweets 2 min read
Feature Scaling is one of the most important transformations you need to apply to your data before feeding it to your machine learning model.
🧵thread 👇 - Feature scaling refers to the concept of normalizing the range of input features so that they have similar scales.
- Most machine learning algorithms do not work well when the input numerical attributes have very different scales. Image