gaspar-avit commited on
Commit
551de09
·
1 Parent(s): 1c5013e

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -3
app.py CHANGED
@@ -120,8 +120,6 @@ def input_layout():
120
 
121
  if __name__ == "__main__":
122
 
123
- # Initialize image variable
124
- poster = None
125
 
126
  ## --- Page config ------------ ##
127
  # Set page title
@@ -135,10 +133,15 @@ if __name__ == "__main__":
135
 
136
  # Set page footer
137
  footer()
 
 
138
 
139
  # Load classification model
140
  model = CatBoostClassifier() # parameters not required.
141
- model.load_model('./train/model.cbm')
 
 
 
142
 
143
  # Define inputs
144
  input_layout()
 
120
 
121
  if __name__ == "__main__":
122
 
 
 
123
 
124
  ## --- Page config ------------ ##
125
  # Set page title
 
133
 
134
  # Set page footer
135
  footer()
136
+
137
+ ## --------------------------- ##
138
 
139
  # Load classification model
140
  model = CatBoostClassifier() # parameters not required.
141
+ for root, dirs, files in os.walk("./"):
142
+ for file in files:
143
+ if file.endswith(".cbm"):
144
+ model.load_model(os.path.join(root, file))
145
 
146
  # Define inputs
147
  input_layout()