gen_avg.py takes problem dir as input parameter