code: def test_linear_layer_compress(self, tmpdir):
      model = create_bert_model()
      compressed_model = init_compression(model, self.get_ds_config())
  
      assert isinstance(
          compressed_model.layer[0].attention.self.query,
          LinearLayer_Compress,
      )
      assert isinstance(
          compressed_model.layer[0].attention.self.key,
          LinearLayer_Compress,
      )
      assert isinstance(
          compressed_model.layer[0].attention.self.value,
          LinearLayer_Compress,
      )
  
imports: import torch
  import pytest
  import random
  import numpy
  from unit.megatron_model import get_gpt2_model
  from deepspeed.compression.compress import init_compression
  from unit.modeling import BertConfig
  from unit.modelingpreln import BertEncoder
  from deepspeed.compression.basic_layer import LinearLayer_Compress, ColumnParallelLinear_Compress, RowParallelLinear_Compress
  from deepspeed.compression.helper import convert_conv1d_to_linear
  from deepspeed.accelerator import get_accelerator
  from deepspeed.runtime.utils import required_torch_version
  from unit.common import DistributedTest
label_desc: Use image node_id 3 for calling the TestCompression obj's underlying member method code with example usage: obj.test_linear_layer_compress(tmpdir) without return types