We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4725234 commit d2d8ca9Copy full SHA for d2d8ca9
datafusion/functions-aggregate/src/median.rs
@@ -387,6 +387,13 @@ impl<T: ArrowNumericType + Send> GroupsAccumulator for MedianGroupsAccumulator<T
387
cur_len += group_value.len() as i32;
388
offsets.push(cur_len);
389
}
390
+ // TODO: maybe we can use `OffsetBuffer::new_unchecked` like what in `convert_to_state`,
391
+ // but safety should be considered more carefully here(and I am not sure if it can get
392
+ // performance improvement when we introduce checks to keep the safety...).
393
+ //
394
+ // Can see more details in:
395
+ // https://github.com/apache/datafusion/pull/13681#discussion_r1931209791
396
397
let offsets = OffsetBuffer::new(ScalarBuffer::from(offsets));
398
399
// Build inner array
0 commit comments