public abstract class AssemblyRegionWalker extends WalkerBase
assemblyRegionEvaluator()
to provide a means of determining whether a site is active or not, as well as
apply(org.broadinstitute.hellbender.engine.AssemblyRegion, org.broadinstitute.hellbender.engine.ReferenceContext, org.broadinstitute.hellbender.engine.FeatureContext)
to process each region. Authors must also implement methods providing default values for the
various traversal parameters.
Each region passed to apply(org.broadinstitute.hellbender.engine.AssemblyRegion, org.broadinstitute.hellbender.engine.ReferenceContext, org.broadinstitute.hellbender.engine.FeatureContext)
will come pre-marked as either "active" or "inactive" using the results of the
configured assemblyRegionEvaluator()
. The assemblyRegionEvaluator()
is used to evaluate the probability
that each individual locus is active, and these probabilities are used to determine the bounds of each active and
inactive region.
apply(org.broadinstitute.hellbender.engine.AssemblyRegion, org.broadinstitute.hellbender.engine.ReferenceContext, org.broadinstitute.hellbender.engine.FeatureContext)
will be called once for each active AND inactive region, and it is up to the implementation how to
handle/process active vs. inactive regions.
Internally, the reads are loaded in chunks called read shards, which are then subdivided into active/inactive regions
for processing by the tool implementation. One read shard is created per contig.Modifier and Type | Field and Description |
---|---|
AssemblyRegionArgumentCollection |
assemblyRegionArgs |
protected java.lang.String |
assemblyRegionOut
If provided, this walker will write out its assembly regions
to this file in the IGV formatted TAB-delimited output:
http://www.broadinstitute.org/software/igv/IGV
Intended to make debugging the active region calculations easier
|
addOutputSAMProgramRecord, addOutputVCFCommandLine, cloudIndexPrefetchBuffer, cloudPrefetchBuffer, createOutputBamIndex, createOutputBamMD5, createOutputVariantIndex, createOutputVariantMD5, disableBamIndexCaching, features, intervalArgumentCollection, lenientVCFProcessing, outputSitesOnlyVCFs, progressMeter, readArguments, referenceArguments, SECONDS_BETWEEN_PROGRESS_UPDATES_NAME, seqValidationArguments
GATK_CONFIG_FILE, logger, NIO_MAX_REOPENS, NIO_PROJECT_FOR_REQUESTER_PAYS, QUIET, specialArgumentsCollection, tmpDir, useJdkDeflater, useJdkInflater, VERBOSITY
Constructor and Description |
---|
AssemblyRegionWalker() |
Modifier and Type | Method and Description |
---|---|
abstract void |
apply(AssemblyRegion region,
ReferenceContext referenceContext,
FeatureContext featureContext)
Process an individual AssemblyRegion.
|
abstract AssemblyRegionEvaluator |
assemblyRegionEvaluator() |
protected ReadsDownsampler |
createDownsampler() |
java.util.List<ReadFilter> |
getDefaultReadFilters()
Returns the default list of CommandLineReadFilters that are used for this tool.
|
java.lang.String |
getProgressMeterRecordLabel() |
protected void |
onShutdown()
Shutdown data sources.
|
protected void |
onStartup()
Initialize data sources for traversal.
|
boolean |
requiresReads()
Does this tool require reads? Traversals types and/or tools that do should override to return true.
|
boolean |
requiresReference()
Does this tool require reference data? Traversals types and/or tools that do should override to return true.
|
void |
traverse()
A complete traversal from start to finish.
|
directlyAccessEngineFeatureManager, directlyAccessEngineReadsDataSource, directlyAccessEngineReferenceDataSource
addFeatureInputsAfterInitialization, closeTool, createSAMWriter, createVCFWriter, createVCFWriter, createVCFWriter, doWork, getBestAvailableSequenceDictionary, getDefaultCloudIndexPrefetchBufferSize, getDefaultCloudPrefetchBufferSize, getDefaultToolVCFHeaderLines, getDefaultVariantAnnotationGroups, getDefaultVariantAnnotations, getGenomicsDBOptions, getHeaderForFeatures, getHeaderForReads, getHeaderForSAMWriter, getMasterSequenceDictionary, getPluginDescriptors, getReferenceDictionary, getSequenceDictionaryValidationArgumentCollection, getToolName, getTransformedReadStream, getTraversalIntervals, hasFeatures, hasReads, hasReference, hasUserSuppliedIntervals, initializeProgressMeter, makePostReadFilterTransformer, makePreReadFilterTransformer, makeReadFilter, makeVariantAnnotations, onTraversalStart, onTraversalSuccess, requiresFeatures, requiresIntervals, transformTraversalIntervals, useVariantAnnotations
customCommandLineValidation, getCommandLine, getCommandLineParser, getDefaultHeaders, getMetricsFile, getSupportInformation, getToolkitName, getToolkitShortName, getToolStatusWarning, getUsage, getVersion, instanceMain, instanceMainPostParseArgs, isBetaFeature, isExperimentalFeature, parseArgs, printLibraryVersions, printSettings, printStartupMessage, runTool, setDefaultHeaders, warnOnToolStatus
@ArgumentCollection public final AssemblyRegionArgumentCollection assemblyRegionArgs
@Argument(fullName="assembly-region-out", doc="Output the assembly region to this IGV formatted file", optional=true) protected java.lang.String assemblyRegionOut
public final boolean requiresReads()
GATKTool
requiresReads
in class GATKTool
public final boolean requiresReference()
GATKTool
requiresReference
in class GATKTool
public java.lang.String getProgressMeterRecordLabel()
getProgressMeterRecordLabel
in class GATKTool
ProgressMeter.DEFAULT_RECORD_LABEL
,
but tools may override to provide a more appropriate label (like "reads" or "regions")protected final void onStartup()
public java.util.List<ReadFilter> getDefaultReadFilters()
WellformedReadFilter
filter with all default options, as well as the ReadFilterLibrary.MappedReadFilter
.
Subclasses can override to provide alternative filters.
Note: this method is called before command line parsing begins, and thus before a SAMFileHeader is
available through {link #getHeaderForReads}.getDefaultReadFilters
in class GATKTool
protected ReadsDownsampler createDownsampler()
public void traverse()
traverse()
if you are writing a new walker base class in the
engine package that extends this class. It is not meant to be overridden by tools outside of the
engine package.protected final void onShutdown()
onShutdown
in class GATKTool
public abstract AssemblyRegionEvaluator assemblyRegionEvaluator()
public abstract void apply(AssemblyRegion region, ReferenceContext referenceContext, FeatureContext featureContext)
assemblyRegionEvaluator()
. This method will be called once for each active AND inactive region,
and it is up to the implementation how to handle/process active vs. inactive regions.region
- region to process (pre-marked as either active or inactive)referenceContext
- reference data overlapping the padded span of the assembly regionfeatureContext
- features overlapping the padded span of the assembly region