code: def dynamic_convolution(
      inp, inp2=None, n_heads=8, kernel_size=4, padding="causal"
  ):
      batch, seq, n_channels = shape_list(inp)
      kernel_size_inc_ra = kernel_size
      if inp2 is not None:
          kernel_size_inc_ra += shape_list(inp2)[2]
  
      weights_linear = tf.reshape(
          linear(
              inp,
              n_heads * kernel_size_inc_ra,
              "kernel_machine",
          ),
          [
              batch,
              seq,
              kernel_size_inc_ra,
              n_heads,
          ],  # batch time heads, kernel_size, 1
      )
      weights_linear = tf.nn.softmax(weights_linear, 2)
  
      if inp2 is not None:
          weights_ra = weights_linear[:, :, kernel_size:]
          weights_linear = weights_linear[:, :, :kernel_size]
          ra_dynamic = dynamic_conv_on_ra_out(inp2, weights_ra)
      else:
          ra_dynamic = 0.0
  
      if indico_ops.BUILT and tf.test.is_gpu_available():
          # There is no CPU version of this op we need to check this.
          dynamic_conv_fn = indico_ops.dynamic_convolution_op
      else:
          dynamic_conv_fn = dynamic_conv_cpu
  
      return (
          dynamic_conv_fn(inp, weights_linear, padding=padding)
          + ra_dynamic
      )
  
file_path: finetune/finetune/custom_ops/indico_tf_ops/python/dynamic_conv.py
imports: import os
  import math
  import numpy
  import tensorflow
  from finetune.util.shapes import shape_list
  from finetune.custom_ops.indico_tf_ops.python import indico_ops
label_desc: Use image node_id 5 for calling a global function with example usage: dynamic_convolution(inp, inp2, n_heads, kernel_size, padding) and returns: unknown