Cleaned Up utils.py