load_quantized_kernels_so.py 文件源码

python
阅读 35 收藏 0 点赞 0 评论 0

项目:lsdc 作者: febert 项目源码 文件源码
def Load(library_base_dir=''):
  """Load the quantized ops library and return the loaded module."""
  with _kernels_lock:
    global _quantized_kernels
    if not _quantized_kernels:
      data_files_path = os.path.join(library_base_dir,
                                     tf.resource_loader.get_data_files_path())
      tf.logging.info('data path: %s', data_files_path)
      _quantized_kernels = tf.load_op_library(os.path.join(
          data_files_path, QUANTIZED_KERNELS_FILE))

      assert _quantized_kernels, 'Could not load _quantized_kernels.so'
  return _quantized_kernels
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号