If you’re interested in Machine Learning but don’t know where to start, this article is a guide made for you! 🔥
We’ll go over the steps you need to take to start your journey in Machine Learning with Python.
Python is a great language to get started with Machine Learning, as it has a large community (many questions that you’ll have are already answered).
On top of that, it’s an easy to learn language that has a lot of resources and libraries that will help you in your projects.
So this article is for those who want to start Machine Learning. If you are not yet familiar with this field, I recommend our article that presents the fundamentals.
Now we can get started!
Install Python
First of all you have to install Python on your computer
To do this, you can download the latest version of the language from the official website.
Download the Mac or PC version according to your own computer.
Then install the program.
After the installation, you will be able to install the main Machine Learning libraries.
These libraries are NumPy, Pandas and scikit-learn.
You can install these libraries using the pip
package manager provided with Python.
To install a library using pip
, open a terminal (search Terminal on Mac or Cmd Prompt on Windows).
You can install a library like this:
pip install library_name
For example, to install NumPy :
pip install numpy
You can install several libraries at the same time by separating them with a space, like this:
pip install numpy pandas scikit-learn
Once you have installed the necessary libraries, you need to choose a programming environment (also called Code Editor).
Code Editor
It is in this environment that you will be able to code and run your Python programs.
Several options are available to you. Here are the most popular ones:
This environment will allow you to write your program in a .py
file and to execute this code from a terminal.
For example with Visual Studio Code, you can create a new file in File > New File.
When you save it, give it a name by adding the extension .py
at the end.
Then you can go to Terminal > New Terminal.
A Terminal opens in which you can launch your program with the command :
python ton_fichier.py
Otherwise you can use a simple text editor and execute your code from a terminal that you open on your computer.
The Data Scientists’ Alternative: Notebooks
A Notebook is a document that combines text, code and other types of content into a single interactive document.
Notebooks are widely used by data scientists and machine learning engineers.
They are a convenient and powerful way to organize and present code, results and explanations in a single document.
There are several types of notebooks, including Jupyter notebooks and Colab notebooks.
By the way, if your goal is to master Deep Learning - I've prepared the Action plan to Master Neural networks. for you.
7 days of free advice from an Artificial Intelligence engineer to learn how to master neural networks from scratch:
- Plan your training
- Structure your projects
- Develop your Artificial Intelligence algorithms
I have based this program on scientific facts, on approaches proven by researchers, but also on my own techniques, which I have devised as I have gained experience in the field of Deep Learning.
To access it, click here :
Now we can get back to what I was talking about earlier.
You can create and edit notebooks using an online application or development environment, such as Jupyter, Google Colab or Azure Notebooks.
The most popular option is Anaconda where you can use Jupyter Notebooks.
Notebooks, how does it work?
Notebooks work with cells.
A cell is a block of code that you can execute independently of other cells.
They are used to write and execute code, display results, add text and other content in the notebook.
There are two types of cells: code cells and text cells.
Code cells are used to write and execute code, while text cells are used to add text, equations and other content to the notebook.
To create a new cell in a notebook, you can click the “+ Code” or “+ Text” button in the toolbar at the top of the notebook.
To execute a cell, you can either click on the “Play” button in the toolbar or use the keyboard shortcut Shift+Enter. This will execute the code in the cell and display the results.
Also, if you create a variable in a cell of a notebook, you will have access to it in other cells of the same notebook.
This is because notebooks are run in a single Python interpreter, which means that all cells in the notebook share the same global environment.
The Google Colab case
You can also do Machine Learning without any installation.
But for that you will need internet.
With Google Colab you can write and run your code easily on notebooks.
Google Colab is a free online development environment that allows you to write and run code in Python.
Colab notebooks are based on Jupyter notebooks.
Like Jupyter notebooks, Colab notebooks are composed of cells that can contain code, text, equations and other types of content.
One of the main advantages of Colab notebooks is that they can be easily shared. Indeed they are stored in Google Drive and can be shared with other people through a simple link.
Several people can collaborate on the same notebook, read it, modify it and execute it.
On top of that, Colab notebooks are particularly useful for Machine Learning.
They provide access to powerful computing resources, such as GPUs and TPUs, which can greatly accelerate the process of learning ML models.
They also come with a large number of libraries commonly used in ML, such as NumPy, Pandas and scikit-learn.
So you don’t even need to install them.
This makes Colab notebooks a convenient and powerful alternative to the classic code editor.
What’s next?
Once you have set up your development environment and installed the necessary libraries, you are ready to start exploring Machine Learning with Python!
You can start by learning about different Machine Learning algorithms.
As you gain experience, you’ll be able to work on your own projects.
Inside Machine Learning provides you with free tutorials to learn Machine Learning.
Here is a set of beginner-friendly tutorial:
- Machine Learning with the Scikit-Learn library
- Deep Learning with the Keras library
- Data Science (an essential component of Machine Learning)
- The Decision Tree algorithm (one of the best known Machine Learning algorithms)
That’s the end of this article to get started in Machine Learning.
See you soon on Inside Machine Learning 😉
One last word, if you want to go further and learn about Deep Learning - I've prepared for you the Action plan to Master Neural networks. for you.
7 days of free advice from an Artificial Intelligence engineer to learn how to master neural networks from scratch:
- Plan your training
- Structure your projects
- Develop your Artificial Intelligence algorithms
I have based this program on scientific facts, on approaches proven by researchers, but also on my own techniques, which I have devised as I have gained experience in the field of Deep Learning.
To access it, click here :
I look forward to continued excellence from you in the future. I want to express my gratitude for providing this website. Your website recommendations are truly valuable.