Skip to content

Commit

Permalink
fix tmm version
Browse files Browse the repository at this point in the history
  • Loading branch information
Cathy0908 committed Oct 27, 2023
1 parent e04ce3c commit ddbaa4a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion easycv/models/backbones/efficientformer.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@
import os
from distutils.version import LooseVersion

import timm
import torch
import torch.nn as nn
from timm.models.layers import DropPath, trunc_normal_

from ..modelzoo import efficientformer as model_urls
from ..registry import BACKBONES

if LooseVersion(torch.__version__) <= LooseVersion('0.8.2'):
if LooseVersion(timm.__version__) <= LooseVersion('0.8.2'):
from timm.models.layers.helpers import to_2tuple
else:
from timm.layers.helpers import to_2tuple
Expand Down

0 comments on commit ddbaa4a

Please sign in to comment.