code: def art_warning(request):
      def _art_warning(exception):
          if type(exception) is ARTTestFixtureNotImplemented:
              if request.node.get_closest_marker("framework_agnostic"):
                  if not request.node.get_closest_marker("parametrize"):
                      raise Exception(
                          "This test has marker framework_agnostic decorator which means it will only be ran "
                          "once. However the ART test exception was thrown, hence it is never run fully. "
                      )
              elif (
                  request.node.get_closest_marker("only_with_platform")
                  and len(
                      request.node.get_closest_marker(
                          "only_with_platform"
                      ).args
                  )
                  == 1
              ):
                  raise Exception(
                      "This test has marker only_with_platform decorator which means it will only be ran "
                      "once. However the ARTTestFixtureNotImplemented exception was thrown, hence it is "
                      "never run fully. "
                  )
  
              # NotImplementedErrors are raised in ART whenever a test model does not exist for a specific
              # model/framework combination. By catching there here, we can provide a report at the end of each
              # pytest run list all models requiring to be implemented.
              warnings.warn(UserWarning(exception))
          else:
              raise exception
  
      return _art_warning
  
imports: import importlib
  import json
  import logging
  import os
  import shutil
  import tempfile
  from typing import Dict, List, TYPE_CHECKING, Union
  import warnings
  import numpy
  import pytest
  import requests
  from art.data_generators import KerasDataGenerator, MXDataGenerator, PyTorchDataGenerator, TensorFlowDataGenerator, TensorFlowV2DataGenerator
  from art.defences.preprocessor import FeatureSqueezing, JpegCompression, SpatialSmoothing
  from art.estimators.classification import KerasClassifier
  from tests.utils import ARTTestFixtureNotImplemented, get_attack_classifier_pt, get_image_classifier_kr, get_image_classifier_kr_functional, get_image_classifier_kr_tf, get_image_classifier_kr_tf_functional, get_image_classifier_kr_tf_with_wildcard, get_image_classifier_mxnet_custom_ini, get_image_classifier_pt, get_image_classifier_pt_functional, get_image_classifier_tf, get_image_classifier_hf, get_image_gan_tf_v2, get_image_generator_tf_v2, get_tabular_classifier_kr, get_tabular_classifier_pt, get_tabular_classifier_scikit_list, get_tabular_classifier_tf, load_dataset, master_seed
label_desc: Use image node_id 19 for calling a global function with example usage: art_warning(request) and returns: _art_warning