A few changes in main script and testing file