Skip to content

Commit f8d1eb4

Browse files
authored
Merge pull request #137 from lukemelas/advprop
Fixed `url_map` name
2 parents 50b0de9 + 53dbbe5 commit f8d1eb4

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

efficientnet_pytorch/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
__version__ = "0.6.0"
1+
__version__ = "0.6.1"
22
from .model import EfficientNet
33
from .utils import (
44
GlobalParams,

efficientnet_pytorch/utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ def get_model_params(model_name, override_params):
295295
return blocks_args, global_params
296296

297297

298-
url_map_aa = {
298+
url_map = {
299299
'efficientnet-b0': 'https://publicmodels.blob.core.windows.net/container/aa/efficientnet-b0-355c32eb.pth',
300300
'efficientnet-b1': 'https://publicmodels.blob.core.windows.net/container/aa/efficientnet-b1-f1951068.pth',
301301
'efficientnet-b2': 'https://publicmodels.blob.core.windows.net/container/aa/efficientnet-b2-8bb594d6.pth',
@@ -323,8 +323,8 @@ def get_model_params(model_name, override_params):
323323
def load_pretrained_weights(model, model_name, load_fc=True, advprop=False):
324324
""" Loads pretrained weights, and downloads if loading for the first time. """
325325
# AutoAugment or Advprop (different preprocessing)
326-
url_map = url_map_advprop if advprop else url_map_aa
327-
state_dict = model_zoo.load_url(url_map[model_name])
326+
url_map_ = url_map_advprop if advprop else url_map
327+
state_dict = model_zoo.load_url(url_map_[model_name])
328328
if load_fc:
329329
model.load_state_dict(state_dict)
330330
else:

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
1919
AUTHOR = 'Luke'
2020
REQUIRES_PYTHON = '>=3.5.0'
21-
VERSION = '0.6.0'
21+
VERSION = '0.6.1'
2222

2323
# What packages are required for this module to be executed?
2424
REQUIRED = [

0 commit comments

Comments
 (0)