summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNilesh Patra <nilesh@debian.org>2022-05-29 07:53:26 +0200
committerNilesh Patra <nilesh@debian.org>2022-05-29 07:53:26 +0200
commitc191692bfa00e750864dddc488c03342719df4c3 (patch)
treee54ef6363a858dda463e7fd1a56e6f87aecffca4
parent8a03dc7330590d5818bbb47807c9d21daafd3cec (diff)
import module in needed functions to fix circular import
Last-Update: 2021-06-30 Gbp-Pq: Name fix-circular-import.patch
-rw-r--r--mirtop/bam/bam.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/mirtop/bam/bam.py b/mirtop/bam/bam.py
index 1528b6a..1295729 100644
--- a/mirtop/bam/bam.py
+++ b/mirtop/bam/bam.py
@@ -15,7 +15,6 @@ import mirtop.libs.logger as mylog
from mirtop.mirna.realign import isomir, hits, reverse_complement
from mirtop.mirna.mapper import get_primary_transcript, guess_database
from mirtop.bam import filter
-from mirtop.gff import body
from mirtop.mirna.annotate import annotate
from mirtop.libs import sql
@@ -72,6 +71,7 @@ def read_bam(bam_fn, args, clean=True):
def low_memory_bam(bam_fn, sample, out_handle, args):
if args.genomic:
raise ValueError("low-memory option is not compatible with genomic coordinates.")
+ from mirtop.gff import body
precursors = args.precursors
bam_fn = _sam_to_bam(bam_fn)
bam_fn = _bam_sort(bam_fn)
@@ -100,6 +100,7 @@ def low_memory_bam(bam_fn, sample, out_handle, args):
def low_memory_genomic_bam(bam_fn, sample, out_handle, args):
logger.info("Reading BAM file in low memory mode.")
logger.warning("This is under development and variants can be unexact.")
+ from mirtop.gff import body
precursors = args.precursors
bam_fn = _sam_to_bam(bam_fn)
bam_fn = _bam_sort(bam_fn)