Algorithmic Changes to photoreceptor.py