NIX3S commited on
Commit
cf15e10
·
1 Parent(s): 78d6ff7

correction

Browse files
Files changed (1) hide show
  1. app.py +7 -1
app.py CHANGED
@@ -14,7 +14,13 @@ def gradio_predict(*args):
14
  "BuildingType_Nonresidential_WA", "ZipCode_infrequent_sklearn",
15
  "EPAPropertyType_infrequent_sklearn"
16
  ]
17
- data = InputData(**args)
 
 
 
 
 
 
18
  prediction = predict(data)
19
  return prediction
20
 
 
14
  "BuildingType_Nonresidential_WA", "ZipCode_infrequent_sklearn",
15
  "EPAPropertyType_infrequent_sklearn"
16
  ]
17
+ # Convertir le tuple en dict
18
+ data_dict = dict(zip(columns, args))
19
+
20
+ # Créer l'objet Pydantic
21
+ data = InputData(**data_dict)
22
+
23
+ # Prédiction
24
  prediction = predict(data)
25
  return prediction
26