From a00e3023218a8034bb1e4f7d494e9e9942f83b48 Mon Sep 17 00:00:00 2001 From: Matt Hanna Date: Mon, 25 Jul 2011 14:31:40 -0400 Subject: [PATCH 1/3] Fix formatting issue. --- build.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/build.xml b/build.xml index 874a003eb..295cd95e1 100644 --- a/build.xml +++ b/build.xml @@ -489,6 +489,7 @@ + From af0b5883c3cf9141d413e9f61b3eea21c12c1991 Mon Sep 17 00:00:00 2001 From: Matt Hanna Date: Mon, 25 Jul 2011 14:36:12 -0400 Subject: [PATCH 2/3] In unstable, add a reference to DocumentedGATKFeature to vcf.jar, which is now a static dependency of UserExceptions. --- build.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/build.xml b/build.xml index fb485f0e5..81e24f58f 100644 --- a/build.xml +++ b/build.xml @@ -521,6 +521,7 @@ + From 3afcb3415d47d9450623ce810ccb1d338795dbad Mon Sep 17 00:00:00 2001 From: Mark DePristo Date: Mon, 25 Jul 2011 14:58:31 -0400 Subject: [PATCH 3/3] Max of 1000 records will be loaded and compared to avoid heap size problem. --- .../sting/gatk/walkers/diffengine/DiffEngine.java | 6 +++--- public/java/test/org/broadinstitute/sting/MD5DB.java | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/public/java/src/org/broadinstitute/sting/gatk/walkers/diffengine/DiffEngine.java b/public/java/src/org/broadinstitute/sting/gatk/walkers/diffengine/DiffEngine.java index 5f8f19892..4a4f6f6af 100644 --- a/public/java/src/org/broadinstitute/sting/gatk/walkers/diffengine/DiffEngine.java +++ b/public/java/src/org/broadinstitute/sting/gatk/walkers/diffengine/DiffEngine.java @@ -342,12 +342,12 @@ public class DiffEngine { return reader.readFromFile(file, maxElementsToRead); } - public static boolean simpleDiffFiles(File masterFile, File testFile, DiffEngine.SummaryReportParams params) { + public static boolean simpleDiffFiles(File masterFile, File testFile, int maxElementsToRead, DiffEngine.SummaryReportParams params) { DiffEngine diffEngine = new DiffEngine(); if ( diffEngine.canRead(masterFile) && diffEngine.canRead(testFile) ) { - DiffElement master = diffEngine.createDiffableFromFile(masterFile); - DiffElement test = diffEngine.createDiffableFromFile(testFile); + DiffElement master = diffEngine.createDiffableFromFile(masterFile, maxElementsToRead); + DiffElement test = diffEngine.createDiffableFromFile(testFile, maxElementsToRead); List diffs = diffEngine.diff(master, test); diffEngine.reportSummarizedDifferences(diffs, params); return true; diff --git a/public/java/test/org/broadinstitute/sting/MD5DB.java b/public/java/test/org/broadinstitute/sting/MD5DB.java index bea9eaec5..6f56fce4b 100644 --- a/public/java/test/org/broadinstitute/sting/MD5DB.java +++ b/public/java/test/org/broadinstitute/sting/MD5DB.java @@ -47,6 +47,7 @@ public class MD5DB { /** * Subdirectory under the ant build directory where we store integration test md5 results */ + private static final int MAX_RECORDS_TO_READ = 10000; public static final String LOCAL_MD5_DB_DIR = "integrationtests"; public static final String GLOBAL_MD5_DB_DIR = "/humgen/gsa-hpprojects/GATK/data/integrationtests"; @@ -232,7 +233,7 @@ public class MD5DB { // inline differences DiffEngine.SummaryReportParams params = new DiffEngine.SummaryReportParams(System.out, 20, 10, 0); - boolean success = DiffEngine.simpleDiffFiles(new File(pathToExpectedMD5File), new File(pathToFileMD5File), params); + boolean success = DiffEngine.simpleDiffFiles(new File(pathToExpectedMD5File), new File(pathToFileMD5File), MAX_RECORDS_TO_READ, params); if ( success ) System.out.printf("Note that the above list is not comprehensive. At most 20 lines of output, and 10 specific differences will be listed. Please use -T DiffObjects -R public/testdata/exampleFASTA.fasta -m %s -t %s to explore the differences more freely%n", pathToExpectedMD5File, pathToFileMD5File);