Why Logarithms Are So Important In Machine Learning
Photo by Tim Foster on Unsplash

If you are living on the 10th floor of a building, are you going to take the stairs or use the elevator?

The goal in both cases is the same: You want to go back to your apartment after a long day at work.

Of course, taking the stairs is better if you are a busy person who doesn’t have time to go to the gym and wants to use the stairs as a simplified version of the cardio exercises. But, aside from that, you are more likely to take the elevator.

Let’s take another example.

Let’s say that you are trying to go to your workplace. It takes you 10 minutes by car when there are no traffic jams and 50 minutes walking.

You can choose to either drive or walk. You are still going to reach the same destination, but you want to save time. You go to work every workday and not just once in your lifetime. As a result, you may need to decide about this on a regular basis.

You want to be able to go to your work faster so that you can have more time in your day to stay with your family and friends. You want to start that side project. Read the book that you bought at the local book store. Watch the lectures that you always wanted.

Instead of spending so much of your time to go to the same destination, you want to take a car or a bus that helps you get there. This way, you have more time to do other things.

Examples of the benefits of using the logarithm

Using logarithm is the same: You need to find the parameters that minimize the loss function, which is one of the main problems that you try to solve in Machine Learning.

Let’s say that your function seems like the following:

If we find its first derivative, we will have the following expression in the end:
['Fatos Morina']
['Machine Learning', 'Data Science', 'Technology', 'Artificial Intelligence', 'Programming']