code: def pytest_configure(config):
      test_folder = Path(__file__).parent.resolve()
  
      targets = config.getoption("file_or_dir")
  
      if not targets:
          targets.append(".")
  
      requirements = set()
  
      for target in targets:
          target = Path(target).resolve()
  
          if target.is_file():
              target = target.parent
          else:
              requirements.update(
                  target.glob("**/require-packages.txt")
              )
  
          try:
              # .is_relative_to was only added in Py 3.9
              target.relative_to(test_folder)
  
              while True:
                  require = target / "require-packages.txt"
                  if require.exists():
                      requirements.add(require)
  
                  if target == test_folder:
                      break
                  target = target.parent
          except ValueError:
              pass
  
      old_path = sys.path
      sys.path = [
          path
          for path in sys.path
          if Path(path).resolve() != test_folder
      ]
  
      excludes = []
  
      for path in requirements:
          with path.open() as requirement:
              for requirement in map(str.strip, requirement):
                  try:
                      __import__(requirement)
                  except ImportError:
                      collect_ignore.append(
                          str(path.parent.relative_to(test_folder))
                      )
                      break
  
      if collect_ignore:
          warnings.warn(
              f"Skipping tests because some packages are not installed: {excludes}"
          )
  
      sys.path = old_path
  
imports: from pathlib import Path
  from typing import List, NamedTuple
  import gluonts
  import logging
  import numpy
  import os
  import pandas
  import pytest
  import random
  import sys
  import tempfile
  import warnings
  from gluonts.model import Predictor
  from gluonts.dataset.common import ListDataset
label_desc: Use image node_id 4 for calling a global function with example usage: pytest_configure(config) without return types