From 04ad074611d4c4fa80853ded26b4a327cd160e43 Mon Sep 17 00:00:00 2001 From: ritchie Date: Sun, 17 Sep 2023 14:18:10 +0200 Subject: [PATCH] feaures --- crates/polars-core/src/doc/changelog/mod.rs | 8 ----- .../src/doc/changelog/v0_10_0_11.rs | 21 ------------ crates/polars-core/src/doc/changelog/v0_3.rs | 8 ----- crates/polars-core/src/doc/changelog/v0_4.rs | 9 ------ crates/polars-core/src/doc/changelog/v0_5.rs | 11 ------- crates/polars-core/src/doc/changelog/v0_6.rs | 8 ----- crates/polars-core/src/doc/changelog/v0_7.rs | 32 ------------------- crates/polars-core/src/doc/changelog/v0_8.rs | 24 -------------- crates/polars-core/src/doc/changelog/v0_9.rs | 19 ----------- crates/polars-core/src/doc/mod.rs | 2 -- crates/polars-core/src/lib.rs | 2 -- crates/polars-lazy/src/lib.rs | 7 ++++ crates/polars-plan/src/dsl/mod.rs | 1 - crates/polars-plan/src/lib.rs | 8 +++++ crates/polars/Cargo.toml | 4 +-- crates/polars/src/lib.rs | 4 +-- 16 files changed, 19 insertions(+), 149 deletions(-) delete mode 100644 crates/polars-core/src/doc/changelog/mod.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_10_0_11.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_3.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_4.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_5.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_6.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_7.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_8.rs delete mode 100644 crates/polars-core/src/doc/changelog/v0_9.rs delete mode 100644 crates/polars-core/src/doc/mod.rs diff --git a/crates/polars-core/src/doc/changelog/mod.rs b/crates/polars-core/src/doc/changelog/mod.rs deleted file mode 100644 index 40f167264afc..000000000000 --- a/crates/polars-core/src/doc/changelog/mod.rs +++ /dev/null @@ -1,8 +0,0 @@ -pub mod v0_10_0_11; -pub mod v0_3; -pub mod v0_4; -pub mod v0_5; -pub mod v0_6; -pub mod v0_7; -pub mod v0_8; -pub mod v0_9; diff --git a/crates/polars-core/src/doc/changelog/v0_10_0_11.rs b/crates/polars-core/src/doc/changelog/v0_10_0_11.rs deleted file mode 100644 index 8136f24f8f80..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_10_0_11.rs +++ /dev/null @@ -1,21 +0,0 @@ -//! # Changelog v0.10 / v0.11 -//! -//! * CSV Read IO -//! - Parallel csv reader -//! * Sample DataFrames/ Series -//! * Performance increase in take kernel -//! * Performance increase in ChunkedArray builders -//! * Join operation on multiple columns. -//! * ~3.5 x performance increase in group_by operations (measured on db-benchmark), -//! due to embarrassingly parallel grouping and better branch prediction (tight loops). -//! * Performance increase on join operation due to better branch prediction. -//! * Categorical datatype and global string cache (BETA). -//! -//! * Lazy -//! - Lot's of bug fixes in optimizer. -//! - Parallel execution of Physical plan -//! - Partition window function -//! - More simplify expression optimizations. -//! - Caching -//! - Alpha release of Aggregate pushdown optimization. -//! * Start of general Object type in ChunkedArray/DataFrames/Series diff --git a/crates/polars-core/src/doc/changelog/v0_3.rs b/crates/polars-core/src/doc/changelog/v0_3.rs deleted file mode 100644 index 738021313cdc..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_3.rs +++ /dev/null @@ -1,8 +0,0 @@ -//! # Changelog v0.3 -//! -//! * Utf8 type is nullable [#37](https://github.com/pola-rs/polars/issues/37) -//! * Support all ARROW numeric types [#40](https://github.com/pola-rs/polars/issues/40) -//! * Support all ARROW temporal types [#46](https://github.com/pola-rs/polars/issues/46) -//! * ARROW IPC Reader/ Writer [#50](https://github.com/pola-rs/polars/issues/50) -//! * Implement DoubleEndedIterator trait for ChunkedArray's [#34](https://github.com/pola-rs/polars/issues/34) -//! diff --git a/crates/polars-core/src/doc/changelog/v0_4.rs b/crates/polars-core/src/doc/changelog/v0_4.rs deleted file mode 100644 index d357526134ef..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_4.rs +++ /dev/null @@ -1,9 +0,0 @@ -//! # Changelog v0.4 -//! -//! * median aggregation added to `ChunkedArray` -//! * Arrow LargeList datatype support (and group_by aggregation into LargeList). -//! * Shift operation. -//! * Fill None operation. -//! * Buffered serialization (less memory requirements) -//! * Temporal utilities -//! diff --git a/crates/polars-core/src/doc/changelog/v0_5.rs b/crates/polars-core/src/doc/changelog/v0_5.rs deleted file mode 100644 index 7d82f3271cc0..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_5.rs +++ /dev/null @@ -1,11 +0,0 @@ -//! # Changelog v0.5 -//! -//! * `DataFrame.column` returns `Result<_>` **breaking change**. -//! * Define idiomatic way to do inplace operations on a `DataFrame` with `apply`, `try_apply` and `ChunkSet` -//! * `ChunkSet` Trait. -//! * `Groupby` aggregations can be done on a selection of multiple columns. -//! * `Groupby` operation can be done on multiple keys. -//! * `Groupby` `first` operation. -//! * `Pivot` operation. -//! * Random access to `ChunkedArray` types via `.get` and `.get_unchecked`. -//! diff --git a/crates/polars-core/src/doc/changelog/v0_6.rs b/crates/polars-core/src/doc/changelog/v0_6.rs deleted file mode 100644 index 23e38f3d2369..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_6.rs +++ /dev/null @@ -1,8 +0,0 @@ -//! # Changelog v0.6 -//! -//! * Add more distributions for random sampling. -//! * Fix float aggregations with NaNs. -//! * Comparisons are more performant. -//! * Outer join is more performant. -//! * Start with parallel iterator support for ChunkedArrays. -//! * Remove crossbeam dependency. diff --git a/crates/polars-core/src/doc/changelog/v0_7.rs b/crates/polars-core/src/doc/changelog/v0_7.rs deleted file mode 100644 index 55996f2fcaa5..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_7.rs +++ /dev/null @@ -1,32 +0,0 @@ -//! # Changelog v0.7 -//! -//! * More group by aggregations: -//! - n_unique -//! - quantile -//! - median -//! - last -//! - group indexes -//! - agg (combined aggregations) -//! * explode operation -//! * melt operation -//! * df! macro -//! * Rem trait implemented for Series and ChunkedArrays -//! * ChunkedArrays broadcasting arithmetic -//! * ChunkedArray/Series `zip_with` operation -//! * ChunkedArray/Series `new_from_index` operation -//! * laziness api initiated. -//! - Predicate pushdown optimizer -//! - Projection pushdown optimizer -//! - Type coercion optimizer -//! - Selection (filter, where clause) -//! - Projection (select foo from bar) -//! - Aggregation (group_by) -//! - all eager aggregations supported -//! - Joins -//! - WithColumn operation -//! - DSL -//! * (col, lit, lt, lt_eq, alias, etc.) -//! * arithmetic -//! * when / then /otherwise -//! * 1.3-1.7 performance increase of filter -//! * ChunkedArray/ Series creation speedup: No nulls: 10X speedup, Nulls: 1.1-2.2x speedup. diff --git a/crates/polars-core/src/doc/changelog/v0_8.rs b/crates/polars-core/src/doc/changelog/v0_8.rs deleted file mode 100644 index 3d7c6fdabb8f..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_8.rs +++ /dev/null @@ -1,24 +0,0 @@ -//! # Changelog v0.8 -//! -//! * Upgrade to Arrow 2.0 -//! * Add quantile aggregation to `ChunkedArray` -//! * Option to stop reading CSV after n rows. -//! * Read parquet file in a single batch reducing reading time. -//! * Faster kernel for zip_with and set_with operation -//! * String utilities -//! - Utf8Chunked::str_lengths method -//! - Utf8Chunked::contains method -//! - Utf8Chunked::replace method -//! - Utf8Chunked::replace_all method -//! * Temporal utilities -//! - Utf8Chunked to dat32 / datetime -//! * Lazy -//! - fill_null expression -//! - shift expression -//! - Series aggregations -//! - aggregations on DataFrame level -//! - aggregate to largelist -//! - a lot of bugs fixed in optimizers -//! - UDF's / closures in lazy dsl -//! - DataFrame reverse operation -//! diff --git a/crates/polars-core/src/doc/changelog/v0_9.rs b/crates/polars-core/src/doc/changelog/v0_9.rs deleted file mode 100644 index f0ece2b79bcf..000000000000 --- a/crates/polars-core/src/doc/changelog/v0_9.rs +++ /dev/null @@ -1,19 +0,0 @@ -//! # Changelog v0.9 -//! -//! * CSV Read IO -//! - large performance increase -//! - skip_rows -//! - ignore parser errors -//! * Overall performance increase by using aHash in favor of FNV. -//! * Groupby floating point keys -//! * DataFrame operations -//! - drop_nulls -//! - drop duplicate rows -//! * Temporal handling -//! * Lazy -//! - a lot of bug fixes in the optimizer -//! - start of optimizer framework -//! - start of simplify expression optimizer -//! - csv scan -//! - various operations -//! * Start of general Object type in ChunkedArray/DataFrames/Series diff --git a/crates/polars-core/src/doc/mod.rs b/crates/polars-core/src/doc/mod.rs deleted file mode 100644 index 18169f152474..000000000000 --- a/crates/polars-core/src/doc/mod.rs +++ /dev/null @@ -1,2 +0,0 @@ -//! Other documentation -pub mod changelog; diff --git a/crates/polars-core/src/lib.rs b/crates/polars-core/src/lib.rs index 17ead65b8daa..610b8324a0f7 100644 --- a/crates/polars-core/src/lib.rs +++ b/crates/polars-core/src/lib.rs @@ -13,8 +13,6 @@ pub mod chunked_array; pub mod cloud; pub mod config; pub mod datatypes; -#[cfg(feature = "docs")] -pub mod doc; pub mod error; pub mod export; pub mod fmt; diff --git a/crates/polars-lazy/src/lib.rs b/crates/polars-lazy/src/lib.rs index 657103012f7a..b45ce11ee16c 100644 --- a/crates/polars-lazy/src/lib.rs +++ b/crates/polars-lazy/src/lib.rs @@ -201,11 +201,18 @@ extern crate core; #[cfg(feature = "dot_diagram")] +#[cfg(feature = "compile")] mod dot; +#[cfg(feature = "compile")] pub mod dsl; +#[cfg(feature = "compile")] pub mod frame; +#[cfg(feature = "compile")] pub mod physical_plan; +#[cfg(feature = "compile")] pub mod prelude; #[cfg(test)] +#[cfg(feature = "compile")] mod tests; +#[cfg(feature = "compile")] pub mod utils; diff --git a/crates/polars-plan/src/dsl/mod.rs b/crates/polars-plan/src/dsl/mod.rs index 1e8832808a7a..866a7b4dbb7b 100644 --- a/crates/polars-plan/src/dsl/mod.rs +++ b/crates/polars-plan/src/dsl/mod.rs @@ -17,7 +17,6 @@ mod expr; mod expr_dyn_fn; mod from; pub(crate) mod function_expr; -#[cfg(feature = "compile")] pub mod functions; mod list; #[cfg(feature = "meta")] diff --git a/crates/polars-plan/src/lib.rs b/crates/polars-plan/src/lib.rs index 01fde0ab0d23..915305aa87ac 100644 --- a/crates/polars-plan/src/lib.rs +++ b/crates/polars-plan/src/lib.rs @@ -1,11 +1,19 @@ #![cfg_attr(docsrs, feature(doc_auto_cfg))] #![cfg_attr(feature = "nightly", allow(clippy::needless_pass_by_ref_mut))] // remove once stable +#[cfg(feature = "compile")] pub mod constants; +#[cfg(feature = "compile")] pub mod dot; +#[cfg(feature = "compile")] pub mod dsl; +#[cfg(feature = "compile")] pub mod frame; +#[cfg(feature = "compile")] pub mod global; +#[cfg(feature = "compile")] pub mod logical_plan; +#[cfg(feature = "compile")] pub mod prelude; +#[cfg(feature = "compile")] pub mod utils; diff --git a/crates/polars/Cargo.toml b/crates/polars/Cargo.toml index c501c071a77a..36559b0dcd24 100644 --- a/crates/polars/Cargo.toml +++ b/crates/polars/Cargo.toml @@ -12,9 +12,9 @@ description = "DataFrame library based on Apache Arrow" [dependencies] polars-algo = { workspace = true, optional = true } -polars-core = { workspace = true, features = ["docs"], default-features = false } +polars-core = { workspace = true } polars-io = { workspace = true, optional = true } -polars-lazy = { workspace = true, features = [], default-features = false, optional = true } +polars-lazy = { workspace = true, default-features = false, optional = true } polars-ops = { workspace = true } polars-sql = { workspace = true, optional = true } polars-time = { workspace = true, optional = true } diff --git a/crates/polars/src/lib.rs b/crates/polars/src/lib.rs index 121c819e088b..11abf37644c7 100644 --- a/crates/polars/src/lib.rs +++ b/crates/polars/src/lib.rs @@ -408,8 +408,8 @@ pub mod prelude; pub mod sql; pub use polars_core::{ - apply_method_all_arrow_series, chunked_array, datatypes, df, doc, error, frame, functions, - series, testing, + apply_method_all_arrow_series, chunked_array, datatypes, df, error, frame, functions, series, + testing, }; #[cfg(feature = "dtype-categorical")] pub use polars_core::{enable_string_cache, using_string_cache};