Skip to content

timm upgrade 0.6.12 #696

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Dec 15, 2022

Conversation

VadimLevin
Copy link
Contributor

@VadimLevin VadimLevin commented Dec 13, 2022

This patch resolves compatibility issues after timm upgrade to 0.6.12 release.

Unfortunately, RegNet in 0.6.12 uses RegNetCfg dataclass instead of plain dict as cfg parameter (related commit).
This requires min Python version change to 3.7 (when dataclass module was introduced).

Related issue 620

@qubvel
Copy link
Collaborator

qubvel commented Dec 14, 2022

Hi Vadim,
Thanks for your contribution!
I was really thinking about deprecating timm- encoders in favor of tu- enoders to make updates smooth, but seems like your solve the issue!

@qubvel
Copy link
Collaborator

qubvel commented Dec 14, 2022

@a99user
Copy link

a99user commented Dec 14, 2022

@qubvel, could you reveal some details a bit regrading mentioned tu- encoders, please?

@qubvel
Copy link
Collaborator

qubvel commented Dec 14, 2022

Both tu- and timm- are models from timm (see timm universal). However, tu- encoders are not rewritten for this repo structure and are slightly less optimized for some features.
For example,

  • when you use encoder as timm- and depth=4, then images are passed only through required blocks
  • when you use tu- encoder then images are passed through all blocks, no matter what depth is specified (and only required features are used)

But, you have more options using tu- encores, almost any model from timm

@VadimLevin
Copy link
Contributor Author

It looks like PR-694 broke formatting

EfficientNet act1 layer in timm is merged with bn1 layer after
ab49d275de8a9c344aea086fd86d04c4cabb6098 commit
`zero_init_last_bn` was renamed to `zero_init_last` in
372ad5fa0dbeb74dcec81db06e9ff69b3d5a2eb6 commit
Instead of plain dict config RegNet uses RegNetCfg dataclass.
Dataclasses module were added in Python 3.7, thats why min required
Python version for package is also increased.
@VadimLevin VadimLevin force-pushed the dev/vlevin/timm-upgrade-0.6.12 branch from c8eade3 to a545e6f Compare December 14, 2022 12:41
@VadimLevin
Copy link
Contributor Author

@qubvel I've rebased on the latest commit in the master branch. Can you trigger a workflow?

@qubvel qubvel merged commit 519d358 into qubvel-org:master Dec 15, 2022
@qubvel
Copy link
Collaborator

qubvel commented Dec 15, 2022

Thanks a lot, merged!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants