Skip to content
Snippets Groups Projects
Commit 3e0885f8 authored by andong's avatar andong
Browse files

correctly print model_names

parent 5bcb9fce
No related branches found
No related tags found
No related merge requests found
...@@ -34,7 +34,7 @@ def create_model(arch, pretrained='', delete_fc=False, *args, **kwargs): ...@@ -34,7 +34,7 @@ def create_model(arch, pretrained='', delete_fc=False, *args, **kwargs):
optional arguments optional arguments
''' '''
# creating model # creating model
if arch not in globals(): if arch not in model_names:
raise NameError("unknown model architecture '%s'\nSelect one in %s" % ( raise NameError("unknown model architecture '%s'\nSelect one in %s" % (
arch, ','.join(model_names))) arch, ','.join(model_names)))
model = globals()[arch](*args, **kwargs) model = globals()[arch](*args, **kwargs)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment