code: def init_libane():
      global libane, aneregs
      libane = cdll.LoadLibrary((basedir / "libane.dylib").as_posix())
  
      libane.ANE_Compile.argtypes = [c_char_p, c_int]
      libane.ANE_Compile.restype = c_void_p
  
      libane.ANE_TensorCreate.restype = c_void_p
  
      libane.ANE_TensorData.argtypes = [c_void_p]
      libane.ANE_TensorData.restype = POINTER(c_uint16)
  
      libane.ANE_Run.argtypes = [c_void_p] * 4
      libane.ANE_Run.restype = c_int
  
      # libane.ANE_RegDebug.restype = c_char_p
  
      with open(basedir / "aneregs.json") as f:
          aneregs = json.load(f)
  
imports: from pathlib import Path
  from ctypes import *
  import json
  import collections
  import numpy
  import faulthandler
  import struct
label_desc: Use image node_id 1 for calling a global function with example usage: init_libane() without return types