Added an option of using a different file as input