modified normalize.py