|
15 | 15 | from torchvision.models.mobilenetv3 import SqueezeExcitation
|
16 | 16 |
|
17 | 17 |
|
18 |
| -__all__ = ["EfficientNet", "efficientnet_b0"] |
| 18 | +__all__ = ["EfficientNet", "efficientnet_b0", "efficientnet_b3"] |
19 | 19 |
|
20 | 20 |
|
21 |
| -model_urls = { |
22 |
| - "efficientnet_b0": None, # TODO: Add weights |
| 21 | +model_urls = { # TODO: Add weights |
| 22 | + "efficientnet_b0": None, |
| 23 | + "efficientnet_b3": None, |
23 | 24 | }
|
24 | 25 |
|
25 | 26 |
|
@@ -235,3 +236,16 @@ def efficientnet_b0(pretrained: bool = False, progress: bool = True, **kwargs: A
|
235 | 236 | """
|
236 | 237 | inverted_residual_setting = _efficientnet_conf(width_mult=1.0, depth_mult=1.0, **kwargs)
|
237 | 238 | return _efficientnet_model("efficientnet_b0", inverted_residual_setting, 0.2, pretrained, progress, **kwargs)
|
| 239 | + |
| 240 | + |
| 241 | +def efficientnet_b3(pretrained: bool = False, progress: bool = True, **kwargs: Any) -> EfficientNet: |
| 242 | + """ |
| 243 | + Constructs a EfficientNet B3 architecture from |
| 244 | + `"EfficientNet: Rethinking Model Scaling for Convolutional Neural Networks" <https://arxiv.org/abs/1905.11946>`_. |
| 245 | +
|
| 246 | + Args: |
| 247 | + pretrained (bool): If True, returns a model pre-trained on ImageNet |
| 248 | + progress (bool): If True, displays a progress bar of the download to stderr |
| 249 | + """ |
| 250 | + inverted_residual_setting = _efficientnet_conf(width_mult=1.2, depth_mult=1.4, **kwargs) |
| 251 | + return _efficientnet_model("efficientnet_b3", inverted_residual_setting, 0.3, pretrained, progress, **kwargs) |
0 commit comments