def METHOD_NAME(self):
    meta_info = dict(
        img_size=[256, 256],
        scale_factor=np.array([1.5, 1.5]),
        img_shape=torch.rand(4))
    det_data_sample = DetDataSample(metainfo=meta_info)
    assert 'img_size' in det_data_sample
    assert det_data_sample.img_size == [256, 256]
    assert det_data_sample.get('img_size') == [256, 256]