Skip to content

add timm-MobileNetV3 as an Encoder #355

New issue

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

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

Already on GitHub? # to your account

Merged
merged 5 commits into from
Jul 4, 2021
Merged

Conversation

markson14
Copy link
Contributor

[PR] timm-MobileNetV3 Encoder Added !!

  1. Rewrite timm-MobileNetV3 as an Encoder
  2. Using "mode" to create corresponding mobilenetv3
  3. Using "width_mult" to manipulate out_channels. Encoder can be easily extended.

@@ -0,0 +1,164 @@
from timm import create_model
import torch.nn as nn
from segmentation_models_pytorch.encoders._base import EncoderMixin
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to change this to:

from ._base import EncoderMixin

(like other timm_*** encoders)

@JulienMaille
Copy link
Contributor

@markson14 may I ask why you have to tweak the models after creation, rwightman seems to believe we can use create_model() as the encoder without further modfications. See #373

@qubvel qubvel merged commit 225823b into qubvel-org:master Jul 4, 2021
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants