Update app.py
Browse files
app.py
CHANGED
@@ -45,23 +45,9 @@ def video_to_gif(video_array, gif_filename):
|
|
45 |
|
46 |
|
47 |
def get_model(data_type):
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
pt_model = keras.models.load_model(MODELS[data_type][1])
|
52 |
-
label_map = {v: k for k, v in K400_label_map.items()}
|
53 |
-
|
54 |
-
elif data_type=='SSv2':
|
55 |
-
ft_model = keras.models.load_model(MODELS[data_type][0])
|
56 |
-
pt_model = keras.models.load_model(MODELS[data_type][1])
|
57 |
-
label_map = {v: k for k, v in SSv2_label_map.items()}
|
58 |
-
|
59 |
-
elif data_type=='UCF':
|
60 |
-
ft_model = keras.models.load_model(MODELS[data_type][0])
|
61 |
-
pt_model = keras.models.load_model(MODELS[data_type][1])
|
62 |
-
label_map = {v: k for k, v in UCF_label_map.items()}
|
63 |
-
|
64 |
-
|
65 |
return ft_model, pt_model, label_map
|
66 |
|
67 |
|
|
|
45 |
|
46 |
|
47 |
def get_model(data_type):
|
48 |
+
ft_model = keras.models.load_model(MODELS[data_type][0])
|
49 |
+
pt_model = keras.models.load_model(MODELS[data_type][1])
|
50 |
+
label_map = {v: k for k, v in K400_label_map.items()}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
51 |
return ft_model, pt_model, label_map
|
52 |
|
53 |
|