Skip to content

CLAM: default model #174

Answered by jamesdolezal
OncologyDS asked this question in Q&A
Discussion options

You must be logged in to vote

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:

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 Versio…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@OncologyDS
Comment options

Answer selected by OncologyDS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants