cython的编译方法
cython用于存放cpp的代码,在不同的环境中编译,如Mac或Ubuntu服务器,一般存在setup.py的文件夹中,需要执行命令:
python setup.py build_ext --inplace
即,在setup.py文件中,执行cmdclass中的key:
setup(
name='frcnn_cython',
ext_modules=ext_modules,
# inject our custom trigger
cmdclass={'build_ext': custom_build_ext},
)
That’s all!