epalvarez commited on
Commit
2aefedd
·
verified ·
1 Parent(s): e95be4c

prediction[0][0][0] trying to get the float value

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -81,12 +81,12 @@ def predict_insurance_charge(age, bmi, children, sex, smoker, region):
81
  'sex': sex,
82
  'smoker': smoker,
83
  'region': region,
84
- 'prediction': prediction[0]
85
  }
86
  ))
87
  f.write("\n")
88
 
89
- prediction_result = prediction[0]
90
  print(f"\nDebug - Prediction result: {prediction_result} - {type(prediction_result)}\n")
91
  return prediction_result
92
 
 
81
  'sex': sex,
82
  'smoker': smoker,
83
  'region': region,
84
+ 'prediction': prediction[0][0][0]
85
  }
86
  ))
87
  f.write("\n")
88
 
89
+ prediction_result = prediction[0][0][0]S
90
  print(f"\nDebug - Prediction result: {prediction_result} - {type(prediction_result)}\n")
91
  return prediction_result
92