追踪到gpu_untils出现报错修改调用方法为如上图所示:
1.将cp.cuda.compile_with_cahe需改为cp.RawKernel.
这是因为在cuda V10以上版本不在支持compile_with_cahe方法,并且注意cp.RawKernel的输入为两个分别是代码,和代码名称:
kernel_code = cp.RawKernel(code,kernel_name)
2.将return值直接改为 kernel_code即可
return kernel_code