原文github:https://github.com/zhigangjiang/simple_agc
本来想用python写一遍,考虑到速度可能慢,故使用cython重写,方便python调用:
测试效果不是很对,不知道出了什么问题了,待改进。
jupyter notebook : %load_ext Cython
# %%cython -a --cplus --compile-args=/openmp
import cv2
cimport cython
cimport numpy as np
import numpy as np
from cython.parallel import parallel, prange
from libc.math cimport pow as