MCPcopy Create free account
hub / github.com/dask/dask / _divisions

Method _divisions

dask/dataframe/dask_expr/_expr.py:3522–3532  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3520 _expr_cls: AnyType | None = None
3521
3522 def _divisions(self):
3523 if {df.npartitions for df in self.args} == {1}:
3524 divs = []
3525 for df in self.args:
3526 divs.extend(list(df.divisions))
3527 try:
3528 return min(divs), max(divs)
3529 except TypeError:
3530 # either unknown divisions or int-str mix
3531 return None, None
3532 return calc_divisions_for_align(*self.args)
3533
3534 def _simplify_up(self, parent, dependents):
3535 if isinstance(parent, Projection) and self._projection_passthrough:

Callers

nothing calls this directly

Calls 3

minFunction · 0.85
maxFunction · 0.85
calc_divisions_for_alignFunction · 0.85

Tested by

no test coverage detected