code: def check_eq_hist_cdf_slope(eq):
      # Check that the slope of the cdf is ~1
      # Adapted from scikit-image's test for the same function
      cdf = np.histogram(eq[~np.isnan(eq)], bins=256)[0].cumsum()
      cdf = cdf / cdf[-1]
      slope = np.polyfit(np.linspace(0, 1, cdf.size), cdf, 1)[0]
      assert 0.9 < slope < 1.1
  
imports: from __future__ import annotations
  from io import BytesIO
  import numpy
  import xarray
  import dask.array
  import PIL
  import pytest
  import datashader.transfer_functions
  from datashader.tests.test_pandas import assert_eq_ndarray, assert_eq_xr, assert_image_close
label_desc: Use image node_id 33 for calling a global function with example usage: check_eq_hist_cdf_slope(eq) without return types