code: def test_karras_schedulers_shape(self):
      skip_schedulers = [
          "DDIMScheduler",
          "DDPMScheduler",
          "PNDMScheduler",
          "HeunDiscreteScheduler",
          "EulerAncestralDiscreteScheduler",
          "KDPM2DiscreteScheduler",
          "KDPM2AncestralDiscreteScheduler",
          "DPMSolverSDEScheduler",
      ]
      components = self.get_dummy_components()
      pipe = self.pipeline_class(**components)
  
      # make sure that PNDM does not need warm-up
      pipe.scheduler.register_to_config(skip_prk_steps=True)
  
      pipe.to(torch_device)
      pipe.set_progress_bar_config(disable=None)
      inputs = self.get_dummy_inputs(torch_device)
      inputs["num_inference_steps"] = 2
  
      outputs = []
      for scheduler_enum in KarrasDiffusionSchedulers:
          if scheduler_enum.name in skip_schedulers:
              # no sigma schedulers are not supported
              # no schedulers
              continue
  
          scheduler_cls = getattr(diffusers, scheduler_enum.name)
          pipe.scheduler = scheduler_cls.from_config(
              pipe.scheduler.config
          )
          output = pipe(**inputs)[0]
          outputs.append(output)
  
      assert check_same_shape(outputs)
  
imports: import gc
  import random
  import unittest
  import numpy
  import torch
  from transformers import CLIPTextConfig, CLIPTextModel, CLIPTokenizer
  import diffusers
  from diffusers import AutoencoderKL, EulerDiscreteScheduler, StableDiffusionLatentUpscalePipeline, StableDiffusionPipeline, UNet2DConditionModel
  from diffusers.schedulers import KarrasDiffusionSchedulers
  from diffusers.utils.testing_utils import enable_full_determinism, floats_tensor, load_image, load_numpy, require_torch_gpu, slow, torch_device
  from ..pipeline_params import TEXT_GUIDED_IMAGE_VARIATION_BATCH_PARAMS, TEXT_GUIDED_IMAGE_VARIATION_PARAMS
  from ..test_pipelines_common import PipelineKarrasSchedulerTesterMixin, PipelineLatentTesterMixin, PipelineTesterMixin
label_desc: Use image node_id 12 for calling the StableDiffusionLatentUpscalePipelineFastTests obj's underlying member method code with example usage: obj.test_karras_schedulers_shape() without return types