code: def test_save_load_compatible_schedulers(self):
      SchedulerObject2._compatibles = ["SchedulerObject"]
      SchedulerObject._compatibles = ["SchedulerObject2"]
  
      obj = SchedulerObject()
  
      # mock add obj class to `diffusers`
      setattr(diffusers, "SchedulerObject", SchedulerObject)
      setattr(diffusers, "SchedulerObject2", SchedulerObject2)
      logger = logging.get_logger("diffusers.configuration_utils")
  
      with tempfile.TemporaryDirectory() as tmpdirname:
          obj.save_config(tmpdirname)
  
          # now save a config parameter that is expected by another class, but not origin class
          with open(
              os.path.join(tmpdirname, SchedulerObject.config_name), "r"
          ) as f:
              data = json.load(f)
              data["f"] = [0, 0]
              data["unexpected"] = True
  
          with open(
              os.path.join(tmpdirname, SchedulerObject.config_name), "w"
          ) as f:
              json.dump(data, f)
  
          with CaptureLogger(logger) as cap_logger:
              config = SchedulerObject.load_config(tmpdirname)
              new_obj = SchedulerObject.from_config(config)
  
      assert new_obj.__class__ == SchedulerObject
  
      assert (
          cap_logger.out
          == "The config attributes {'unexpected': True} were passed to SchedulerObject, but are not expected and"
          " will"
          " be ignored. Please verify your config.json configuration file.\n"
      )
  
imports: import inspect
  import json
  import os
  import tempfile
  import unittest
  import uuid
  from typing import Dict, List, Tuple
  import numpy
  import torch
  from huggingface_hub import delete_repo
  import diffusers
  from diffusers import CMStochasticIterativeScheduler, DDIMScheduler, DEISMultistepScheduler, DiffusionPipeline, EulerAncestralDiscreteScheduler, EulerDiscreteScheduler, IPNDMScheduler, LMSDiscreteScheduler, UniPCMultistepScheduler, VQDiffusionScheduler, logging
  from diffusers.configuration_utils import ConfigMixin, register_to_config
  from diffusers.schedulers.scheduling_utils import SchedulerMixin
  from diffusers.utils.testing_utils import CaptureLogger, torch_device
  from ..others.test_utils import TOKEN, USER, is_staging_test
label_desc: Use image node_id 2 for calling the SchedulerBaseTests obj's underlying member method code with example usage: obj.test_save_load_compatible_schedulers() without return types