cellflow.model.CellFlow.prepare_model

CellFlow.prepare_model(condition_mode='deterministic', regularization=0.0, pooling='attention_token', pooling_kwargs=mappingproxy({}), layers_before_pool=Field(name=None, type=None, default=<dataclasses._MISSING_TYPE object>, default_factory=<function CellFlow.<lambda>>, init=True, repr=True, hash=None, compare=True, metadata=mappingproxy({}), kw_only=<dataclasses._MISSING_TYPE object>, _field_type=None), layers_after_pool=Field(name=None, type=None, default=<dataclasses._MISSING_TYPE object>, default_factory=<function CellFlow.<lambda>>, init=True, repr=True, hash=None, compare=True, metadata=mappingproxy({}), kw_only=<dataclasses._MISSING_TYPE object>, _field_type=None), condition_embedding_dim=256, cond_output_dropout=0.9, condition_encoder_kwargs=None, pool_sample_covariates=True, time_freqs=1024, time_max_period=10000, time_encoder_dims=(2048, 2048, 2048), time_encoder_dropout=0.0, hidden_dims=(2048, 2048, 2048), hidden_dropout=0.0, conditioning='concatenation', conditioning_kwargs=Field(name=None, type=None, default=<dataclasses._MISSING_TYPE object>, default_factory=<function CellFlow.<lambda>>, init=True, repr=True, hash=None, compare=True, metadata=mappingproxy({}), kw_only=<dataclasses._MISSING_TYPE object>, _field_type=None), decoder_dims=(4096, 4096, 4096), decoder_dropout=0.0, vf_act_fn=<PjitFunction of <function silu>>, vf_kwargs=None, probability_path=None, match_fn=<function match_linear>, optimizer=<optax.transforms._accumulation.MultiSteps object>, solver_kwargs=None, layer_norm_before_concatenation=False, linear_projection_before_concatenation=False, seed=0)[source]

Prepare the model for training.

This function sets up the neural network architecture and specificities of the solver. When solver is an instance of cellflow.solvers._genot.GENOT, the following arguments have to be passed to 'condition_encoder_kwargs':

Parameters:
Return type:

None

Returns:

: Updates the following fields: