mirror of
https://github.com/open-mmlab/mim.git
synced 2025-06-03 06:40:24 +08:00
Compare commits
2 Commits
2ec36a90d7
...
7d25759ead
Author | SHA1 | Date | |
---|---|---|---|
|
7d25759ead | ||
|
10f3e61739 |
@ -278,7 +278,7 @@ def gridsearch(
|
||||
for arg in search_args_dict:
|
||||
try:
|
||||
arg_value = get_config(cfg, arg)
|
||||
if arg_value and not isinstance(arg_value, str):
|
||||
if arg_value is not None and not isinstance(arg_value, str):
|
||||
search_args_dict[arg] = [
|
||||
eval(x) for x in search_args_dict[arg]
|
||||
]
|
||||
|
@ -42,10 +42,10 @@ def test_download():
|
||||
|
||||
# mim download mmcls --config resnet18_b16x8_cifar10
|
||||
checkpoints = download('mmcls', ['resnet18_b16x8_cifar10'])
|
||||
assert checkpoints == ['resnet18_b16x8_cifar10_20200823-f906fa4e.pth']
|
||||
assert checkpoints == ['resnet18_b16x8_cifar10_20210528-bd6371c8.pth']
|
||||
checkpoints = download('mmcls', ['resnet18_b16x8_cifar10'])
|
||||
|
||||
# mim download mmcls --config resnet18_b16x8_cifar10 --dest temp_root
|
||||
with tempfile.TemporaryDirectory() as temp_root:
|
||||
checkpoints = download('mmcls', ['resnet18_b16x8_cifar10'], temp_root)
|
||||
assert checkpoints == ['resnet18_b16x8_cifar10_20200823-f906fa4e.pth']
|
||||
assert checkpoints == ['resnet18_b16x8_cifar10_20210528-bd6371c8.pth']
|
||||
|
Loading…
x
Reference in New Issue
Block a user