Skip to content

Instantly share code, notes, and snippets.

@zorix
Created October 2, 2017 18:22
Show Gist options
  • Select an option

  • Save zorix/571392a1df0ae88aa16625406f12fefe to your computer and use it in GitHub Desktop.

Select an option

Save zorix/571392a1df0ae88aa16625406f12fefe to your computer and use it in GitHub Desktop.
Rozwiązanie do misji 11 - https://www.youtube.com/watch?v=lDsigXCo5TA
from PIL import Image, ImageChops
from os import listdir
workDir = './data/' # dir with extracted files
onlyfiles = [f for f in listdir(workDir) if '.' not in f]
base = Image.open(workDir + onlyfiles[0])
for file in onlyfiles[1:]:
im = Image.open(workDir + file)
base = ImageChops.add(im, base)
base.save("output.png")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment