code: def _generate_chunks_for_qr(total_size, min_size, n_parts):
      n_total_per_part = max(1, int(total_size / n_parts))
      if n_total_per_part > min_size:
          min_size = n_total_per_part
  
      n_partitions = int(max(1, total_size / min_size))
      rest = total_size % (n_partitions * min_size)
      chunks_list = [min_size for i in range(n_partitions - 1)]
      chunks_list.append(min_size + rest)
      return tuple(chunks_list)
  
imports: from cuml.dask.common.utils import get_client
  from cuml.dask.common.input_utils import DistributedDataHandler
  from cuml.common import with_cupy_rmm
  from cuml.dask.datasets.utils import _create_delayed
  from cuml.dask.datasets.utils import _get_labels
  from cuml.dask.datasets.utils import _get_X
  from cuml.internals.safe_imports import gpu_only_import
  import dask.array
  from cuml.internals.safe_imports import cpu_only_import
label_desc: Use image node_id 9 for calling a global function with example usage: _generate_chunks_for_qr(total_size, min_size, n_parts) and returns: tuple