hipscatalog_gen.utils._get_dask_base

_get_dask_base(ddf_like, require_groupby=False, require_map_partitions=False, require_to_delayed=False)[source]

Prefer public Dask-like interfaces; fall back to LSDB ._ddf only when needed.

Parameters:
  • ddf_like (Any) – Dask-like object or LSDB catalog.

  • require_groupby (bool) – Require a groupby attribute.

  • require_map_partitions (bool) – Require a map_partitions attribute.

  • require_to_delayed (bool) – Require a to_delayed attribute.

Returns:

The same object if it already satisfies the required interface, otherwise its underlying Dask DataFrame when dealing with LSDB catalogs.

Raises:
  • TypeError – If the object (or its LSDB base) does not expose the required methods.

  • TypeError – If an LSDB catalog lacks the _ddf attribute.

Return type:

Any