pandas vs Polars DataFrames? 👨🏻‍🍳 #python

preview_player
Показать описание
Here's Marco Gorelli's take on why lazy execution matters 🎂 🎂 🎂

So with pandas, everything happens eagerly. You give the library some instructions, and it evaluates your instructions the moment you give them.

With Polars, there's an option to give it some instructions, it can wait a bit, and then do them all together in the most optimal way that it can detect.

If I was to tell you to cook me a recipe 👨‍🍳
...and I gave you the steps one at a time
...and for each step, you have to go out and buy the ingredients that you need for that step

^ This is going to be a pretty inefficient way of making a cake

But if I can give you the recipe beforehand:
...you can buy all the ingredients together
...you can maybe do 2 steps at the same time

^ This is going to be a much nicer cooking experience 😊
Рекомендации по теме
visit shbcf.ru