1 Star 1 Fork 0

zzb32 / HandPose

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
normalize.py 855 Bytes
一键复制 编辑 原始数据 按行查看 历史
MrEliptik 提交于 2019-01-21 11:10 . new models and results
import cv2
import os
from os.path import isfile, join
print(os.listdir("Poses/"))
poses = os.listdir('Poses/')
for pose in poses:
print(">> Working on pose : " + pose)
subdirs = os.listdir('Poses/' + pose + '/')
for subdir in subdirs:
files = os.listdir('Poses/' + pose + '/' + subdir + '/')
print(">> Working on examples : " + subdir)
for file in files:
if(file.endswith(".png")):
path = 'Poses/' + pose + '/' + subdir + '/' + file
# Read image
im = cv2.imread(path)
height, width, channels = im.shape
if not height == width == 28:
# Resize image
im = cv2.resize(im, (28, 28), interpolation=cv2.INTER_AREA)
# Write image
cv2.imwrite(path, im)
1
https://gitee.com/zzb32/HandPose.git
git@gitee.com:zzb32/HandPose.git
zzb32
HandPose
HandPose
master

搜索帮助

53164aa7 5694891 3bd8fe86 5694891