From a09c819f5c65d7fe2b0f64824135c3043367cf69 Mon Sep 17 00:00:00 2001 From: Amine GHOZLANE Date: Mon, 24 Jun 2024 15:38:29 +0200 Subject: [PATCH] Fix calculation issue --- meteor/phylogeny.py | 58 ++++++++++++++++----------------------------- 1 file changed, 20 insertions(+), 38 deletions(-) diff --git a/meteor/phylogeny.py b/meteor/phylogeny.py index 5294d30..0baf3c9 100644 --- a/meteor/phylogeny.py +++ b/meteor/phylogeny.py @@ -160,44 +160,26 @@ def execute(self) -> None: msp_count, ) elif len(cleaned_seqs) >= 4: - if info_sites < self.meteor.threads: - # Compute trees - result = check_call( - [ - "raxml-ng", - "--threads", - str(info_sites), - "--search1", - "--msa", - temp_clean.name, - "--model", - "GTR+G", - "--redo", - "--force", - "perf_threads", # not working with raxml-ng-mpi - "--prefix", - str(tree_file.resolve()), - ] - ) - else: - # Compute trees - result = check_call( - [ - "raxml-ng", - "--threads", - str(self.meteor.threads), - "--search1", - "--msa", - temp_clean.name, - "--model", - "GTR+G", - "--redo", - "--force", - "perf_threads", # not working with raxml-ng-mpi - "--prefix", - str(tree_file.resolve()), - ] - ) + # Compute trees + result = check_call( + [ + "raxml-ng", + "--threads", + "auto{{{}}}".format(self.meteor.threads), + "--workers", + "auto", + "--search1", + "--msa", + temp_clean.name, + "--model", + "GTR+G", + "--redo", + "--force", + "perf,msa", # not working with raxml-ng-mpi + "--prefix", + str(tree_file.resolve()), + ] + ) if result != 0: logging.error("raxml-ng failed with return code %d", result) else: