You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
From 1.31.1, Polars has a new streaming engine. In time, it will become the default engine, as it is usually faster and uses less memory. All queries that run on the in-memory engine should run on the streaming engine (please file a bug otherwise), but certain operations might not have a native streaming implementation yet (in which case they will transparently fall back to the in-memory engine).
This issue tracks the progress of adding functionality natively to the streaming engine.
The streaming engine can be used by using LazyFrame.collect(engine='streaming') or LazyFrame.sink_*(...). The physical plan can be visualized as a dot graph by using .show_graph(engine='streaming', plan_stage='physical').
From 1.31.1, Polars has a new streaming engine. In time, it will become the default engine, as it is usually faster and uses less memory. All queries that run on the in-memory engine should run on the streaming engine (please file a bug otherwise), but certain operations might not have a native streaming implementation yet (in which case they will transparently fall back to the in-memory engine).
This issue tracks the progress of adding functionality natively to the streaming engine.
The streaming engine can be used by using
LazyFrame.collect(engine='streaming')orLazyFrame.sink_*(...). The physical plan can be visualized as a dot graph by using.show_graph(engine='streaming', plan_stage='physical').Sources
scan_deltascan_icebergSinks
PartitionByKeyfor new streaming sinks #21689)LazyFrame.{sink,collect}_batches#23980)sink_batches)collect_batches)LazyFrame.sink_iceberg#26799)Out-of-core
Streaming Nodes
AsOfjoin node #26398)byparameter (Streaming implementation for grouped AsOf join #26500)headtail(feat: Add negative slice support to new-streaming engine #21001){Expr,LazyFrame}.rolling(feat: Streaming{Expr,LazyFrame}.rolling#25058)group_bycolumnLazyFrame.group_by_dynamicgroup_by=None(perf: Add streaming nativeLazyFrame.group_by_dynamic#25342)group_bycolumnrolling_{sum,std,var,...}strptimewithout format (to_time,to_datetime,to_date) (perf: Streamingstrptimewithformat=None#27056)Aggregates
.mode()expression #24459)arg_min,arg_max(perf: Lowerarg_{min,max}to streaming engine #26845)any/allcorr(perf: Streamingcovandcorr#27008)cov(perf: Streamingcovandcorr#27008)kurtosis/skew(perf: Lowerskew/kurtosisto streaming aggregations #27176)entropy(perf: Lowerentropyto streaming reductions #27174)str.joinPlan translation to streaming
shift(perf: Lower Expr.shift to streaming engine #24106).over()to group-by + join.over(mapping_strategy="group_to_rows")perf: Lower basic over() to streaming primitives #27303.over(keys)wherekeysare sorted tosorted-group-by + explode.replace()to map (small replacement dictionary) or join (large replacement dictionary)is_first_distinct(perf: Streaming is_first_distinct and unique(maintain_order=True) #27052)is_last_distinctis_uniqueis_duplicatedarg_where(perf: Lowerarg_wherenatively to streaming engine #24088)index_of(perf: Lowerindex_ofto streaming engine #26923)drop_nans/drop_nullsreshapearg_unique(perf: Lowerarg_uniquenatively to the streaming engine #24279)top_k/bottom_k(perf: Lower top-k to streaming engine #23979)cum_count,cum_sum,cum_prod,cum_min,cum_max(feat: Addcum_*as native streaming nodes #23977)diff(feat: Implement diff() in streaming engine #24189)uniquepl.concatpeak_min/peak_max(feat: Add native streaming forpeaks_{min,max}#24039)cut(perf: MakecutoutputEnumand mark as elementwise #27173)qcutrle(feat: Lowerrleto a native streaming engine node #23929)rle_id(feat: Lowerrle_idto a native streaming node #23894)samplerepeat(perf: Lower pl.repeat to streaming engine #23804)extend_constant(perf: Lower extend_constant to the streaming engine #23824)unique_counts/value_counts(feat: Lowerunique_countsandvalue_countsto streaming engine #23890)mode(perf: Native streaming.mode()expression #24459)pct_changeinterpolate(perf: Add native streaminginterpolate#27185)interpolate_byewm_{mean,std,var}(feat: Supportewm_mean()in streaming engine #25003, feat: Supportewm_var/stdin streaming engine #25109)ewm_{mean,std,var}_bygather_every(perf: Native streaminggather_every#24700)fill_null(strategy="min"/"max"/"mean")forward_fill(perf: Native streamingforward_fill#26922)backward_fill(perf: Streaming nativebackward_fill#26967)search_sortedrandomrankarg_sorthistDatatypes
Other
show_graph(feat: Show physical stage graph #22491)Add support for(RemoveprofileLazyFrame.profile()#28274)set_streaming_chunk_size