cyto_ml.models package

Submodules

cyto_ml.models.api module

cyto_ml.models.api.load_models() None[source]
async cyto_ml.models.api.resnet18_3(url: str = Form(PydanticUndefined)) JSONResponse[source]

Use the 3 class Resnet18 model to return both a prediction and a set of image embeddings

async cyto_ml.models.api.resnet50(url: str = Form(PydanticUndefined)) JSONResponse[source]
async cyto_ml.models.api.root() JSONResponse[source]

cyto_ml.models.utils module

cyto_ml.models.utils.flat_embeddings(features: Tensor) list[source]

Utility function that takes the features returned by the model in truncate_model And flattens them into a list suitable for storing in a vector database

cyto_ml.models.utils.resnet18(num_classes: int, filename: str = '', strip_final_layer: bool = False) Module[source]

Module contents