def __init__(self, multilocus_dataset, sate_team, tree, tmp_base_dir, tmp_dir_par=None, reset_recursion_index=False, **kwargs): self._job_lock = Lock() TreeHolder.__init__(self, multilocus_dataset.dataset) behavior = copy.copy(SateAlignerJob.BEHAVIOUR_DEFAULTS) behavior.update(kwargs) for k in SateAlignerJob.BEHAVIOUR_DEFAULTS.keys(): setattr(self, k, behavior[k]) self.multilocus_dataset = multilocus_dataset self.sate_team = sate_team self.tree = tree self._subjob1 = None self._subjob2 = None self._align_job_list = None self._merge_job_list = None self.tmp_base_dir = tmp_base_dir self.context_str = '' self.killed = False self._dirs_to_cleanup = [] self.tmp_dir_par = tmp_dir_par if self.tmp_dir_par == None: self.tmp_dir_par = self.tmp_base_dir if reset_recursion_index: self.__class__.RECURSION_INDEX = 0
def __init__(self, multilocus_dataset, sate_team, tree=None, name=None, **kwargs): TreeHolder.__init__(self, multilocus_dataset.dataset) self.blind_mode_is_final = True self.is_stuck_in_blind = False behavior = copy.copy(SateJob.BEHAVIOUR_DEFAULTS) behavior.update(SateAlignerJob.BEHAVIOUR_DEFAULTS) behavior.update(kwargs) self.__dict__.update(behavior) self._job_lock = Lock() self.multilocus_dataset = multilocus_dataset self.sate_team = sate_team self.tree = tree self.score = None self.best_score = None self._tree_build_job = None self._sate_decomp_job = None self._reset_jobs() self._status_message_func = kwargs.get('status_messages') # right now max_subproblem_size can be an integer or proportion. # These two run modes should be separate parameters! # if self.max_subproblem_size <= 1.0: # self.max_subproblem_size *= alignment.get_num_taxa() # self.max_subproblem_size = max(1, int(round(self.max_subproblem_size))) if isinstance(self.break_strategy, str): self.break_strategy = [self.break_strategy] self._reset_current_run_settings() self.killed = False
def __init__(self, multilocus_dataset, sate_team, tree=None, name=None, **kwargs): """ Note that the `tree` will be resolved using DendroPy's resolve_polytomies function. """ TreeHolder.__init__(self, multilocus_dataset.dataset, force_fully_resolved=True) if tree is not None: resolve_polytomies(tree, update_splits=True) self.blind_mode_is_final = True self.is_stuck_in_blind = False behavior = copy.copy(SateJob.BEHAVIOUR_DEFAULTS) behavior.update(SateAlignerJob.BEHAVIOUR_DEFAULTS) behavior.update(kwargs) self.__dict__.update(behavior) self._job_lock = Lock() self.multilocus_dataset = multilocus_dataset self.sate_team = sate_team self.tree = tree self.score = kwargs.get('score', None) self.best_score = None self._tree_build_job = None self._sate_decomp_job = None self._reset_jobs() self._status_message_func = kwargs.get('status_messages') # right now max_subproblem_size can be an integer or proportion. # These two run modes should be separate parameters! # if self.max_subproblem_size <= 1.0: # self.max_subproblem_size *= alignment.get_num_taxa() # self.max_subproblem_size = max(1, int(round(self.max_subproblem_size))) if isinstance(self.break_strategy, str): self.break_strategy = [self.break_strategy] self._reset_current_run_settings() self.killed = False
def __init__(self, multilocus_dataset, sate_team, tree, tmp_dir_par, **kwargs): self._job_lock = Lock() TreeHolder.__init__(self, multilocus_dataset.dataset) behavior = copy.copy(SateAlignerJob.BEHAVIOUR_DEFAULTS) behavior.update(kwargs) for k in SateAlignerJob.BEHAVIOUR_DEFAULTS.keys(): setattr(self, k, behavior[k]) self.multilocus_dataset = multilocus_dataset self.sate_team = sate_team self.tree = tree self._subjob1 = None self._subjob2 = None self._align_job_list = None self._merge_job_list = None self.tmp_dir_par = tmp_dir_par self.context_str = '' self.killed = False self._dirs_to_cleanup = []