code: def test(self, zero_stage, use_cpu_offload):
      if (
          use_cpu_offload
          and not deepspeed.ops.__compatible_ops__[CPUAdamBuilder.NAME]
      ):
          pytest.skip("cpu-adam is not compatible")
  
      if zero_stage == 3:
          pytest.skip("skip for now")
  
      config_dict = {
          "train_micro_batch_size_per_gpu": 1,
          "gradient_accumulation_steps": 1,
          "fp16": {"enabled": True, "initial_scale_power": 8},
          "optimizer": {"type": "Adam", "params": {"lr": 0.00015}},
          "zero_optimization": {
              "stage": zero_stage,
              "cpu_offload": use_cpu_offload,
              "reduce_bucket_size": 100,
              "allgather_bucket_size": 100,
          },
      }
      hidden_dim = 1
      model = SimpleModel(hidden_dim)
  
      # Ensure model has 2 parameters, to cause empty partition with DP=3
      assert len(list(model.parameters())) == 2
      model, _, _, _ = deepspeed.initialize(
          config=config_dict,
          model=model,
          model_parameters=model.parameters(),
      )
  
      # Now make sure things work..
      data_loader = random_dataloader(
          model=model,
          total_samples=1,
          hidden_dim=hidden_dim,
          device=model.device,
      )
      for n, batch in enumerate(data_loader):
          loss = model(batch[0], batch[1])
          model.backward(loss)
          model.step()
  
imports: import torch
  import deepspeed.comm
  import deepspeed
  import pytest
  from deepspeed.ops.adam import FusedAdam
  from unit.common import DistributedTest
  from unit.simple_model import SimpleModel, SimpleOptimizer, random_dataloader, SimpleMoEModel, sequence_dataloader
  from deepspeed.runtime.utils import required_torch_version
  from deepspeed.accelerator import get_accelerator
  from deepspeed.ops.op_builder import CPUAdamBuilder
label_desc: Use image node_id 1 for calling the TestZeroEmptyPartition obj's underlying member method code with example usage: obj.test(zero_stage, use_cpu_offload) without return types