|
|
|
@ -37,6 +37,7 @@ import javax.annotation.Resource;
|
|
|
|
import java.awt.*;
|
|
|
|
import java.awt.*;
|
|
|
|
import java.io.File;
|
|
|
|
import java.io.File;
|
|
|
|
import java.math.BigDecimal;
|
|
|
|
import java.math.BigDecimal;
|
|
|
|
|
|
|
|
import java.math.RoundingMode;
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.*;
|
|
|
|
import java.util.*;
|
|
|
|
import java.util.stream.Collectors;
|
|
|
|
import java.util.stream.Collectors;
|
|
|
|
@ -145,9 +146,11 @@ public class OcrIdentifyServiceImpl extends ServiceImpl<OcrIdentifyMapper, OcrId
|
|
|
|
//ocrIdentifyDetail.setStatus(taskStatus);
|
|
|
|
//ocrIdentifyDetail.setStatus(taskStatus);
|
|
|
|
ocrIdentifyDetail.setStatus("");
|
|
|
|
ocrIdentifyDetail.setStatus("");
|
|
|
|
ocrIdentifyDetail.setMessage(message);
|
|
|
|
ocrIdentifyDetail.setMessage(message);
|
|
|
|
ocrIdentifyDetail.setOcrTime(new BigDecimal(ocrTime).setScale(2,BigDecimal.ROUND_HALF_UP).doubleValue());
|
|
|
|
ocrIdentifyDetail.setOcrTime(new BigDecimal(ocrTime).setScale(2, RoundingMode.HALF_UP).doubleValue());
|
|
|
|
ocrIdentifyDetail.setNluTime(new BigDecimal(nluTime).setScale(2,BigDecimal.ROUND_HALF_UP).doubleValue());
|
|
|
|
ocrIdentifyDetail.setNluTime(new BigDecimal(nluTime).setScale(2, RoundingMode.HALF_UP).doubleValue());
|
|
|
|
ocrIdentifyDetail.setSemanticResult(semanticResult.getJSONObject("semantic_result").toJSONString());
|
|
|
|
if (semanticResult!=null && semanticResult.getJSONObject("semantic_result")!=null) {
|
|
|
|
|
|
|
|
ocrIdentifyDetail.setSemanticResult(semanticResult.getJSONObject("semantic_result").toJSONString());
|
|
|
|
|
|
|
|
}
|
|
|
|
ocrIdentifyDetailService.save(ocrIdentifyDetail);
|
|
|
|
ocrIdentifyDetailService.save(ocrIdentifyDetail);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
//===================
|
|
|
|
//===================
|
|
|
|
|