debugged cluster and input.py