cleaning of renderer.py