code: def max_rel_diff(curve_ref, curve, min_value=0.01):
      
      assert len(curve_ref) == len(curve), (len(curve_ref), len(curve))
      assert len(curve), 'The curves are empty!'
      max_diff = 0
      for c1, c2 in zip(curve_ref, curve):
          if c1 >= min_value:
              max_diff = max(max_diff, abs(c1 - c2) / c1)
      return max_diff
docs: Compute the maximum relative difference between two curves. Only values
      greather or equal than the min_value are considered.
  
      >>> curve_ref = [0.01, 0.02, 0.03, 0.05, 1.0]
      >>> curve = [0.011, 0.021, 0.031, 0.051, 1.0]
      >>> round(max_rel_diff(curve_ref, curve), 2)
      0.1