code: def _run_dnb_normalization(self, dnb_data, sza_data):
          
          # convert dask arrays to DataArray objects
          dnb_data = xr.DataArray(dnb_data, dims=('y', 'x'))
          sza_data = xr.DataArray(sza_data, dims=('y', 'x'))
  
          good_mask = ~(dnb_data.isnull() | sza_data.isnull())
          output_dataset = dnb_data.where(good_mask)
          # we only need the numpy array
          output_dataset = output_dataset.values.copy()
          dnb_data = dnb_data.values
          sza_data = sza_data.values
  
          day_mask, mixed_mask, night_mask = make_day_night_masks(
              sza_data,
              good_mask.values,
              self.high_angle_cutoff,
              self.low_angle_cutoff,
              stepsDegrees=self.mixed_degree_step)
  
          did_equalize = False
          if day_mask.any():
              LOG.debug("Histogram equalizing DNB day data...")
              histogram_equalization(dnb_data, day_mask, out=output_dataset)
              did_equalize = True
          if mixed_mask:
              for mask in mixed_mask:
                  if mask.any():
                      LOG.debug("Histogram equalizing DNB mixed data...")
                      histogram_equalization(dnb_data, mask, out=output_dataset)
                      did_equalize = True
          if night_mask.any():
              LOG.debug("Histogram equalizing DNB night data...")
              histogram_equalization(dnb_data, night_mask, out=output_dataset)
              did_equalize = True
  
          if not did_equalize:
              raise RuntimeError("No valid data found to histogram equalize")
  
          return output_dataset
docs: Scale the DNB data using a histogram equalization method.
  
          Args:
              dnb_data (ndarray): Day/Night Band data array
              sza_data (ndarray): Solar Zenith Angle data array