UPGRADING.md
I generally try to maintain code interface and especially model weight compatibility across many timm versions. Sometimes there are exceptions.
Pretrained weight remapping is handled by checkpoint_filter_fn in a model implementation module. This remaps old pretrained checkpoints to new, and also 3rd party (original) checkpoints to timm format if the model was modified when brought into timm.
The checkpoint_filter_fn is automatically called when loading pretrained weights via pretrained=True, but they can be called manually if you call the fn directly with the current model instance and old state dict.
Many changes were made since the 0.6.x stable releases. They were previewed in 0.8.x dev releases but not everyone transitioned.
timm.models.layers moved to timm.layers:
from timm.models.layers import name will still work via deprecation mapping (but please transition to timm.layers).import timm.models.layers.module or from timm.models.layers.module import name needs to be changed now.timm.models have a _ prefix added, ie timm.models.helpers -> timm.models._helpers, there are temporary deprecation mapping files but those will be removed.architecture.pretrained_tag naming (ex resnet50.rsb_a1).
architecture defaults to the first weights in the default_cfgs for that model architecture.vit_base_patch16_224_in21k -> vit_base_patch16_224.augreg_in21k). There are deprecation mappings for these.features_only=True, there are checkpoint_filter_fn methods in any model module that was remapped. These can be passed to timm.models.load_checkpoint(..., filter_fn=timm.models.swin_transformer_v2.checkpoint_filter_fn) to remap your existing checkpoint.timm weights. Model cards include link to papers, original source, license.