timm breaking changes
Updated December 4, 2026
On this page
Latest version 1.0.31, released November 3, 2026. Source repository
Packages on PyPI run on Python. Python end of life dates.
- From 0.9.0 to 1.0.31: 249 breaking changes in 3 versions.
- From 0.6.5 to 1.0.31: 1,957 breaking changes in 6 versions.
timm 1.0.31 breaking changes
- Removed
timm.data.naflex_mixup.smoothed_sparse_target
timm.data.naflex_mixup.smoothed_sparse_target was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbedding.bands
RotaryEmbedding.bands was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbedding.pos_embed_cos
RotaryEmbedding.pos_embed_cos was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbedding.pos_embed_sin
RotaryEmbedding.pos_embed_sin was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbeddingCat.bands
RotaryEmbeddingCat.bands was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbeddingCat.pos_embed
RotaryEmbeddingCat.pos_embed was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbeddingDinoV3.aug_active
RotaryEmbeddingDinoV3.aug_active was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbeddingDinoV3.jitter_coords
RotaryEmbeddingDinoV3.jitter_coords was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbeddingDinoV3.rescale_coords
RotaryEmbeddingDinoV3.rescale_coords was removed in timm 1.0.31 pypi.org - Removed
timm.layers.RotaryEmbeddingDinoV3.shift_coords
RotaryEmbeddingDinoV3.shift_coords was removed in timm 1.0.31 pypi.org - Removed
timm.models.ConvMixer.pooling
ConvMixer.pooling was removed in timm 1.0.31 pypi.org - Removed
timm.task.token_distillation.create_model
timm.task.token_distillation.create_model was removed in timm 1.0.31 pypi.org - Removed
timm.task.TokenDistillationTeacher
timm.task.TokenDistillationTeacher was removed in timm 1.0.31 pypi.org - Removed
timm.task.TrainingTask.to
TrainingTask.to was removed in timm 1.0.31 pypi.org - Renamed
reparameterize_model
reparameterize_model is now provided from timm.models, so imports from the old location need updating. github.com - Renamed
timm.task.token_distillation.TokenDistillationTeacher
Use timm.task.token_distillation.DistillationTeacher instead. pypi.org - Behavior changed
Pool types a model cannot apply now raise an error at creation or reset instead of being ignored or failing in forward. github.com - Behavior changed
Models now raise TypeError for unknown constructor arguments in all families, so code passing extra arguments will fail. github.com - Behavior changed
apply_rot_embed
The function now casts the output back to each input's dtype after rotation, which can change output dtype. github.com - Behavior changed
apply_rot_embed_cat
The function now casts the output back to each input's dtype after rotation, which can change output dtype. github.com - Behavior changed
apply_rot_embed_list
The function now casts the output back to each input's dtype after rotation, which can change output dtype. github.com - Behavior changed
prune_intermediate_layers
With prune_head=True the head norm, pre-logits layers and attention pooling are removed. Pass prune_head=False to keep the head. github.com - Default changed
ASL
The ASL loss default reduction is now batchmean, which changes loss values for code relying on the old default. github.com - Default changed
ModelEmaV3
bfloat16 EMA weights now use stochastic rounding by default, which changes EMA results for bfloat16 models. github.com - Signature changed
timm.data.create_naflex_loader
Was def create_naflex_loader(dataset, patch_size: Optional[Union[Tuple[int, int], int]] = None, patch_size_choices: Optional[List[int]] = None, patch_size_choice_probs: Optional[List[float]] = None, train_seq_lens: Tuple[int, ...] = (128... pypi.org - Signature changed
timm.data.Mixup.__init__
Was def __init__(self, mixup_alpha=1.0, cutmix_alpha=0.0, cutmix_minmax=None, prob=1.0, switch_prob=0.5, mode='batch', correct_lam=True, label_smoothing=0.1, num_classes=1000); now def __init__(self, mixup_alpha=1.0, cutmix_alpha=0.0... pypi.org - Signature changed
timm.data.mixup.mixup_target
Was def mixup_target(target, num_classes, lam=1.0, smoothing=0.0); now def mixup_target(target, num_classes, lam=1.0, smoothing=0.0, multi_label=False). pypi.org - Signature changed
timm.data.NaFlexMixup.__init__
Was def __init__(self, *, num_classes: int, mixup_alpha: float = 0.8, cutmix_alpha: float = 1.0, switch_prob: float = 0.5, prob: float = 1.0, local_shuffle: int = 4, label_smoothing: float = 0.0, mixup_off_epoch: int = 0) -> None; now def... pypi.org - Signature changed
timm.data.pairwise_mixup_target
Was def pairwise_mixup_target(targets: torch.Tensor, pair_to: Dict[int, int], lam_list: List[float], *, num_classes: int, smoothing: float = 0.0) -> torch.Tensor; now def pairwise_mixup_target(targets: torch.Tensor, pair_to: Dict[int... pypi.org - Signature changed
timm.data.readers.reader_hfds.ReaderHfds.__init__
Was def __init__(self, name: str, root: Optional[str] = None, split: str = 'train', class_map: dict = None, input_key: str = 'image', target_key: str = 'label', additional_features: Optional[List[str]] = None, download: bool = False... pypi.org - Signature changed
timm.data.readers.reader_hfids.ReaderHfids.__init__
Was def __init__(self, name: str, root: Optional[str] = None, split: str = 'train', is_training: bool = False, batch_size: int = 1, download: bool = False, repeats: int = 0, seed: int = 42, class_map: Optional[dict] = None, input_key: str... pypi.org - Signature changed
timm.data.readers.reader_tfds.get_class_labels
Was def get_class_labels(info); now def get_class_labels(info, label_key='label'). pypi.org - Signature changed
timm.data.readers.reader_tfds.ReaderTfds.__init__
Was def __init__(self, name, root=None, split='train', class_map=None, is_training=False, batch_size=1, download=False, repeats=0, seed=42, input_key='image', input_img_mode='RGB', target_key='label', target_img_mode=''... pypi.org - Signature changed
timm.data.readers.reader_wds.ReaderWds.__init__
Was def __init__(self, root: str, name: Optional[str] = None, split: str = 'train', is_training: bool = False, num_samples: Optional[int] = None, batch_size: int = 1, repeats: int = 0, seed: int = 42, class_map: Optional[dict] = None... pypi.org - Signature changed
timm.layers.AttentionPool2d.reset
Was def reset(self, num_classes: Optional[int] = None, pool_type: Optional[str] = None, device=None, dtype=None); now def reset(self, num_classes: Optional[int] = None, pool_type: Optional[str] = None, reset_other: bool = False... pypi.org - Signature changed
timm.layers.build_fourier_pos_embed
Was def build_fourier_pos_embed(feat_shape: List[int], bands: Optional[torch.Tensor] = None, num_bands: int = 64, max_res: int = 224, temperature: float = 10000.0, linear_bands: bool = False, include_grid: bool = False, in_pixels: bool =... pypi.org - Signature changed
timm.layers.build_rotary_pos_embed
Was def build_rotary_pos_embed(feat_shape: List[int], bands: Optional[torch.Tensor] = None, dim: int = 64, max_res: int = 224, temperature: float = 10000.0, linear_bands: bool = False, in_pixels: bool = True, ref_feat_shape... pypi.org - Signature changed
timm.layers.ClassifierHead.reset
Was def reset(self, num_classes: int, pool_type: Optional[str] = None, device=None, dtype=None); now def reset(self, num_classes: int, pool_type: Optional[str] = None, reset_other: bool = False, in_features: Optional[int] = None... pypi.org - Signature changed
timm.layers.ClNormMlpClassifierHead.reset
Was def reset(self, num_classes: int, pool_type: Optional[str] = None, reset_other: bool = False, device=None, dtype=None); now def reset(self, num_classes: int, pool_type: Optional[str] = None, reset_other: bool = False, in_features... pypi.org - Signature changed
timm.layers.get_mixed_freqs
Was def get_mixed_freqs(freqs: torch.Tensor, t_x: torch.Tensor, t_y: torch.Tensor) -> torch.Tensor; now def get_mixed_freqs(freqs: torch.Tensor, t_x: torch.Tensor, t_y: torch.Tensor, dtype: Optional[torch.dtype] = None) -> torch.Tensor. pypi.org - Signature changed
timm.layers.NormMlpClassifierHead.reset
Was def reset(self, num_classes: int, pool_type: Optional[str] = None, device=None, dtype=None); now def reset(self, num_classes: int, pool_type: Optional[str] = None, reset_other: bool = False, in_features: Optional[int] = None... pypi.org - Signature changed
timm.layers.resample_abs_pos_embed
Was def resample_abs_pos_embed(posemb: torch.Tensor, new_size: List[int], old_size: Optional[List[int]] = None, num_prefix_tokens: int = 1, interpolation: str = 'bicubic', antialias: bool = True, verbose: bool = False); now def... pypi.org - Signature changed
timm.layers.resize_rel_pos_bias_table
Was def resize_rel_pos_bias_table(rel_pos_bias, new_window_size: Tuple[int, int], new_bias_shape: Tuple[int, ...]); now def resize_rel_pos_bias_table(rel_pos_bias, new_window_size: Tuple[int, int], new_bias_shape: Tuple[int, ...]... pypi.org - Signature changed
timm.layers.RotaryEmbedding
Was class RotaryEmbedding(nn.Module); now class RotaryEmbedding(_RotaryEmbeddingBase). pypi.org - Signature changed
timm.layers.RotaryEmbedding.__init__
Was def __init__(self, dim, max_res=224, temperature=10000, in_pixels=True, linear_bands: bool = False, feat_shape: Optional[List[int]] = None, ref_feat_shape: Optional[List[int]] = None, grid_offset: float = 0.0, grid_indexing: str =... pypi.org - Signature changed
timm.layers.RotaryEmbedding.get_embed
Was def get_embed(self, shape: Optional[List[int]] = None); now def get_embed(self, shape: Optional[List[int]] = None, dtype: Optional[torch.dtype] = None) -> Tuple[torch.Tensor, torch.Tensor]. pypi.org - Signature changed
timm.layers.RotaryEmbeddingCat
Was class RotaryEmbeddingCat(nn.Module); now class RotaryEmbeddingCat(_RotaryEmbeddingBase). pypi.org - Signature changed
timm.layers.RotaryEmbeddingCat.__init__
Was def __init__(self, dim: int, max_res: int = 224, temperature: float = 10000, in_pixels: bool = True, linear_bands: bool = False, feat_shape: Optional[List[int]] = None, ref_feat_shape: Optional[List[int]] = None, grid_offset: float =... pypi.org - Signature changed
timm.layers.RotaryEmbeddingCat.get_batch_embeds
Was def get_batch_embeds(self, shapes: List[Tuple[int, int]], seq_len: Optional[int] = None) -> Union[torch.Tensor, List[torch.Tensor]]; now def get_batch_embeds(self, shapes: List[Tuple[int, int]], seq_len: Optional[int] = None, dtype... pypi.org - Signature changed
timm.layers.RotaryEmbeddingCat.get_embed
Was def get_embed(self, shape: Optional[List[int]] = None); now def get_embed(self, shape: Optional[List[int]] = None, dtype: Optional[torch.dtype] = None) -> torch.Tensor. pypi.org
And 109 more in this version. Sign up to see every change
timm 1.0.30 breaking changes
- Behavior changed
The inference.py script chooses its input size in a different way than before. Pass an explicit input size if you depend on the old choice. github.com - Behavior changed
Pruned models now report different feature_info channels than before, which can change code that reads that metadata. github.com - Behavior changed
AdafactorBigVision
The optimizer now clips updates in the corrected direction, so training results will differ from earlier versions. github.com - Behavior changed
AdaMuon
Conv weights now get a different learning-rate scale, so training results will differ from earlier versions. github.com - Behavior changed
AsymmetricLossMultiLabel
The loss no longer forces its own gradient mode, so gradient behavior depends on the caller's setting. github.com - Behavior changed
Kron
Loaded Kron checkpoints now get corrected_weight_decay applied, so optimizer behavior after loading differs from before. github.com - Behavior changed
Mars
The optimizer now stores a copy of the previous gradient rather than a reference to p.grad, which changes its update results. github.com - Default changed
The default position interpolation for NaFlex SigLIP models is now different. Set it explicitly if you need the previous results. github.com - Signature changed
timm.layers.AttentionRope.__init__
Was def __init__(self, dim: int, num_heads: int = 8, dim_out: Optional[int] = None, qkv_bias: bool = True, qkv_fused: bool = True, num_prefix_tokens: int = 1, attn_drop: float = 0.0, proj_drop: float = 0.0, attn_head_dim: Optional[int] =... pypi.org - Signature changed
timm.layers.build_rotary_pos_embed
Was def build_rotary_pos_embed(feat_shape: List[int], bands: Optional[torch.Tensor] = None, dim: int = 64, max_res: int = 224, temperature: float = 10000.0, linear_bands: bool = False, in_pixels: bool = True, ref_feat_shape... pypi.org
And 5 more in this version. Sign up to see every change
timm 1.0.3 breaking changes
- Removed
Functions annotated with torch.jit.script and the old JIT activations were removed. Code that calls them must switch to dynamo-based compilation. github.com - Removed
timm.layers.activations_jit
timm.layers.activations_jit was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.hard_mish_jit_bwd
timm.layers.activations_me.hard_mish_jit_bwd was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.hard_mish_jit_fwd
timm.layers.activations_me.hard_mish_jit_fwd was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.hard_sigmoid_jit_bwd
timm.layers.activations_me.hard_sigmoid_jit_bwd was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.hard_swish_jit_bwd
timm.layers.activations_me.hard_swish_jit_bwd was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.hard_swish_jit_fwd
timm.layers.activations_me.hard_swish_jit_fwd was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.HardMishJitAutoFn
timm.layers.activations_me.HardMishJitAutoFn was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.HardSigmoidJitAutoFn
timm.layers.activations_me.HardSigmoidJitAutoFn was removed in timm 1.0.3 pypi.org - Removed
timm.layers.activations_me.HardSwishJitAutoFn
timm.layers.activations_me.HardSwishJitAutoFn was removed in timm 1.0.3 pypi.org
And 65 more in this version. Sign up to see every change
timm 0.9.0 breaking changes
- Removed
timm.data.dataset.ImageDataset.parser
ImageDataset.parser was removed in timm 0.9.0 pypi.org - Removed
timm.data.dataset.IterableImageDataset.parser
IterableImageDataset.parser was removed in timm 0.9.0 pypi.org - Removed
timm.data.ImageDataset.parser
ImageDataset.parser was removed in timm 0.9.0 pypi.org - Removed
timm.data.IterableImageDataset.parser
IterableImageDataset.parser was removed in timm 0.9.0 pypi.org - Removed
timm.data.loader.PrefetchLoader.fp16
PrefetchLoader.fp16 was removed in timm 0.9.0 pypi.org - Removed
timm.has_pretrained_cfg_key
timm.has_pretrained_cfg_key was removed in timm 0.9.0 pypi.org - Removed
timm.is_pretrained_cfg_key
timm.is_pretrained_cfg_key was removed in timm 0.9.0 pypi.org - Removed
timm.models.act_with_gamma
timm.models.act_with_gamma was removed in timm 0.9.0 pypi.org - Removed
timm.models.adjust_widths_groups_comp
timm.models.adjust_widths_groups_comp was removed in timm 0.9.0 pypi.org - Removed
timm.models.adv_inception_v3
timm.models.adv_inception_v3 was removed in timm 0.9.0 pypi.org
And 1,695 more in this version. Sign up to see every change
timm 0.8.17.dev0 breaking changes
- Default changed
convnext_xxlarge
The default LayerNorm eps for convnext_xxlarge is now 1e-5. Code relying on the previous default may see slightly different outputs. github.com
timm 0.8.2.dev0 breaking changes
- Removed
timm.data.parsers
Dataset 'parsers' were renamed to 'readers'. Update code that imports or refers to parsers. pypi.org - Configuration changed
AMP arguments changed: APEX is selected with --amp-impl apex and bfloat16 with --amp-dtype bfloat16. Update scripts that pass the old AMP arguments. github.com
Older versions
1 older version, each with its first changes. Sign up to see every change
Show 1 older version
timm 0.6.5 breaking changes
- Removed
timm.data.parsers.constants
timm.data.parsers.constants was removed in timm 0.6.5 pypi.org - Removed
timm.data.parsers.parser_factory.ParserImageTar
timm.data.parsers.parser_factory.ParserImageTar was removed in timm 0.6.5 pypi.org
And 371 more in this version.
Check your code
These are the changes. To see which of them reach your code, scan a public repository, or have your coding agent call check_code with your manifest or lockfile over MCP. The API reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

Put your code on continuous maintenance.
Scan a public repository now, or give your agent one line.
See how out of date your code is.
Tell your agent what changed since it was trained.
claude mcp add --transport http since https://api.since.dev/mcpCodex, Cursor and any MCP client use https://api.since.dev/mcp.