code: def test_threshold_iou(case):
      gt, pr, res = case
      gt = _to_4d(gt)
      pr = _to_4d(pr) * 0.51
      iou_score = IOUScore(smooth=10e-12, threshold=0.5)
      score = keras.backend.eval(iou_score(gt, pr))
      assert np.allclose(score, res)
  
file_path: segmentation_models/tests/test_metrics.py
imports: import pytest
  import numpy
  import segmentation_models
  from segmentation_models.metrics import IOUScore, FScore
  from segmentation_models.losses import JaccardLoss, DiceLoss
label_desc: Use image node_id 11 for calling a global function with example usage: test_threshold_iou(case) without return types