Skip to content

Commit

Permalink
Merge branch 'tandem_tweaks_rebased' into 'dev'
Browse files Browse the repository at this point in the history
better handling of abpoa errors

See merge request research/medaka!568
  • Loading branch information
mwykes committed Oct 24, 2023
2 parents 8b83bf3 + 08c9ef7 commit cbf182f
Show file tree
Hide file tree
Showing 5 changed files with 176 additions and 79 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- An issue with co-ordinate handling in computing variants from alignments.
### Added
- Ability to use basecaller model name as --model argument.
- Better handling or errors when running abpoa.

## [v1.11.0]
### Fixed
Expand Down
6 changes: 6 additions & 0 deletions medaka/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@
sys.stderr.write(
"Cannot import pyabpoa, some features may not be available.\n")
abpoa = None
try:
import wurlitzer
except ImportError:
sys.stderr.write(
"Cannot import wurlitzer, some features may not be available.\n")
wurlitzer = None


def check_minimap2_version():
Expand Down
11 changes: 7 additions & 4 deletions medaka/medaka.py
Original file line number Diff line number Diff line change
Expand Up @@ -531,10 +531,13 @@ def medaka_parser():
help='Sample sex, required for appropriate handling of X/Y chromosomes including PAR regions.')
trparser.add_argument('output', help='Output directory.')
trparser.add_argument('--phasing', choices=set(medaka.tandem.phasing_options.keys()),
default='hybrid', help='Phasing method. prephased: '
'use HP bam tags. abpoa: abpoa diploid clustering. '
'hybrid: try prephased, use abpoa when either '
'haplotype has < --depth coverage.')
default='hybrid', help='Phasing method. '
'prephased: use HP bam tags. '
'abpoa: abpoa diploid clustering. '
'hybrid: try prephased, use abpoa when either haplotype has < --depth '
'coverage.'
'unphased: assume sample is haploid / homozygous in target regions.'
)
trparser.add_argument('--depth', type=int, default=3,
help='Minimum reads per haplotype.')
trparser.add_argument('--min_mapq', type=int, default=5,
Expand Down
Loading

0 comments on commit cbf182f

Please sign in to comment.