fix bug in HGC energy weights