最近由于项目自动化构建的需要,研究了下gradle调用脚本并传参的用法,在此作个总结. Pre build.gradle中定义了$jenkinsJobName $jenkinsBuild两个Jenkins变量,意图将gradle中的这两个值传到shell/python脚本中去用 def jenkinsBuild = System.getenv("BUILD_NUMBER") ?: "0" println "jenkinsBuild is set to $j
检测图片是否模糊有很多方法(这篇文章review了36种),比如FFT和variation of Laplacian等,前者在操作到时候需要定义高频的量有多低和多高来区分图片是模糊的,操作起来比较麻烦:而后者可以输出一个浮点数来代表图片的模糊程度. 这里我们用的方法为Pech-Pacheco在2000年提出的Laplacian方法(具体可以查看这篇文章).Laplacian方法能够进行这项工作的原因是Laplacian算子是用来衡量图片的二阶导,能够强调图片中密度快速变化的区域,也就是边界,故常
拉普拉斯线性滤波,.边缘检測 . When ksize == 1 , the Laplacian is computed by filtering the image with the following aperture: Laplace 计算图像的 Laplacian 变换 void cvLaplace( const CvArr* src, CvArr* dst, int aperture_size=3 ); src 输入图像. dst 输出图像. aperture_size 核大小 (
闲的时候用OpenCV画漫画也挺有意思,虽然效果不好(达不到上面所实现的效果), 参数需要调整,还是大头贴而且噪声小的图像比较合适 而且可以熟悉一下关于各种滤波的操作比如:双边滤波: #include "cv.h" #include "highgui.h" using namespace cv; using namespace std; int main() { string name="D:/cartoon0.jpg"; Mat src1=im