code: def test_sequence():
      """
      Test basic OpAlgoBase operation
      """
  
      shader = """
          #version 450
          layout(set = 0, binding = 0) buffer tensorLhs {float valuesLhs[];};
          layout(set = 0, binding = 1) buffer tensorRhs {float valuesRhs[];};
          layout(set = 0, binding = 2) buffer tensorOutput { float valuesOutput[];};
          layout (local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
  
          void main()
          {
              uint index = gl_GlobalInvocationID.x;
              valuesOutput[index] = valuesLhs[index] * valuesRhs[index];
          }
      """
  
      spirv = compile_source(shader)
  
      mgr = kp.Manager(0)
  
      tensor_in_a = mgr.tensor([2, 2, 2])
      tensor_in_b = mgr.tensor([1, 2, 3])
      tensor_out = mgr.tensor([0, 0, 0])
  
      params = [tensor_in_a, tensor_in_b, tensor_out]
  
      algo = mgr.algorithm(params, spirv)
  
      sq = mgr.sequence()
  
      sq.record(kp.OpTensorSyncDevice(params))
      sq.record(kp.OpAlgoDispatch(algo))
      sq.record(kp.OpTensorSyncLocal(params))
  
      sq.eval()
  
      assert sq.is_init() == True
  
      sq.destroy()
  
      assert sq.is_init() == False
  
      assert tensor_out.data().tolist() == [2.0, 4.0, 6.0]
      assert np.all(tensor_out.data() == [2.0, 4.0, 6.0])
  
      tensor_in_a.destroy()
      tensor_in_b.destroy()
      tensor_out.destroy()
  
      assert tensor_in_a.is_init() == False
      assert tensor_in_b.is_init() == False
      assert tensor_out.is_init() == False
  
file_path: kompute/python/test/test_kompute.py
imports: import os
  import kp
  import numpy
  import logging
  import pyshader
  from .utils import compile_source
label_desc: Use image node_id 3 for calling a global function with example usage: test_sequence() without return types