Small script to stack astro photos
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
import glob | |
import sys | |
import numpy as np | |
from PIL import Image | |
def readFiles(images): | |
loaded = [np.asarray(Image.open(img)) for img in images] | |
return np.array(loaded) | |
if __name__ == "__main__": | |
r = np.max(readFiles(glob.glob(sys.argv[1])), axis=0) | |
Image.fromarray(r).save("result.jpg") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment