code: def test_loss_gradient_with_wildcard(art_warning, image_dl_estimator):
      try:
          classifier, _ = image_dl_estimator(wildcard=True)
          shapes = [(1, 10, 1), (1, 20, 1)]
          for shape in shapes:
              x = np.random.normal(size=shape)
              loss_gradient = classifier.loss_gradient(x, y=[1])
              assert loss_gradient.shape == shape
  
              class_gradient = classifier.class_gradient(x, 0)
              assert class_gradient[0].shape == shape
  
      except ARTTestException as e:
          art_warning(e)
  
imports: import logging
  import os
  from os import listdir, path
  import pickle
  import tempfile
  import keras
  import numpy
  import pytest
  from tensorflow.keras.callbacks import LearningRateScheduler
  from art.defences.preprocessor import FeatureSqueezing, JpegCompression, SpatialSmoothing
  from tests.utils import ARTTestException
label_desc: Use image node_id 2 for calling a global function with example usage: test_loss_gradient_with_wildcard(art_warning, image_dl_estimator) without return types