code: def test_lz4_decompression_avoids_deep_copy():
      """Test that lz4 output is a bytearray, not bytes, so that numpy deserialization is
      not forced to perform a deep copy to obtain a writeable array.
      Note that zlib, zstandard, and snappy don't have this option.
      """
      pytest.importorskip("lz4")
      a = bytearray(1_000_000)
      b = compressions["lz4"].compress(a)
      c = compressions["lz4"].decompress(b)
      assert isinstance(c, bytearray)
  
imports: from __future__ import annotations
  import threading
  import zlib
  from concurrent.futures import ThreadPoolExecutor
  import pytest
  import dask.config
  from distributed import Worker, wait
  from distributed.compatibility import LINUX
  from distributed.protocol import dumps, loads, maybe_compress, msgpack, to_serialize
  from distributed.protocol.compression import Compression, compressions, get_compression_settings
  from distributed.utils import nbytes
  from distributed.utils_test import gen_cluster
label_desc: Use image node_id 9 for calling a global function with example usage: test_lz4_decompression_avoids_deep_copy() without return types