Spaces:
Runtime error
Runtime error
poornesh110
commited on
Commit
•
866d91b
1
Parent(s):
188d176
Update app.py
Browse files
app.py
CHANGED
@@ -373,6 +373,12 @@ def pneumonia(image):
|
|
373 |
colu = list(X_test.columns[selector.get_support()]) #generating name of columns consisting that feature
|
374 |
|
375 |
Selected_DF = DataFrame[colu]
|
|
|
|
|
|
|
|
|
|
|
|
|
376 |
prediction = model.predict(Selected_DF)
|
377 |
|
378 |
if prediction == 0: # Determine the predicted class
|
|
|
373 |
colu = list(X_test.columns[selector.get_support()]) #generating name of columns consisting that feature
|
374 |
|
375 |
Selected_DF = DataFrame[colu]
|
376 |
+
final_model = RandomForestClassifier(criterion = 'gini',max_depth = None,
|
377 |
+
max_features = None,max_leaf_nodes = None,
|
378 |
+
min_samples_leaf = 3,min_samples_split = 4,
|
379 |
+
min_weight_fraction_leaf = 0.0,n_estimators = 200)
|
380 |
+
train_DF = X_train[colu]
|
381 |
+
final_model.fit(train_DF,y_train)
|
382 |
prediction = model.predict(Selected_DF)
|
383 |
|
384 |
if prediction == 0: # Determine the predicted class
|