code: def target_opsets(request):
      opsets = request.config.getoption("opset-versions")
      min_version = onnx_chainer.MINIMUM_OPSET_VERSION
      max_version = min(
          onnx.defs.onnx_opset_version(),
          onnx_chainer.MAXIMUM_OPSET_VERSION,
      )
      if opsets is None:
          return list(range(min_version, max_version + 1))
      elif opsets == "min":
          return [min_version]
      elif opsets == "latest":
          return [max_version]
      else:
          try:
              versions = [int(i) for i in opsets.split(",")]
          except ValueError:
              raise ValueError(
                  "cannot convert {} to versions list".format(opsets)
              )
          return versions
  
file_path: chainer/tests/onnx_chainer_tests/conftest.py
imports: import chainer
  import onnx
  import pytest
  import onnx_chainer
label_desc: Use image node_id 4 for calling a global function with example usage: target_opsets(request) and returns: list, list, list, versions