From ff4d23ffd75231d342cd0714bf906cda45b147b6 Mon Sep 17 00:00:00 2001 From: danielgeiszler Date: Fri, 20 Aug 2021 12:17:51 -0700 Subject: [PATCH] Bump to v1.1.1 --- build.gradle | 2 +- src/edu/umich/andykong/ptmshepherd/PTMShepherd.java | 2 +- src/edu/umich/andykong/ptmshepherd/core/MSFMGFFile.java | 9 +++++++-- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/build.gradle b/build.gradle index ec9453f..1dd704a 100644 --- a/build.gradle +++ b/build.gradle @@ -27,7 +27,7 @@ repositories { sourceCompatibility = '1.8' targetCompatibility = '1.8' -version = '1.1.0' +version = '1.1.1' application { // Define the main class for the application diff --git a/src/edu/umich/andykong/ptmshepherd/PTMShepherd.java b/src/edu/umich/andykong/ptmshepherd/PTMShepherd.java index 6e04b77..bb5cad8 100644 --- a/src/edu/umich/andykong/ptmshepherd/PTMShepherd.java +++ b/src/edu/umich/andykong/ptmshepherd/PTMShepherd.java @@ -26,7 +26,7 @@ public class PTMShepherd { public static final String name = "PTM-Shepherd"; - public static final String version = "1.1.0"; + public static final String version = "1.1.1"; static HashMap params; static TreeMap> datasets; diff --git a/src/edu/umich/andykong/ptmshepherd/core/MSFMGFFile.java b/src/edu/umich/andykong/ptmshepherd/core/MSFMGFFile.java index 10e33e3..96d7f64 100644 --- a/src/edu/umich/andykong/ptmshepherd/core/MSFMGFFile.java +++ b/src/edu/umich/andykong/ptmshepherd/core/MSFMGFFile.java @@ -137,11 +137,12 @@ else if (cline.equals("END IONS")) int iend = (i + 1) * BLOCKSIZE; //end scan 500 int ilinestart = scanStarts[istart]; //start at line corresponding to line 0 (0) int ilineend; - if (iend > scanC) { + //System.out.println(istart + "\t" + iend + "\t" + i + "\t" + scanC); + if (iend >= scanC) { iend = scanC; ilineend = fileLines.size(); //last line } else - ilineend = scanStarts[iend + 1] - 1; //end at line corresponding to line before scan 501 + ilineend = scanStarts[iend]; //end at line corresponding to line before scan 501 futureList.add(executorService.submit(() -> processMSFMGFSpectraBlock(fileLines, ilinestart, ilineend))); } @@ -150,6 +151,8 @@ else if (cline.equals("END IONS")) for (Future future : futureList) { //checks to make sure all threads are done future.get(); } + + //TEST TODO //System.out.println("Time: " + Long.toString(System.currentTimeMillis() - t1)); //todo } @@ -165,6 +168,8 @@ private void processMSFMGFSpectraBlock(ArrayList lines, int istart, int ArrayList cspecLines = new ArrayList<>(); String line; + int nScans = 0; + for (int i = istart; i < iend; i++) { line = lines.get(i); cspecLines.add(line);