Closed milo-melo closed 2 years ago
I tried using flair.py collapse-range and it's still running after a day with 16 threads for a single nanopore cDNA sample. This is way more than the 3.5hours of time that's listed in the wiki. What are the minimum system requirements needed to run this package?
Hi there, I also had the same problem and I guess you have the same problem as mine also stopped at the same step. It seems that it is because of their recent update. They included a parameter, mm2_args
, to pass minimap2 arguments to the collapse
function. However, when the argument is empty, minimap2 falsely consider that as an input (which is an empty directory). You can directly go to your tmp file (e.g. /tmp) and check the log (*.mm2_stderr) inside and it should mention something, like [ERROR] failed to open file ''
.
If you do not have any minimap2 argument to pass, you can temporarily fix this problem by changing the code at line 554-555 in flair.py from
if subprocess.call([args.m, '-a', '-t', args.t, '-N', '4'] + args.mm2_args + [args.o+'firstpass.fa'] + args.r, \ stdout=open(alignout+'sam', 'w'), stderr=open(alignout+'mm2_stderr', 'w')):
to
if subprocess.call([args.m, '-a', '-t', args.t, '-N', '4'] + [args.o+'firstpass.fa'] + args.r, \ stdout=open(alignout+'sam', 'w'), stderr=open(alignout+'mm2_stderr', 'w')):
.
Obviously, I just deleted the passing of minimap2 arguments.
Hi Cheuk-Ting,
That worked. Thank you very much for the detailed solution.
An alternative to the above solution could be if one wanted to input mm2_args at some point further downstream during their analysis, replacing 553-556 with:
if args.mm2_args == "":
mm2_args = []
else:
mm2_args = args.mm2_args.split(',')
if subprocess.call([args.m, '-a', '-t', args.t, '-N', '4'] + mm2_args + [args.o+'firstpass.fa'] + args.r, \
stdout=open(alignout+'sam', 'w'), stderr=open(alignout+'mm2_stderr', 'w')):
raise Exception([args.m, '-a', '-t', args.t, '-N', '4'] + mm2_args + [args.o+'firstpass.fa'] + args.r)
Hello,
I've been using the default command for flair collapse: python3 flair.py collapse -g ensembl.GRCh38.fa -q file_all_corrected.bed r reads.fastq
and the program terminates at:
Annotated ends extracted from GTF Read data extracted Single-exon genes grouped, collapsing Renaming isoforms Aligning reads to first-pass isoform reference
There are collapse.firstpass.fa and bed output files but the script doesn't progress to the second pass read assignment. Am I missing an argument?