def val(self):
    global logger
    if self.__eval:
        logger.info('***********Start Evaluation****************')
        start = time.time()
        mAP = 0
        with torch.no_grad():
            (APs, inference_time) = Evaluator(self.__model, showatt=False).APs_voc(self.__multi_scale_val, self.__flip_val)
            for i in APs:
                logger.info('{} --> mAP : {}'.format(i, APs[i]))
                mAP += APs[i]
            mAP = (mAP / self.__num_class)
            logger.info('mAP:{}'.format(mAP))
            logger.info('inference time: {:.2f} ms'.format(inference_time))
        end = time.time()
        logger.info('  ===val cost time:{:.4f}s'.format((end - start)))
def val(self):
    global logger
    if self.__eval:
        logger.info('***********Start Evaluation****************')
        start = time.time()
        mAP = 0
        with torch.no_grad():
            (APs, inference_time) = Evaluator(self.__model, showatt=False).APs_voc(self.__multi_scale_val, self.__flip_val)
            for i in APs:
                logger.info('{} --> mAP : {}'.format(i, APs[i]))
                mAP += APs[i]
            mAP = (mAP / self.__num_class)
            logger.info('mAP:{}'.format(mAP))
            logger.info('inference time: {:.2f} ms'.format(inference_time))
        end = time.time()
        logger.info('  ===val cost time:{:.4f}s'.format((end - start)))