smirarab / pasta

PASTA (Practical Alignment using SATe and Transitivity)
GNU General Public License v3.0
85 stars 26 forks source link

error on identical alignments #39

Closed B10KGenomes closed 5 years ago

B10KGenomes commented 5 years ago

PASTA fails when alignments are identical or mostly invariant. Should halt after initial iteration.


Exception in thread Thread-1:
Traceback (most recent call last):
  File "/project/bird10k/alns/pasta/pasta/scheduler.py", line 197, in __call__
    job.results = job.result_processor()
  File "/project/bird10k/alns/pasta/pasta/tools.py", line 1087, in <lambda>
    step_num=step_num)
  File "/project/bird10k/alns/pasta/pasta/tools.py", line 127, in read_fasttree_results
    raise Exception(message)
Exception: FastTree did not report a log-likelhood for the data: the data set is probably too weird

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/jossti/miniconda3/envs/aln/lib/python3.7/threading.py", line 917, in _bootstrap_inner
    self.run()
  File "/home/jossti/miniconda3/envs/aln/lib/python3.7/threading.py", line 865, in run
    self._target(*self._args, **self._kwargs)
  File "/project/bird10k/alns/pasta/pasta/scheduler.py", line 209, in __call__
    traceback.print_exc(file=err)
  File "/home/jossti/miniconda3/envs/aln/lib/python3.7/traceback.py", line 163, in print_exc
    print_exception(*sys.exc_info(), limit=limit, file=file, chain=chain)
  File "/home/jossti/miniconda3/envs/aln/lib/python3.7/traceback.py", line 105, in print_exception
    print(line, file=file, end="")
TypeError: a bytes-like object is required, not 'str'
smirarab commented 5 years ago

Since PASTA seeks to produce both alignments and trees, in a situation like this, it should not be able to finish because no tree can be obtained. Thus, the current behavior is as expected (if a bit annoying if all you care about is the alignment).