diff --git a/htroot/yacy/search.java b/htroot/yacy/search.java index 1a4193ea7..6877974b7 100644 --- a/htroot/yacy/search.java +++ b/htroot/yacy/search.java @@ -91,7 +91,7 @@ public final class search { } final long timestamp = System.currentTimeMillis(); - plasmaSearchQuery squery = new plasmaSearchQuery(keyhashes, new String[]{plasmaSearchQuery.ORDER_QUALITY, plasmaSearchQuery.ORDER_DATE}, + plasmaSearchQuery squery = new plasmaSearchQuery(keyhashes, new String[]{plasmaSearchQuery.ORDER_YBR, plasmaSearchQuery.ORDER_DATE, plasmaSearchQuery.ORDER_QUALITY}, count, duetime, ".*"); prop = sb.searchFromRemote(squery); diff --git a/source/de/anomic/plasma/plasmaRankingRCIEvaluation.java b/source/de/anomic/plasma/plasmaRankingRCIEvaluation.java index 6523bddd9..de3e48b18 100644 --- a/source/de/anomic/plasma/plasmaRankingRCIEvaluation.java +++ b/source/de/anomic/plasma/plasmaRankingRCIEvaluation.java @@ -52,6 +52,7 @@ import java.net.MalformedURLException; import java.util.Iterator; import java.util.HashMap; import java.util.HashSet; +import java.util.TreeSet; import de.anomic.kelondro.kelondroAttrSeq; import de.anomic.server.serverCodings; @@ -169,9 +170,9 @@ public class plasmaRankingRCIEvaluation { return partition.length - 1; } - public static HashSet[] genRankingTable(kelondroAttrSeq rci, int[] partition) { - HashSet[] ranked = new HashSet[partition.length]; - for (int i = 0; i < partition.length; i++) ranked[i] = new HashSet(); + public static TreeSet[] genRankingTable(kelondroAttrSeq rci, int[] partition) { + TreeSet[] ranked = new TreeSet[partition.length]; + for (int i = 0; i < partition.length; i++) ranked[i] = new TreeSet(); Iterator i = rci.keys(); String key; kelondroAttrSeq.Entry entry; @@ -199,7 +200,7 @@ public class plasmaRankingRCIEvaluation { return dommap; } - public static void storeRankingTable(HashSet[] ranking, File tablePath) throws IOException { + public static void storeRankingTable(TreeSet[] ranking, File tablePath) throws IOException { String hash; String filename; if (!(tablePath.exists())) tablePath.mkdirs(); @@ -219,7 +220,7 @@ public class plasmaRankingRCIEvaluation { final kelondroAttrSeq rci = new kelondroAttrSeq(rci_file, false); int counts[] = rcieval(rci); int[] partition = interval(counts, 16); - HashSet[] ranked = genRankingTable(rci, partition); + TreeSet[] ranked = genRankingTable(rci, partition); storeRankingTable(ranked, new File(root_path, "ranking/YBR")); long seconds = java.lang.Math.max(1, (System.currentTimeMillis() - start) / 1000); System.out.println("Finished YBR generation in " + seconds + " seconds."); @@ -252,7 +253,7 @@ public class plasmaRankingRCIEvaluation { System.out.println("sum of all references: " + sum); // now print out the table - HashSet[] ranked = genRankingTable(rci, partition); + TreeSet[] ranked = genRankingTable(rci, partition); HashMap dommap = genReverseDomHash(new File(root_path, "domlist.txt")); String hash, dom; for (int i = 0; i < 9; i++) {