3 ms·
Espouse the benefits of polars vs pandas and ill consider it. At this point i know pandas very well and, while it had some nuances, its pretty good at what it
by boringg 3y ago
Espouse the benefits of polars vs pandas and ill consider it. At this point i know pandas very well and, while it had some nuances, its pretty good at what it does!
- seanhunter 3y agoNot the OP but I’ll give my opinion. Ultimately they are similar but polars has definitely benefited from “going second” ie seeing a successful example and how people use it and knocking off some rough edges. 1. Polars has a narrower API that seems a bit cleaner and more logical vs pandas is more maximalist. Matter of taste but https://franzdiebold.github.io/polars-cheat-sheet/Polars_cheat_sheet.pdf https://franzdiebold.github.io/polars-cheat-sheet/Polars_che... Will give you a flavour 2. Polars perf seems quite a lot better. This may not matter for your use case but if it does it does. 3. Polars supports both eager and lazy evaluation modes and you can choose whichever makes sense for your use case. I like this but sone people find lazy eval confusing to debug. 4. polars can do things like parallelization under the hood 5. Polars is less inclined to guess what you mean about things like type conversions and will instead fail and throw until you fix your code to be more explicit. Pandas is a bit more lassez faire. I guess this reflects the dev philosophy of the respective teams. Here’s someone else’s writeup with some benchmarks https://towardsdatascience.com/pandas-vs-polars-a-syntax-and-speed-comparison-5aa54e27497e https://towardsdatascience.com/pandas-vs-polars-a-syntax-and...
- boringg 3y agoThanks interesting diffs. I think functionality is the missing diff at this point. Appreciate the parallelization.