Skip to content

Instantly share code, notes, and snippets.

View JRiggles's full-sized avatar
👾

John Riggles / sudo whoami JRiggles

👾
View GitHub Profile
from PIL import Image
from pathlib import Path
import random
def gray_value(r, g, b):
return 0.2989 * r + 0.5870 * g + 0.1140 * b
def filter_2x2_bayer(image_file, threshold):