code: def init_fp8_kv_cache(
      batch_size,
      num_heads,
      head_dim,
      current_length,
      max_length,
      device,
  ):
      k_cache_storage = torch.empty(
          batch_size,
          num_heads,
          max_length,
          head_dim,
          dtype=torch.uint8,
          device=device,
      )
  
      v_cache_storage = torch.empty(
          batch_size,
          num_heads,
          head_dim,
          max_length,
          dtype=torch.uint8,
          device=device,
      )
  
      k_cache = k_cache_storage.as_strided(
          (batch_size, num_heads, current_length, head_dim),
          k_cache_storage.stride(),
          storage_offset=0,
      )
  
      v_cache = v_cache_storage.as_strided(
          (batch_size, num_heads, head_dim, current_length),
          v_cache_storage.stride(),
          storage_offset=0,
      )
  
      return k_cache, v_cache.transpose(-1, -2)
  
imports: import os
  import torch
  from bigdl.llm.utils.common import invalidInputError
  from bigdl.llm.ggml.quantize import ggml_tensor_qtype
  from bigdl.llm.transformers.utils import get_ipex_version, get_xpu_device_type
label_desc: Use image node_id 5 for calling a global function with example usage: init_fp8_kv_cache(batch_size, num_heads, head_dim, current_length, max_length, device) and returns: k_cache,  v_cache