当前位置: 首页 > news >正文

wordpress主题制作器seo发外链工具

wordpress主题制作器,seo发外链工具,外贸网站建设soho,网站建设流程所用工具同时对一共父级文件夹遍历。获得对应不同干扰程度的模糊图像 # This isimport cv2 import numpy as npdef reduce_resolution(image, factor):height, width, _ image.shape # 获取原始图像的宽度和高度new_width int(width / factor) # 计算新的宽度和高度new_height i…

同时对一共父级文件夹遍历。获得对应不同干扰程度的模糊图像

# This isimport cv2
import numpy as npdef reduce_resolution(image, factor):height, width, _ = image.shape    # 获取原始图像的宽度和高度new_width = int(width / factor) # 计算新的宽度和高度new_height = int(height / factor)# 使用resize方法来缩小图像分辨率,保持尺寸不变resized_image = cv2.resize(image, (new_width, new_height), interpolation=cv2.INTER_AREA)return resized_imagedef motion_blur(image, degree=12, angle=45):image = np.array(image)# 这里生成任意角度的运动模糊kernel的矩阵, degree越大,模糊程度越高M = cv2.getRotationMatrix2D((degree / 2, degree / 2), angle, 1)motion_blur_kernel = np.diag(np.ones(degree))motion_blur_kernel = cv2.warpAffine(motion_blur_kernel, M, (degree, degree))motion_blur_kernel = motion_blur_kernel / degreeblurred = cv2.filter2D(image, -1, motion_blur_kernel)# convert to uint8cv2.normalize(blurred, blurred, 0, 255, cv2.NORM_MINMAX)blurred = np.array(blurred, dtype=np.uint8)return blurredimg = cv2.imread(r'H:\LRFRcode\acrface-bubb\arcface-pytorch-main\ForPaper1_Images_Crop\N010\N010_0008__Gaus2.jpg')idex = 15
Image_perturbation_Gaussian_idex = 1.02*idex
Image_perturbation_Motion_idex = 3*idex
Image_perturbation_reduceresolution_idex = 1.1*idex#
Gaussian_blurred_image = cv2.GaussianBlur(img, ksize=(0,0), sigmaX=Image_perturbation_Gaussian_idex) # ksize 必须是一个正奇数,可以通过 (0, 0) 来自动计算核的大小
Motion_blurred_image = motion_blur(img, degree=Image_perturbation_Motion_idex, angle=45)
reduce_resolution_image = reduce_resolution(img, factor=Image_perturbation_reduceresolution_idex)# cv2.imshow('Original', img)
# cv2.imshow('Gaussian Filter', Gaussian_blurred_image)
# cv2.imshow('Motion Filter', Motion_blurred_image)
# cv2.imshow('reduce_resolution Filter', reduce_resolution_image)
#
# cv2.waitKey(0)
# cv2.destroyAllWindows()# 保存图像
cv2.imwrite("save/Gaussian_blurred_image" + str(Image_perturbation_Gaussian_idex) +".jpg", Gaussian_blurred_image)  # 保存降低分辨率后的图像
cv2.imwrite("save/Motion_blurred_image" + str(Image_perturbation_Motion_idex) +".jpg", Motion_blurred_image)  # 保存降低分辨率后的图像
cv2.imwrite("save/reduced_resolution_image_" + str(Image_perturbation_reduceresolution_idex) +".jpg", reduce_resolution_image)  # 保存降低分辨率后的图像
http://www.wangmingla.cn/news/53619.html

相关文章:

  • 可以做设计兼职的网站有哪些工作室百度seo系统
  • 网页制作素材末班seo搜索引擎实训心得体会
  • 北京智能网站建设平台百度网盘客服在线咨询
  • 电商网站开发的背景东莞网络推广招聘
  • 做城市网站的标语链交换
  • 郑州网站维护海外seo推广公司
  • 广州网站开发制作百度目前的推广方法
  • app网站建设销售谷歌浏览器官网手机版
  • 网站可以做的线下活动如何去除痘痘有效果
  • 国外 做励志视频的网站传统营销与网络营销的整合方法
  • 网络班级网站建设关键词排名怎么查
  • 四川建设工程网seo是什么意思呢
  • 绵阳市城市建设档案馆网站口碑营销的模式
  • 网站建设备案是什么意思百度推广查询
  • 网站建设分项报价表深圳网站建设推广
  • 网站开发工具和平台云优客seo排名公司
  • 平安网站做的太差大连百度推广公司
  • 代做财务报表分析网站利用搜索引擎营销成功的案例
  • 男女做暖暖的试看网站企业网络推广
  • 网站源码制作深圳网络营销网站设计
  • 网站关键词表格下载百度引流推广
  • 武汉有哪些建筑公司东莞做网站排名优化推广
  • 怎么样做电影网站长沙优化排名
  • 动态网站制作好了在哪里看网站推广的目的是什么
  • 当地政府网站建设问卷调查体验营销策略有哪些
  • 网站架构模式用哪种一链一网一平台
  • 发稿计划seo收录排名
  • 刘洋网站建设 够完美网站优化推广的方法
  • 营销公司网络检索宁波seo快速排名
  • 做网站赚钱有哪些途径沙坪坝区优化关键词软件