Resolving merge conflicts

This commit is contained in:
Eric Banks 2012-04-12 09:51:55 -04:00
commit 33a8bdd75f
3 changed files with 16 additions and 2 deletions

View File

@ -112,8 +112,11 @@ public class UnifiedArgumentCollection {
/**
* If there are more than this number of alternate alleles presented to the genotyper (either through discovery or GENOTYPE_GIVEN ALLELES),
* then only this many alleles will be used. Note that genotyping sites with many alternate alleles is both CPU and memory intensive.
* then only this many alleles will be used. Note that genotyping sites with many alternate alleles is both CPU and memory intensive and it
* scales exponentially based on the number of alternate alleles. Unless there is a good reason to change the default value, we highly recommend
* that you not play around with this parameter.
*/
@Advanced
@Argument(fullName = "max_alternate_alleles", shortName = "maxAlleles", doc = "Maximum number of alternate alleles to genotype", required = false)
public int MAX_ALTERNATE_ALLELES = 3;

View File

@ -39,6 +39,8 @@ import org.broadinstitute.sting.gatk.walkers.annotator.interfaces.AnnotatorCompa
import org.broadinstitute.sting.utils.SampleUtils;
import org.broadinstitute.sting.utils.baq.BAQ;
import org.broadinstitute.sting.utils.codecs.vcf.*;
import org.broadinstitute.sting.utils.exceptions.UserException;
import org.broadinstitute.sting.utils.variantcontext.GenotypeLikelihoods;
import org.broadinstitute.sting.utils.variantcontext.VariantContext;
import org.broadinstitute.sting.utils.variantcontext.VariantContextUtils;
@ -214,6 +216,10 @@ public class UnifiedGenotyper extends LocusWalker<List<VariantCallContext>, Unif
*
**/
public void initialize() {
// check for a bad max alleles value
if ( UAC.MAX_ALTERNATE_ALLELES > GenotypeLikelihoods.MAX_ALLELES_THAT_CAN_BE_GENOTYPED )
throw new UserException.BadArgumentValue("max_alternate_alleles", "the maximum possible value is " + GenotypeLikelihoods.MAX_ALLELES_THAT_CAN_BE_GENOTYPED);
// warn the user for misusing EMIT_ALL_SITES
if ( UAC.OutputMode == UnifiedGenotyperEngine.OUTPUT_MODE.EMIT_ALL_SITES &&
UAC.GenotypingMode == GenotypeLikelihoodsCalculationModel.GENOTYPING_MODE.DISCOVERY &&

View File

@ -210,7 +210,12 @@ public abstract class AbstractVCFCodec implements FeatureCodec, NameAwareCodec {
final List<Allele> alleles = parseAlleles(ref, alts, lineNo);
// find out our location
final int start = Integer.valueOf(locParts[1]);
int start = 0;
try {
start = Integer.valueOf(locParts[1]);
} catch (Exception e) {
generateException("the value in the POS field must be an integer but it was " + locParts[1], lineNo);
}
int stop = start;
// ref alleles don't need to be single bases for monomorphic sites