Changeset 34657 in osm for applications/editors/josm/plugins/OSMRecPlugin/src
- Timestamp:
- 2018-09-15T14:27:03+02:00 (6 years ago)
- Location:
- applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/core/TrainWorker.java
r34539 r34657 126 126 System.out.println("fold1"); 127 127 crossValidateFold(0, 4, 4, 5, false, param); //4-1 128 setProgress(4*((5* (trainProgress++))/confParams.length));128 setProgress(4*((5*trainProgress++)/confParams.length)); 129 129 130 130 foldScore1 = foldScore1 + score1; … … 134 134 System.out.println("fold2"); 135 135 crossValidateFold(1, 5, 0, 1, false, param); 136 setProgress(4*((5* (trainProgress++))/confParams.length));136 setProgress(4*((5*trainProgress++)/confParams.length)); 137 137 138 138 foldScore1 = foldScore1 + score1; … … 142 142 System.out.println("fold3"); 143 143 crossValidateFold(0, 5, 1, 2, true, param); 144 setProgress(4*((5* (trainProgress++))/confParams.length));144 setProgress(4*((5*trainProgress++)/confParams.length)); 145 145 146 146 foldScore1 = foldScore1 + score1; … … 150 150 System.out.println("fold4"); 151 151 crossValidateFold(0, 5, 2, 3, true, param); 152 setProgress(4*((5* (trainProgress++))/confParams.length));152 setProgress(4*((5*trainProgress++)/confParams.length)); 153 153 154 154 foldScore1 = foldScore1 + score1; … … 158 158 System.out.println("fold5"); 159 159 crossValidateFold(0, 5, 3, 4, true, param); 160 setProgress(4*((5* (trainProgress++))/confParams.length));160 setProgress(4*((5*trainProgress++)/confParams.length)); 161 161 162 162 foldScore1 = foldScore1 + score1; … … 170 170 171 171 } 172 System.out.println(4*((5* (trainProgress++))/confParams.length));172 System.out.println(4*((5*trainProgress++)/confParams.length)); 173 173 bestConfParam = bestC; 174 174 System.out.println("best c param= " + bestC + ", score: " + bestScore/5); … … 182 182 for (int g = a*testSize; g < b*testSize; g++) { // 0~~1~~2~~3~~4~~5 183 183 if (skip) { 184 if (g == (c)*testSize) {184 if (g == c*testSize) { 185 185 g = (c+1)*testSize; 186 186 } -
applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/extractor/Analyzer.java
r34539 r34657 185 185 @Override 186 186 public int compare(Map.Entry<String, Integer> o1, Map.Entry<String, Integer> o2) { 187 return (o2.getValue()).compareTo(o1.getValue());187 return o2.getValue().compareTo(o1.getValue()); 188 188 } 189 189 }); -
applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/features/ClassFeatures.java
r32404 r34657 56 56 //so this condition check will remain for now 57 57 58 if (! (sortedIndirectIDs.contains(indirectID))) {58 if (!sortedIndirectIDs.contains(indirectID)) { 59 59 sortedIndirectIDs.add(indirectID); 60 60 //wayNode.getIndexVector().put(indirectID, 1.0); -
applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/features/OSMClassification.java
r32404 r34657 54 54 //so this condition check will remain for now 55 55 56 if (! (sortedIndirectIDs.contains(indirectID))) {56 if (!sortedIndirectIDs.contains(indirectID)) { 57 57 sortedIndirectIDs.add(indirectID); 58 58 //wayNode.getIndexVector().put(indirectID, 1.0); -
applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/parsers/OSMParser.java
r34539 r34657 177 177 //the nodes must be more than 3, because jts does not allow a construction of a linear ring with less points. 178 178 179 if (!( (wayTmp.getTagKeyValue().containsKey("barrier")) || wayTmp.getTagKeyValue().containsKey("highway"))) {179 if (!(wayTmp.getTagKeyValue().containsKey("barrier") || wayTmp.getTagKeyValue().containsKey("highway"))) { 180 180 //this is not a barrier nor a road, so construct a polygon geometry 181 181 -
applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/personalization/HistoryParser.java
r34539 r34657 191 191 //the nodes must be more than 3, because jts does not allow a construction of a linear ring with less points. 192 192 193 if (!( (wayTmp.getTagKeyValue().containsKey("barrier")) || wayTmp.getTagKeyValue().containsKey("highway"))) {193 if (!(wayTmp.getTagKeyValue().containsKey("barrier") || wayTmp.getTagKeyValue().containsKey("highway"))) { 194 194 //this is not a barrier nor a road, so construct a polygon geometry 195 195 -
applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/personalization/TrainByUser.java
r34539 r34657 188 188 for (int g = a*testSize; g < b*testSize; g++) { // 0~~1~~2~~3~~4~~5 189 189 if (skip) { 190 if (g == (c)*testSize) {190 if (g == c*testSize) { 191 191 g = (c+1)*testSize; 192 192 }
Note:
See TracChangeset
for help on using the changeset viewer.