Updates to loader.py to accomate csv files