audio-reactive-led-strip/python/image.py
Scott Lawson 47aa7bfcdd Added a slider for contrast adjustment
Added a slider and variables for adjusting the contrast of the
visualization.
2017-01-03 19:16:45 -08:00

8 lines
237 B
Python

import numpy as np
from skimage.exposure import rescale_intensity, equalize_hist, adjust_sigmoid, equalize_adapthist
def contrast(x, gain=100.0):
return adjust_sigmoid(x, gain=gain/10.0)
def equalize(x):
return equalize_hist(x)