whycxzp
2022-07-01 7fd03799ebe950aa0dd006b75c68d8a35bc566ce
人脸路径增加判断
1个文件已修改
20 ■■■■■ 已修改文件
src/com/fgkj/actions/face/FaceIdentifyAction.java 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/com/fgkj/actions/face/FaceIdentifyAction.java
@@ -417,7 +417,12 @@
                    }else{
                        for (User_inf temp:userInfList){
                            String filePath = temp.getFace().getUrl();
                            ImageInfo imageInfo2 = ImageFactory.getRGBData(new File(filePath));
                            File file = new File(filePath);
                            //不存在则不继续执行
                            if(!file.exists()){
                                continue;
                            }
                            ImageInfo imageInfo2 = ImageFactory.getRGBData(file);
                            model = FaceIdentifyUtil.faceCompare(faceEngine, imageInfo, imageInfo2);
                            //对比成功,记录用户登录信息
                            if(model.getCode()==1){
@@ -480,19 +485,6 @@
        return url;
    }
    public static void main(String[] args){
        try {
            FileOutputStream fot = new FileOutputStream("F:\\File\\1.txt");
            String str = "PMP成绩5A通过!";
            fot.write(str.getBytes("UTF-8"));
            fot.flush();
            fot.close();
        }catch (Exception e){
            e.printStackTrace();
            return;
        }
        System.out.println("上面发生异常,下面代码还是执行了!!!");
    }
    public void setJson(String json) {
        this.json = json;