sc_reconstruction.models.BaseReconstructionModel#

class sc_reconstruction.models.BaseReconstructionModel[source]#

Bases: ABC

Abstract base class for single-cell reconstruction models. Subclasses must implement prepare, train, predict, save and load.

__init__()#

Methods

__init__()

load(path)

Load a trained model.

predict(combos, **kwargs)

Run inference in identifier level (e.g., cell line X drug X dose), and return a dictionary mapping each identifier to its predicted result.

prepare(data)

Perform any setup steps needed before training, such as data preprocessing or model initialization.

save(path)

Save the trained model.

train([max_epochs])

Train the model.