CLAM: default model #174
-
Hi, I'm looking to run CLAM using the same model as in the initial paper (ResNet50) and was wondering whether to do so using slideflow I would have to download and save the model separately, or whether it could be done using using something akin to model=default in generate_features_for_clam? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Previously, yes - you would have needed to save an Imagenet-pretrained (but not re-trained) model, and then pass that model to the However, this is a bit unintuitive, so in 86d9c5d I added the ability to pass the name of an architecture (rather than the path to a saved model). If you pass the name of an architecture, it will load the Imagnet pretrained weights and calculate activations from this model. If you do this, you will also need to provide a dataset = Project.dataset(tile_px=299, tile_um=302, min_tiles=16)
Project.generate_features_for_clam(
model='resnet50',
dataset=dataset,
...
) This functionality will be included in Version 1.2.0 when released (anticipate release this month). In the meantime, you can use this functionality by running from the master branch. |
Beta Was this translation helpful? Give feedback.
Previously, yes - you would have needed to save an Imagenet-pretrained (but not re-trained) model, and then pass that model to the
.generate_features_for_clam()
function.However, this is a bit unintuitive, so in 86d9c5d I added the ability to pass the name of an architecture (rather than the path to a saved model). If you pass the name of an architecture, it will load the Imagnet pretrained weights and calculate activations from this model. If you do this, you will also need to provide a
dataset
:This functionality will be included in Versio…