2018年9月19日

3-4 图片缩放3

摘要: # 1 info 2 空白模板 3 xy import cv2 import numpy as np img = cv2.imread('image0.jpg',1) imgInfo = img.shape height = imgInfo[0] width = imgInfo[1] dstHeight = int(height/2) dstWidth = int(width/2) dstIm... 阅读全文

posted @ 2018-09-19 20:04 绿茵好莱坞 阅读(250) 评论(0) 推荐(0)

3-3 图片缩放2

摘要: #最近临域插值 双线性插值 原理 # src 10*20 dst 5*10 # dst src x 2 newX # newX = x*(src 行/目标 行) newX = 1* (10/5) = 2 # newY = y*(src 列/目标 列) newY = 2* (20/10) = 4 # 12.3 = 12 # 双线性插值 # A1 = 20% 上+80%下 A2 # B1 = ... 阅读全文

posted @ 2018-09-19 17:10 绿茵好莱坞 阅读(95) 评论(0) 推荐(0)

导航