How you (yes, you!) can write a Polars Plugin
summary
Claims no prior Rust needed and reproduces a Python numeric map in minutes; workflow uses the cookie cutter template, pip install polars and maturin, write a little Rust, register the function, and run `maturin develop`. Examples include a Pig‑Latin string plugin, an ABS numeric plugin made generic across ints/floats, a snowball stemmer via the rust‑stemmers crate, and a cumulative‑resetting sum (threshold 5) that compiles and runs, preserves nulls unless you handle them, and requires is_elementwise=false to respect groups.
AI-written summary · about
chapters (15)
- 0:00Introduction
- 2:36First Polars plugin project
- 7:14Pig Latin plugin example
- 13:59Plugin registration and API
- 19:12Absolute value plugin
- 23:27Null values and Polars internals
- 35:57Generic plugins over data types
- 44:49Output types for lazy execution
- 51:20Advanced crates.io functionality
- 1:05:22Live coding cumulative resetting sum
- 1:09:46Keyword arguments in plugins
- 1:14:27Dependency management and size
- 1:17:56Live coding success stories
- 1:20:43Group-by context and optimizations
- 1:23:58Q&A
related talks
01h 16mPower up your Polars code with Polars extention
49mKeynote on Polars Plugins
01h 32mAn Introduction to Polars
25mIntegrating Rust with Python...
38mExpressive and fast dataframes in Python with polars
28mExpressive & fast dataframes in Python with polars
58mFrom Pandas to Polars Upgrading Your Data Workflow
26mWe rewrote tsfresh in Polars and why you should too
