API Reference

learnMSA: Learning and Aligning Large Protein Families with support of protein language models.

Sequence Dataset

Classes for managing sequence data (either unaligned or aligned).

Configuration

Configuration classes for learnMSA.

class learnMSA.Configuration(*, input_output=InputOutputConfig(input_file=PosixPath('.'), output_file=PosixPath('.'), format='a2m', input_format='fasta', save_model='', load_model='', scores=PosixPath('.'), verbose=False, cuda_visible_devices='default', work_dir='tmp', convert=False, subset_ids=[], struct_file=None, emb_file=None, save_emb=None, add_block_separator_to_msa=False), training=TrainingConfig(batch_size=-1, tokens_per_batch=-1, learning_rate=0.1, epochs=[10, 2, 10], max_iterations=2, length_init=None, length_init_quantile=0.5, surgery_quantile=0.5, min_surgery_seqs=100000, len_mul=0.8, surgery_del=0.5, surgery_ins=0.5, model_criterion='AIC', max_seq_model_select=200000, indexed_data=False, unaligned_insertions=False, crop=9223372036854775807, auto_crop=True, auto_crop_scale=2.0, trainable_insertions=False, no_sequence_weights=False, skip_training=False, cluster_seq_id=0.5, use_prior=True, dirichlet_mix_comp_count=1, only_matches=False, surgery_checkpoints=True, pre_training_checkpoint=False, use_noise=True, no_aa=False, reset_emissions_after_surgery=False, reset_transitions_after_surgery=False, decoding_mode='viterbi', hit_alignment_mode='greedy_single'), tree=TreeConfig(use_anc_probs=True, trainable_rates=True, trainable_exchangeabilities=False, trainable_equilibrium=False, shared_equilibrium=True, shared_exchangeabilities=False, exchangeability_noise_std=0.02, exchangeability_l2=0.0, num_anc_probs_components=1, low_rank=None), hmm=PHMMConfig(alphabet='ARNDCQEGHILKMFPSTWYVXUO', background_distribution=[0.0834333437, 0.0519266823, 0.0493510863, 0.0465871696, 0.0224936164, 0.0506824822, 0.0629644485, 0.0472142352, 0.0334919201, 0.0526777168, 0.0733173001, 0.0635075307, 0.0352617111, 0.0360992714, 0.0346065678, 0.0721237089, 0.0652571875, 0.0177631364, 0.0339407154, 0.066508661, 0.000791449952, 5.83794314e-08, 9.99208434e-33], use_prior_for_emission_init=True, match_emissions=None, insert_emissions=None, p_begin_match=0.5, p_match_match=0.78, p_match_insert=0.1, p_match_delete=0.12, p_match_end=None, p_insert_insert=0.38, p_delete_delete=0.38, p_begin_delete=0.38, p_left_left=0.75, p_right_right=0.75, p_unannot_unannot=0.75, p_end_unannot=1e-06, p_end_right=0.5, p_start_left_flank=0.5, use_noise=False, noise_concentration=10000.0, shared_flank_transitions=True), hmm_prior=PHMMPriorConfig(use_amino_acid_prior=True, amino_acid_dirichlet_components=1, alpha_flank=7000.0, alpha_single=1000000000.0, alpha_global=10000.0, alpha_flank_compl=0.01, alpha_single_compl=0.001, alpha_global_compl=0.01, epsilon=1e-16), init_msa=InitMSAConfig(from_msa=None, match_threshold=0.4, global_factor=0.1, pseudocounts=False, seeded=False), language_model=LanguageModelConfig(use_language_model=False, only_embeddings=False, plm_cache_dir=None, language_model='protT5', scoring_model_dim=16, scoring_model_activation='sigmoid', scoring_model_suffix='', temperature=3.0, temperature_mode='trainable', use_L2=False, L2_match=0.0, L2_insert=1000.0, embedding_prior_components=32, conditionally_independent=True, variance_init=1.0, inverse_gamma_alpha=3.0, inverse_gamma_beta=0.5, match_expectations=None, match_variance=None, insert_expectation=None, insert_variance=None), visualization=VisualizationConfig(plot='', plot_head=-1, logo_gif=''), structure=StructureConfig(use_structure=False, structural_alphabet='ACDEFGHIKLMNPQRSTVWY', background_distribution=array([0.03442698, 0.03320841, 0.18404163, 0.01884517, 0.02310604, 0.02492139, 0.02817459, 0.01648818, 0.01466074, 0.08201603, 0.00620782, 0.02770227, 0.08903143, 0.04996411, 0.03158215, 0.07714301, 0.01570106, 0.20506961, 0.01778702, 0.01992235]), prior_name='', prior_components=1, prior_temperature=1.0, use_prior_for_emission_init=True, emitter_temperature=2.0, reset_after_surgery=False, match_emissions=None, insert_emissions=None), advanced=AdvancedConfig(dist_out='', initial_distance=0.05, insertion_aligner='famsa', aligner_threads=0, jit_compile=True, one_dnn_opts=False, reset_branch_lengths=True, reset_evo_model=False), **extra_data)

Bases: BaseModel

A configuration for learnMSA controlling all aspects of training and evaluation. See the nested configuration groups for details on each set of parameters.

Parameters:
advanced: AdvancedConfig

Advanced/Development parameters.

hmm: PHMMConfig

HMM parameters.

hmm_prior: PHMMPriorConfig

HMM prior parameters for transition scoring.

init_msa: InitMSAConfig

Initialize with existing MSA parameters.

input_output: InputOutputConfig

Input/output and general control parameters.

language_model: LanguageModelConfig

Protein language model integration parameters.

model_config = {'extra': 'allow'}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

structure: StructureConfig

Protein structure-related parameters.

training: TrainingConfig

Training parameters.

tree: TreeConfig

Ancestral probabilities (tree) layer parameters.

visualization: VisualizationConfig

Visualization parameters.

class learnMSA.config.training.TrainingConfig(*, batch_size=-1, tokens_per_batch=-1, learning_rate=0.1, epochs=[10, 2, 10], max_iterations=2, length_init=None, length_init_quantile=0.5, surgery_quantile=0.5, min_surgery_seqs=100000, len_mul=0.8, surgery_del=0.5, surgery_ins=0.5, model_criterion='AIC', max_seq_model_select=200000, indexed_data=False, unaligned_insertions=False, crop=9223372036854775807, auto_crop=True, auto_crop_scale=2.0, trainable_insertions=False, no_sequence_weights=False, skip_training=False, cluster_seq_id=0.5, use_prior=True, dirichlet_mix_comp_count=1, only_matches=False, surgery_checkpoints=True, pre_training_checkpoint=False, use_noise=True, no_aa=False, reset_emissions_after_surgery=False, reset_transitions_after_surgery=False, decoding_mode='viterbi', hit_alignment_mode='greedy_single')

Bases: BaseModel

Training parameters.

Parameters:
  • batch_size (int)

  • tokens_per_batch (int)

  • learning_rate (float)

  • epochs (Sequence[int])

  • max_iterations (int)

  • length_init (Sequence[int] | None)

  • length_init_quantile (float)

  • surgery_quantile (float)

  • min_surgery_seqs (int)

  • len_mul (float)

  • surgery_del (float)

  • surgery_ins (float)

  • model_criterion (str)

  • max_seq_model_select (int)

  • indexed_data (bool)

  • unaligned_insertions (bool)

  • crop (int)

  • auto_crop (bool)

  • auto_crop_scale (float)

  • trainable_insertions (bool)

  • no_sequence_weights (bool)

  • skip_training (bool)

  • cluster_seq_id (float)

  • use_prior (bool)

  • dirichlet_mix_comp_count (int)

  • only_matches (bool)

  • surgery_checkpoints (bool)

  • pre_training_checkpoint (bool)

  • use_noise (bool)

  • no_aa (bool)

  • reset_emissions_after_surgery (bool)

  • reset_transitions_after_surgery (bool)

  • decoding_mode (str)

  • hit_alignment_mode (str)

auto_crop: bool

Automatically crop sequences during training based on auto_crop_scale.

auto_crop_scale: float

Automatically crop sequences longer than this factor times the average length during training.

batch_size: int

adaptive.

Type:

Batch size for training. Default

cluster_seq_id: float

Sequence identity for computing sequence weights.

crop: int

Crop sequences longer than the given value during training.

decoding_mode: str

“viterbi”, “mea”.

Type:

Decoding mode for training. Options

dirichlet_mix_comp_count: int

Number of components for Dirichlet mixture prior.

epochs: Sequence[int]

Number of training epochs.

classmethod extract_num_model(data)

Extract num_model from input data and store for later initialization.

Parameters:

data (Any)

Return type:

Any

hit_alignment_mode: str

“left”, “right”, “greedy_scores”, “greedy_single”.

Type:

Mode for aligning the domain hits during training. Options

indexed_data: bool

Stream training data at the cost of training time.

learning_rate: float

Learning rate for gradient descent.

len_mul: float

Length multiplier.

length_init: Sequence[int] | None

Initial lengths for the models. Can be a single integer or a list of integers. If a list is provided, the number of models will be set to match the list length.

length_init_quantile: float

Quantile for initial length determination.

max_iterations: int

Maximum number of training iterations. If greater than 2, model surgery will be applied.

max_seq_model_select: int

Maximum number of sequences to use for model selection. If the dataset contains more sequences, a random subset will be used.

min_surgery_seqs: int

Minimum number of sequences for model surgery.

model_config = {'extra': 'forbid'}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_criterion: str

Criterion for model selection.

model_post_init(_TrainingConfig__context)

Store the num_model value after initialization.

Parameters:
  • __context – Context passed during validation (typically None).

  • _TrainingConfig__context (Any)

Return type:

None

no_aa: bool

Whether to use amino acid emissions in the model. This requires an alternative data source like structure information. Default: use amino acid emissions.

no_sequence_weights: bool

Do not use sequence weights and strip mmseqs2 from requirements. In general not recommended.

property num_model: int

Number of models to train.

If length_init is provided, returns its length. Otherwise, returns the stored num_model value.

only_matches: bool

Omit all insertions in the output and write only those amino acids that are assigned to match states.

pre_training_checkpoint: bool

Creates a checkpoint before each training phase. Useful to analyze initial model and effects of model surgery.

reset_emissions_after_surgery: bool

Whether to reset the emission probabilities after surgery.

reset_transitions_after_surgery: bool

Whether to reset the transition probabilities after surgery.

serialize_model(serializer)

Custom serializer to include num_model in the output.

This wraps the default serializer and adds num_model.

Parameters:

serializer (Any)

Return type:

dict[str, Any]

skip_training: bool

Only decode an alignment from the provided model.

surgery_checkpoints: bool

Whether to save model checkpoints after each model surgery run.

surgery_del: float

Discard match states expected less often than this fraction.

surgery_ins: float

Expand insertions expected more often than this fraction.

surgery_quantile: float

Quantile for model surgery.

tokens_per_batch: int

adaptive.

Type:

Tokens per batch for training. Default

trainable_insertions: bool

Insertions will be trainable during training.

unaligned_insertions: bool

Insertions will be left unaligned.

use_noise: bool

Whether to add Dirichlet noise during HMM initialization. Override the corresponding HMM config parameter for training.

use_prior: bool

Whether to use a prior on the model parameters.

classmethod validate_crop(v)
Parameters:

v (int | str)

Return type:

int | str

classmethod validate_epochs(v)
Parameters:

v (int | Sequence[int])

Return type:

Sequence[int]

classmethod validate_learning_rate(v)
Parameters:

v (float)

Return type:

float

classmethod validate_length_init(v)
Parameters:

v (Sequence[int] | None)

Return type:

Sequence[int] | None

classmethod validate_max_iterations(v)
Parameters:

v (int)

Return type:

int

classmethod validate_positive_floats(v, info)
Parameters:

v (float | int)

Return type:

float | int

classmethod validate_quantiles(v, info)
Parameters:

v (float)

Return type:

float

warn_batch_size_ignored()

Warn if both batch_size and tokens_per_batch are set.

When tokens_per_batch > 0, it takes precedence and batch_size is ignored.

Return type:

TrainingConfig

class learnMSA.config.input_output.InputOutputConfig(*, input_file=PosixPath('.'), output_file=PosixPath('.'), format='a2m', input_format='fasta', save_model='', load_model='', scores=PosixPath('.'), verbose=False, cuda_visible_devices='default', work_dir='tmp', convert=False, subset_ids=[], struct_file=None, emb_file=None, save_emb=None, add_block_separator_to_msa=False)

Bases: BaseModel

Input/output and general control parameters.

Parameters:
  • input_file (Annotated[str | Path, BeforeValidator(func=~learnMSA.config.input_output._validate_path, json_schema_input_type=PydanticUndefined)])

  • output_file (Annotated[str | Path, BeforeValidator(func=~learnMSA.config.input_output._validate_path, json_schema_input_type=PydanticUndefined)])

  • format (str)

  • input_format (str)

  • save_model (str)

  • load_model (str)

  • scores (Annotated[str | Path, BeforeValidator(func=~learnMSA.config.input_output._validate_path, json_schema_input_type=PydanticUndefined)])

  • verbose (bool)

  • cuda_visible_devices (str)

  • work_dir (str)

  • convert (bool)

  • subset_ids (list[str])

  • struct_file (Annotated[str | Path, BeforeValidator(func=~learnMSA.config.input_output._validate_path, json_schema_input_type=PydanticUndefined)] | None)

  • emb_file (Annotated[str | Path, BeforeValidator(func=~learnMSA.config.input_output._validate_path, json_schema_input_type=PydanticUndefined)] | None)

  • save_emb (Annotated[str | Path, BeforeValidator(func=~learnMSA.config.input_output._validate_path, json_schema_input_type=PydanticUndefined)] | None)

  • add_block_separator_to_msa (bool)

add_block_separator_to_msa: bool

If True, add a block separator ($) in the output MSA to indicate where sequences hit the profile. This can be seen as an extended A2M format that shows multi-hits.

convert: bool

If True, only convert the input MSA to the format specified with format.

cuda_visible_devices: str

GPU device(s) visible to learnMSA. Use -1 for CPU.

emb_file: PathField | None

If set, path to a file containing embeddings for each sequence.

format: str

Format of the output alignment file.

input_file: PathField

Input fasta file containing the protein sequences to align.

input_format: str

Format of the input alignment file.

load_model: str

If set, learnMSA will load the model parameters from the specified file.

model_config = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

output_file: PathField

Output file path for the resulting multiple sequence alignment.

save_emb: PathField | None

If set, path to save the computed embeddings for each sequence.

save_model: str

If set, the trained model parameters will be saved to the specified file.

scores: PathField

If set, the per-sequence likelihoods and bit scores will be saved to the specified file.

struct_file: PathField | None

If set, path to a fasta file containing 3Di states for each sequence.

subset_ids: list[str]

If set, only align the sequences with these IDs from the input file, but train on all sequences.

classmethod validate_cuda_devices(v)

Validate CUDA visible devices.

Parameters:

v (str)

Return type:

str

classmethod validate_format(v)

Validate output format.

Parameters:

v (str)

Return type:

str

classmethod validate_input_format(v)

Validate input format.

Parameters:

v (str)

Return type:

str

verbose: bool

If False, all output messages will be disabled.

work_dir: str

Directory where any secondary files are stored.

class learnMSA.config.language_model.LanguageModelConfig(*, use_language_model=False, only_embeddings=False, plm_cache_dir=None, language_model='protT5', scoring_model_dim=16, scoring_model_activation='sigmoid', scoring_model_suffix='', temperature=3.0, temperature_mode='trainable', use_L2=False, L2_match=0.0, L2_insert=1000.0, embedding_prior_components=32, conditionally_independent=True, variance_init=1.0, inverse_gamma_alpha=3.0, inverse_gamma_beta=0.5, match_expectations=None, match_variance=None, insert_expectation=None, insert_variance=None)

Bases: BaseModel

Protein language model integration parameters.

Parameters:
  • use_language_model (bool)

  • only_embeddings (bool)

  • plm_cache_dir (str | None)

  • language_model (str)

  • scoring_model_dim (int)

  • scoring_model_activation (str)

  • scoring_model_suffix (str)

  • temperature (float)

  • temperature_mode (str)

  • use_L2 (bool)

  • L2_match (float)

  • L2_insert (float)

  • embedding_prior_components (int)

  • conditionally_independent (bool)

  • variance_init (float)

  • inverse_gamma_alpha (float)

  • inverse_gamma_beta (float)

  • match_expectations (Sequence[float] | Sequence[Sequence[float]] | Sequence[Sequence[Sequence[float]]] | Annotated[ndarray, BeforeValidator(func=~learnMSA.config.util.nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=~learnMSA.config.util.nd_array_serializer, return_type=list, when_used=always)] | None)

  • match_variance (Sequence[float] | Sequence[Sequence[float]] | Sequence[Sequence[Sequence[float]]] | Annotated[ndarray, BeforeValidator(func=~learnMSA.config.util.nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=~learnMSA.config.util.nd_array_serializer, return_type=list, when_used=always)] | None)

  • insert_expectation (Sequence[float] | Sequence[Sequence[float]] | Annotated[ndarray, BeforeValidator(func=~learnMSA.config.util.nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=~learnMSA.config.util.nd_array_serializer, return_type=list, when_used=always)] | None)

  • insert_variance (Sequence[float] | Sequence[Sequence[float]] | Annotated[ndarray, BeforeValidator(func=~learnMSA.config.util.nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=~learnMSA.config.util.nd_array_serializer, return_type=list, when_used=always)] | None)

L2_insert: float

L2 regularization for insert states.

L2_match: float

L2 regularization for match states.

conditionally_independent: bool

Whether to use conditionally independent emissions.

embedding_prior_components: int

Number of embedding prior components.

id_string()

Generate an identifier string for the language model configuration.

Returns:

A string that uniquely identifies the language model configuration.

Return type:

str

insert_expectation: Sequence[float] | Sequence[Sequence[float]] | Annotated[ndarray, BeforeValidator(func=nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=nd_array_serializer, return_type=list, when_used=always)] | None

Optional initialization for insert state expectations. Can be: - None: Initialize with zeros (default). - Sequence[float] of length scoring_model_dim: Same for all heads. - Sequence[Sequence[float]] of shape (num_heads, scoring_model_dim):

Head-specific insert expectations.

insert_variance: Sequence[float] | Sequence[Sequence[float]] | Annotated[ndarray, BeforeValidator(func=nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=nd_array_serializer, return_type=list, when_used=always)] | None

Optional initialization for insert state variances. Can be: - None: Initialize with random normal values (default). - Sequence[float] of length scoring_model_dim: Same for all heads. - Sequence[Sequence[float]] of shape (num_heads, scoring_model_dim):

Head-specific insert variances.

inverse_gamma_alpha: float

Alpha parameter for the inverse gamma prior on variances.

inverse_gamma_beta: float

Beta parameter for the inverse gamma prior on variances.

language_model: str

Name of the language model to use.

match_expectations: Sequence[float] | Sequence[Sequence[float]] | Sequence[Sequence[Sequence[float]]] | Annotated[ndarray, BeforeValidator(func=nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=nd_array_serializer, return_type=list, when_used=always)] | None

Optional initialization for match state expectations. Can be: - None: Initialize with zeros (default). - Sequence[float] of length scoring_model_dim: Same for all match states

in all heads.

  • Sequence[Sequence[float]] of shape (num_heads, scoring_model_dim): Head-specific expectations, same for all match states within a head.

  • Sequence[Sequence[Sequence[float]]] of shape

    (num_heads, length[h], scoring_model_dim): Fully specified match state expectations for each position in each head.

match_variance: Sequence[float] | Sequence[Sequence[float]] | Sequence[Sequence[Sequence[float]]] | Annotated[ndarray, BeforeValidator(func=nd_array_before_validator, json_schema_input_type=PydanticUndefined), PlainSerializer(func=nd_array_serializer, return_type=list, when_used=always)] | None

Optional initialization for match state variances. Can be: - None: Initialize with random normal values (default). - Sequence[float] of length scoring_model_dim: Same for all match states

in all heads.

  • Sequence[Sequence[float]] of shape (num_heads, scoring_model_dim): Head-specific standard deviations, same for all match states within a head.

  • Sequence[Sequence[Sequence[float]]] of shape

    (num_heads, length[h], scoring_model_dim): Fully specified match state standard deviations for each position in each head.

model_config = {'arbitrary_types_allowed': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

only_embeddings: bool

Only compute and save the embeddings without running the full alignment.

plm_cache_dir: str | None

Directory where the protein language model is stored.

scoring_model_activation: str

Activation function of the scoring model.

scoring_model_dim: int

Reduced embedding dimension of the scoring model.

scoring_model_suffix: str

Suffix to identify a specific scoring model.

temperature: float

Temperature of the softmax function.

temperature_mode: str

Temperature mode.

use_L2: bool

Use L2 regularization.

use_language_model: bool

Uses a large protein lanague model to generate per-token embeddings that guide the MSA step.

classmethod validate_language_model(v)
Parameters:

v (str)

Return type:

str

classmethod validate_nonnegative_floats(v, info)
Parameters:

v (float)

Return type:

float

classmethod validate_positive_floats(v, info)
Parameters:

v (float)

Return type:

float

classmethod validate_positive_ints(v, info)
Parameters:

v (int)

Return type:

int

variance_init: float

Initial variance for the normal distribution.

class learnMSA.config.init_msa.InitMSAConfig(*, from_msa=None, match_threshold=0.4, global_factor=0.1, pseudocounts=False, seeded=False)

Bases: BaseModel

Parameters for initializing with existing MSA.

Parameters:
  • from_msa (Path | None)

  • match_threshold (float)

  • global_factor (float)

  • pseudocounts (bool)

  • seeded (bool)

from_msa: Path | None

If set, the initial HMM parameters will inferred from the provided MSA in FASTA format.

global_factor: float

A value in [0, 1] that describes the degree to which the MSA provided with –from_msa is considered a global alignment. This value is used as a mixing factor and affects how states are counted when the data contains fragmentary sequences. A global alignment counts flanks as deletions, while a local alignment counts them as jumps into the profile using only a single edge.

match_threshold: float

When inferring HMM parameters from an MSA, a column is considered a match state if its occupancy (fraction of non-gap characters) is at least this value.

model_config = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

pseudocounts: bool

If set, pseudocounts inferred from Dirichlet priors will be added on state transition and emissions counted in the MSA input via –from_msa.

seeded: bool

If set and –from_msa is not set, a quick MSA will be constructed with FAMSA and used for initialization if the number of sequences is below a certain threshold (default: 500).

classmethod validate_quantiles(v, info)
Parameters:

v (float)

Return type:

float

class learnMSA.config.visualization.VisualizationConfig(*, plot='', plot_head=-1, logo_gif='')

Bases: BaseModel

Visualization parameters.

Parameters:
  • plot (str)

  • plot_head (int)

  • logo_gif (str)

logo_gif: str

Produces a gif that animates the learned sequence logo over training time. Slows down training significantly.

model_config = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

plot: str

Produces a pdf of the learned HMM.

plot_head: int

The HMM head to plot. If not set, the best model based on the model selection criterion will be plotted.

class learnMSA.config.advanced.AdvancedConfig(*, dist_out='', initial_distance=0.05, insertion_aligner='famsa', aligner_threads=0, jit_compile=True, one_dnn_opts=False, reset_branch_lengths=True, reset_evo_model=False)

Bases: BaseModel

Advanced/Development parameters.

Parameters:
  • dist_out (str)

  • initial_distance (float)

  • insertion_aligner (str)

  • aligner_threads (int)

  • jit_compile (bool)

  • one_dnn_opts (bool)

  • reset_branch_lengths (bool)

  • reset_evo_model (bool)

aligner_threads: int

Number of threads to use for the aligner.

dist_out: str

Distribution output file.

initial_distance: float

Initial distance value. Is only used when not using sequence weights. If weights are used, the initial distance is calculated from the cluster sequence identity.

insertion_aligner: str

Insertion aligner to use.

jit_compile: bool

Enable XLA JIT compilation in TensorFlow.

model_config = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

one_dnn_opts: bool

Whether to use oneDNN optimizations in TensorFlow. This can improve performance on CPUs. Set the to false per default as for HMMs it caused numerical instabilities on many CPU.

reset_branch_lengths: bool

Whether to reset the branch lengths (tau) before training.

reset_evo_model: bool

Whether to reset the evolutionary model parameters (exchangeabilities, equilibrium, and mixture) before training.

classmethod validate_quantiles(v, info)
Parameters:

v (float)

Return type:

float