zoukankan      html  css  js  c++  java
  • java 打印box文件

        public void import11(){
            String path="D:\北体检阴阳性整标1116\yinbox";
            TagImgFilter tageImgFilter=new TagImgFilter();
            tageImgFilter.setEq_setId("2367ff90d4ce495ca7c55fbd87683691");        
            tageImgFilter.setEq_typeId("f7ce9ce48b8b423b89ecd9da43edb2bc");
            tageImgFilter.setNull_tagJson(false);
            List<TagImg> tagImgList=tagImgService.selectAll(tageImgFilter);
            System.out.println("size:"+tagImgList.size());
            TagType tagType = null;
            int count=0;
            for(TagImg tagimg:tagImgList){
                tagType=tagTypeService.getById(tagimg.getTypeId());
                System.out.println(count);
                count++;
                //String md5=tagimg.getImgMd5();
                String id=tagimg.getId();
                FileUtil util=new FileUtil();
                String json=tagimg.getTagJson();
                JSONArray array=JSONArray.parseArray(json);
                if(array!=null && array.size()>0){
                    for(int i=0;i<array.size();i++){
                        JSONObject obj = array.getJSONObject(i);
                        Double x=obj.getDouble("x");
                        Double y=obj.getDouble("y");
                        Double width=obj.getDouble("width");
                        Double height=obj.getDouble("height");
                        //String classname=obj.getString("classname");
                        String typename=tagType.getName();
                        String str=x.intValue()+" "+y.intValue()+" "+(int)(x+width.intValue())+" "+(int)(y+height.intValue())+" "+typename;
                        //String str=x.intValue()+" "+y.intValue()+" "+(int)(x+width.intValue())+" "+(int)(y+height.intValue())+" "+"主动脉";
                        //util.toFile(str, path, md5+".box");
                        util.toFile(str, path, id+".box");
                    }
                }
    //            if(count==1000){
    //                  break;
    //              }
            }
            
        }
  • 相关阅读:
    HTTP content-type
    python3学习--安装OCR识别库tesserocr
    http post get 类库 httphelper
    MD5
    解决python3中cv2读取中文路径的问题
    web api获得Post数据为空的解决办法
    python3项目打包成exe可执行程序
    pip install 使用国内镜像
    win10家庭版组策略安装
    在国企的日子(第七章 转正)
  • 原文地址:https://www.cnblogs.com/lely/p/10364608.html
Copyright © 2011-2022 走看看