code: def on_separate_bands(func):
      """Apply `func` one band of the DataArray at a time.
  
      If this decorator is to be applied along with `on_dask_array`, this decorator has to be applied first, eg::
  
          @on_separate_bands
          @on_dask_array
          def my_enhancement_function(data):
              ...
  
  
      """
  
      @wraps(func)
      def wrapper(data, **kwargs):
          attrs = data.attrs
          data_arrs = []
          for idx, band in enumerate(data.coords["bands"].values):
              band_data = func(
                  data.sel(bands=[band]), index=idx, **kwargs
              )
              data_arrs.append(band_data)
              # we assume that the func can add attrs
              attrs.update(band_data.attrs)
          data.data = xr.concat(data_arrs, dim="bands").data
          data.attrs = attrs
          return data
  
      return wrapper
  
imports: import logging
  import os
  from collections import namedtuple
  from functools import wraps
  from numbers import Number
  from typing import Optional
  import dask
  import dask.array
  import numpy
  import xarray
  from trollimage.colormap import Colormap
  from trollimage.xrimage import XRImage
  from satpy._compat import ArrayLike
  from satpy._config import get_config_path
  from satpy.utils import find_in_ancillary
label_desc: Use image node_id 5 for calling a global function with example usage: on_separate_bands(func) and returns: wrapper, data