code: def _thresholding(stc_true, stc_est, threshold):
      relative = isinstance(threshold, str)
      threshold = _check_threshold(threshold)
      if relative:
          if stc_true is not None:
              stc_true._data[
                  np.abs(stc_true._data)
                  <= threshold * np.max(np.abs(stc_true._data))
              ] = 0.0
          stc_est._data[
              np.abs(stc_est._data)
              <= threshold * np.max(np.abs(stc_est._data))
          ] = 0.0
      else:
          if stc_true is not None:
              stc_true._data[np.abs(stc_true._data) <= threshold] = 0.0
          stc_est._data[np.abs(stc_est._data) <= threshold] = 0.0
      return stc_true, stc_est
  
imports: from functools import partial
  import numpy
  from scipy.spatial.distance import cdist
  from ...utils import _check_option, _validate_type, fill_doc
label_desc: Use image node_id 5 for calling a global function with example usage: _thresholding(stc_true, stc_est, threshold) and returns: stc_true,  stc_est