CatoEr commited on
Commit
8b41329
1 Parent(s): 2c1097d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -59,23 +59,23 @@ orientation_labels = {
59
 
60
  model_race = RaceClassifier(n_classes=4)
61
  model_race.to(device)
62
- model_race.load_state_dict(torch.load('best_model_race_deneme.pt', map_location=torch.device('cpu')))
63
 
64
  model_age = RaceClassifier(n_classes=3)
65
  model_age.to(device)
66
- model_age.load_state_dict(torch.load('best_model_age_last.pt', map_location=torch.device('cpu')))
67
 
68
  model_education = RaceClassifier(n_classes=2)
69
  model_education.to(device)
70
- model_education.load_state_dict(torch.load('best_model_education_last.pt', map_location=torch.device('cpu')))
71
 
72
  model_gender = RaceClassifier(n_classes=4)
73
  model_gender.to(device)
74
- model_gender.load_state_dict(torch.load('best_model_gender_last.pt', map_location=torch.device('cpu')))
75
 
76
  model_orientation = RaceClassifier(n_classes=2)
77
  model_orientation.to(device)
78
- model_orientation.load_state_dict(torch.load('best_model_orientation_last.pt', map_location=torch.device('cpu')))
79
 
80
 
81
  def evaluate(model, input, mask):
 
59
 
60
  model_race = RaceClassifier(n_classes=4)
61
  model_race.to(device)
62
+ model_race.load_state_dict(torch.load('best_model_race.pt', map_location=torch.device('cpu')))
63
 
64
  model_age = RaceClassifier(n_classes=3)
65
  model_age.to(device)
66
+ model_age.load_state_dict(torch.load('best_model_age.pt', map_location=torch.device('cpu')))
67
 
68
  model_education = RaceClassifier(n_classes=2)
69
  model_education.to(device)
70
+ model_education.load_state_dict(torch.load('best_model_education.pt', map_location=torch.device('cpu')))
71
 
72
  model_gender = RaceClassifier(n_classes=4)
73
  model_gender.to(device)
74
+ model_gender.load_state_dict(torch.load('best_model_gender.pt', map_location=torch.device('cpu')))
75
 
76
  model_orientation = RaceClassifier(n_classes=2)
77
  model_orientation.to(device)
78
+ model_orientation.load_state_dict(torch.load('best_model_orientation.pt', map_location=torch.device('cpu')))
79
 
80
 
81
  def evaluate(model, input, mask):