added a portion of data processing for evaluation of statistic loss