def fetch_symbol_images():
symbols_images = {}
source_image_path = "../zener-images"
for root, dirs, files in os.walk(source_image_path):
for f in files:
if f.endswith(".png"):
image_name = string.split(f, ".")
image = Image.open(source_image_path + "/" + f)
symbols_images[image_name[0]] = image
return symbols_images
# https://github.com/nathancahill/snippets/blob/master/image_perspective.py
# pa - starting points
# pb - ending points
# func will find the relevant coeffs that will result in the transformation of pa to pb
# and this will be used to transform the entire image
评论列表
文章目录