Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix various typos in aggregation doc #12301

Merged
merged 1 commit into from
Sep 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions datafusion/expr-common/src/groups_accumulator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ pub enum EmitTo {
/// indexes down by `n`.
///
/// For example, if `n=10`, group_index `0, 1, ... 9` are emitted
/// and group indexes '`10, 11, 12, ...` become `0, 1, 2, ...`.
/// and group indexes `10, 11, 12, ...` become `0, 1, 2, ...`.
First(usize),
}

Expand Down Expand Up @@ -113,7 +113,7 @@ pub trait GroupsAccumulator: Send {
/// each group, and `evaluate` will produce that running sum as
/// its output for all groups, in group_index order
///
/// If `emit_to`` is [`EmitTo::All`], the accumulator should
/// If `emit_to` is [`EmitTo::All`], the accumulator should
/// return all groups and release / reset its internal state
/// equivalent to when it was first created.
///
Expand Down
3 changes: 2 additions & 1 deletion datafusion/physical-plan/src/aggregates/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1006,7 +1006,8 @@ pub fn get_finer_aggregate_exprs_requirement(
Ok(PhysicalSortRequirement::from_sort_exprs(&requirement))
}

/// returns physical expressions for arguments to evaluate against a batch
/// Returns physical expressions for arguments to evaluate against a batch.
///
/// The expressions are different depending on `mode`:
/// * Partial: AggregateFunctionExpr::expressions
/// * Final: columns of `AggregateFunctionExpr::state_fields()`
Expand Down
4 changes: 2 additions & 2 deletions datafusion/physical-plan/src/aggregates/order/full.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ use datafusion_expr::EmitTo;
/// group keys
///
/// When the group values are sorted, as soon as we see group `n+1` we
/// know we will never see any rows for group `n again and thus they
/// know we will never see any rows for group `n` again and thus they
/// can be emitted.
///
/// For example, given `SUM(amt) GROUP BY id` if the input is sorted
Expand Down Expand Up @@ -63,7 +63,7 @@ enum State {
/// Seen no input yet
Start,

/// Data is in progress. `current is the current group for which
/// Data is in progress. `current` is the current group for which
/// values are being generated. Can emit `current` - 1
InProgress { current: usize },

Expand Down
2 changes: 1 addition & 1 deletion datafusion/physical-plan/src/aggregates/order/partial.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ use std::sync::Arc;
/// key and earlier.
///
/// For example, given `SUM(amt) GROUP BY id, state` if the input is
/// sorted by `state, when a new value of `state` is seen, all groups
/// sorted by `state`, when a new value of `state` is seen, all groups
/// with prior values of `state` can be emitted.
///
/// The state is tracked like this:
Expand Down
2 changes: 1 addition & 1 deletion datafusion/physical-plan/src/aggregates/row_hash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ struct SpillState {
// ========================================================================
// STATES:
// Fields changes during execution. Can be buffer, or state flags that
// influence the exeuction in parent `GroupedHashAggregateStream`
// influence the execution in parent `GroupedHashAggregateStream`
// ========================================================================
/// If data has previously been spilled, the locations of the
/// spill files (in Arrow IPC format)
Expand Down