Package org.broadinstitute.gatk.engine.resourcemanagement

Examples of org.broadinstitute.gatk.engine.resourcemanagement.ThreadAllocation


        IndexedFastaSequenceFile refReader = new IndexedFastaSequenceFile(referenceFile);
        GenomeLocParser genomeLocParser = new GenomeLocParser(refReader);       

        // initialize reads
        List<SAMReaderID> bamReaders = ListFileUtils.unpackBAMFileList(samFiles,parser);
        SAMDataSource dataSource = new SAMDataSource(bamReaders,new ThreadAllocation(),null,genomeLocParser);

        // intervals
        final GenomeLocSortedSet intervalSortedSet;
        if ( intervals != null )
            intervalSortedSet = IntervalUtils.sortAndMergeIntervals(genomeLocParser, IntervalUtils.parseIntervalArguments(genomeLocParser, intervals), IntervalMergingRule.ALL);
View Full Code Here


        final Collection<SAMReaderID> samFiles = new ArrayList<>();
        final SAMReaderID readerID = new SAMReaderID(testBAM, new Tags());
        samFiles.add(readerID);

        final SAMDataSource dataSource = new SAMDataSource(samFiles, new ThreadAllocation(), null, genomeLocParser,
                false,
                ValidationStringency.STRICT,
                null,
                null,
                new ValidationExclusion(),
View Full Code Here

        final Collection<SAMReaderID> samFiles = new ArrayList<>();
        final SAMReaderID readerID = new SAMReaderID(testBAM, new Tags());
        samFiles.add(readerID);

        final SAMDataSource dataSource = new SAMDataSource(samFiles, new ThreadAllocation(), null, genomeLocParser,
                false,
                ValidationStringency.STRICT,
                null,
                null,
                new ValidationExclusion(),
View Full Code Here

        final Collection<SAMReaderID> samFiles = new ArrayList<>();
        final SAMReaderID readerID = new SAMReaderID(testBAM, new Tags());
        samFiles.add(readerID);

        final SAMDataSource dataSource = new SAMDataSource(samFiles, new ThreadAllocation(), null, genomeLocParser,
                false,
                ValidationStringency.STRICT,
                null,
                null,
                new ValidationExclusion(),
View Full Code Here

        samFiles.add(readerID);

        final List<ReadFilter> filters = new ArrayList<>();
        filters.add(new EveryTenthReadFilter());

        final SAMDataSource dataSource = new SAMDataSource(samFiles, new ThreadAllocation(), null, genomeLocParser,
                false,
                ValidationStringency.STRICT,
                null,
                null,
                new ValidationExclusion(),
View Full Code Here

        // setup the data
        readers.add(new SAMReaderID(new File(validationDataLocation+"/NA12878.chrom6.SLX.SRP000032.2009_06.selected.bam"),new Tags()));

        // the sharding strat.
        SAMDataSource data = new SAMDataSource(readers,
                new ThreadAllocation(),
                null,
                genomeLocParser,
                false,
                ValidationStringency.SILENT,
                null,
View Full Code Here

        // setup the data
        readers.add(new SAMReaderID(new File(b37GoodBAM),new Tags()));

        // use defaults
        SAMDataSource data = new SAMDataSource(readers,
                new ThreadAllocation(),
                null,
                genomeLocParser,
                false,
                ValidationStringency.SILENT,
                null,
                null,
                new ValidationExclusion(),
                new ArrayList<ReadFilter>(),
                false);

        List<SAMProgramRecord> defaultProgramRecords = data.getHeader().getProgramRecords();
        assertTrue(defaultProgramRecords.size() != 0, "testRemoveProgramRecords: No program records found when using default constructor");

        boolean removeProgramRecords = false;
        data = new SAMDataSource(readers,
                new ThreadAllocation(),
                null,
                genomeLocParser,
                false,
                ValidationStringency.SILENT,
                null,
                null,
                new ValidationExclusion(),
                new ArrayList<ReadFilter>(),
                Collections.<ReadTransformer>emptyList(),
                false,
                (byte) -1,
                removeProgramRecords,
                false,
                null, IntervalMergingRule.ALL);

        List<SAMProgramRecord> dontRemoveProgramRecords = data.getHeader().getProgramRecords();
        assertEquals(dontRemoveProgramRecords, defaultProgramRecords, "testRemoveProgramRecords: default program records differ from removeProgramRecords = false");

        removeProgramRecords = true;
        data = new SAMDataSource(readers,
                new ThreadAllocation(),
                null,
                genomeLocParser,
                false,
                ValidationStringency.SILENT,
                null,
View Full Code Here

    @Test(expectedExceptions = UserException.class)
    public void testFailOnReducedReads() {
        readers.add(new SAMReaderID(new File(privateTestDir + "old.reduced.bam"), new Tags()));

        SAMDataSource data = new SAMDataSource(readers,
                new ThreadAllocation(),
                null,
                genomeLocParser,
                false,
                ValidationStringency.SILENT,
                null,
View Full Code Here

    @Test(expectedExceptions = UserException.class)
    public void testFailOnReducedReadsRemovingProgramRecords() {
        readers.add(new SAMReaderID(new File(privateTestDir + "old.reduced.bam"), new Tags()));

        SAMDataSource data = new SAMDataSource(readers,
                new ThreadAllocation(),
                null,
                genomeLocParser,
                false,
                ValidationStringency.SILENT,
                null,
View Full Code Here

    }

    protected SAMDataSource composeDataSource() {
        checkHeaderExists();
        final Set<SAMReaderID> readerIDs = new HashSet<>(1);
        final ThreadAllocation ta = new ThreadAllocation();
        final Integer numFileHandles = 1; // I believe that any value would do but need to confirm.
        final boolean useOriginalBaseQualities = true;
        final ValidationStringency strictness = ValidationStringency.LENIENT;
        final Integer readBufferSize = 1; // not relevant.
        final DownsamplingMethod downsamplingMethod = DownsamplingMethod.NONE;
View Full Code Here

TOP

Related Classes of org.broadinstitute.gatk.engine.resourcemanagement.ThreadAllocation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.