k23064919 commited on
Commit
be6a272
·
1 Parent(s): 534bade

quick fix variable mixup

Browse files
Files changed (1) hide show
  1. ui/model_loader.py +2 -1
ui/model_loader.py CHANGED
@@ -7,6 +7,7 @@ from models.modelOne import modelOne
7
 
8
  sys.path.append(str(Path(__file__).parent.parent))
9
 
 
10
 
11
  class ModelLoader:
12
  def __init__(self):
@@ -25,7 +26,7 @@ class ModelLoader:
25
  print(f"attemtping to fetch '{modelName}' from clearML task: {taskID}")
26
 
27
  modelObject = Model(model_id=taskID)
28
- modelPath = modelObject.get_local_copy()
29
  print(f"Weights downloaded to local path: {modelPath}")
30
 
31
  model = modelOne(noOfClasses=39)
 
7
 
8
  sys.path.append(str(Path(__file__).parent.parent))
9
 
10
+ MODEL_ARTIFACT_NAME = 'model_one.pt'
11
 
12
  class ModelLoader:
13
  def __init__(self):
 
26
  print(f"attemtping to fetch '{modelName}' from clearML task: {taskID}")
27
 
28
  modelObject = Model(model_id=taskID)
29
+ modelPath = Model.get_local_copy(task_id=taskID, file_name=MODEL_ARTIFACT_NAME)
30
  print(f"Weights downloaded to local path: {modelPath}")
31
 
32
  model = modelOne(noOfClasses=39)