code: def _cpu_lstm(
      x,
      init_h,
      init_c,
      kernel,
      recurrent_kernel,
      bias,
      recurrent_bias,
      time_major,
  ):
      def step(cell_inputs, cell_states):
          h_tm1 = cell_states[0]  # previous memory state
          c_tm1 = cell_states[1]  # previous carry state
  
          z = tf.keras.backend.dot(cell_inputs, kernel)
          if bias is not None:
              z += bias
  
          z += tf.keras.backend.dot(h_tm1, recurrent_kernel)
          if recurrent_bias is not None:
              z += recurrent_bias
  
          z0, z1, z2, z3 = tf.split(z, 4, axis=-1)
  
          i = tf.sigmoid(z0)
          f = tf.sigmoid(z1)
          c = f * c_tm1 + i * tf.tanh(z2)
          o = tf.sigmoid(z3)
  
          h = o * tf.tanh(c)
          return h, [h, c]
  
      _, outputs, new_states = tf.keras.backend.rnn(
          step,
          x,
          [init_h, init_c],
          time_major=time_major,
      )
      return outputs, new_states
  
imports: from typing import Optional, Tuple, Union, Sequence
  import tensorflow
  from tensorflow.python.types.core import Tensor
  import ivy
  from ivy.func_wrapper import with_supported_dtypes, with_unsupported_dtypes
  from .None import backend_version
  from ivy.functional.ivy.layers import _deconv_length, _get_x_data_format
label_desc: Use image node_id 16 for calling a global function with example usage: _cpu_lstm(x, init_h, init_c, kernel, recurrent_kernel, bias, recurrent_bias, time_major) and returns: outputs,  new_states, h,  list