Update app.py
Browse files
app.py
CHANGED
@@ -96,24 +96,24 @@ if st.button("Predict"):
|
|
96 |
"race": race,
|
97 |
"is_hispanic": is_hispanic,
|
98 |
"employment_commitment": employment_commitment,
|
99 |
-
"wage_per_hour": wage_per_hour,
|
100 |
-
"working_week_per_year": working_week_per_year,
|
101 |
-
"industry_code": industry_code,
|
102 |
"industry_code_main": industry_code_main,
|
103 |
-
"occupation_code": occupation_code,
|
104 |
"occupation_code_main": occupation_code_main,
|
105 |
-
"total_employed": total_employed,
|
106 |
"household_stat": household_stat,
|
107 |
"household_summary": household_summary,
|
108 |
-
"vet_benefit": vet_benefit,
|
109 |
"tax_status": tax_status,
|
110 |
-
"gains": gains,
|
111 |
-
"losses": losses,
|
112 |
-
"stocks_status": stocks_status,
|
113 |
"citizenship": citizenship,
|
114 |
-
"mig_year": mig_year,
|
115 |
"country_of_birth_own": country_of_birth_own,
|
116 |
-
"importance_of_record": importance_of_record
|
117 |
}
|
118 |
# Send a POST request to the FastAPI server
|
119 |
response = requests.post("https://rasmodev-income-prediction-fastapi.hf.space/docs#/default/predict_income_predict__post", json=user_input)
|
|
|
96 |
"race": race,
|
97 |
"is_hispanic": is_hispanic,
|
98 |
"employment_commitment": employment_commitment,
|
99 |
+
"wage_per_hour": int(wage_per_hour),
|
100 |
+
"working_week_per_year": int(working_week_per_year),
|
101 |
+
"industry_code": int(industry_code),
|
102 |
"industry_code_main": industry_code_main,
|
103 |
+
"occupation_code": int(occupation_code),
|
104 |
"occupation_code_main": occupation_code_main,
|
105 |
+
"total_employed": int(total_employed),
|
106 |
"household_stat": household_stat,
|
107 |
"household_summary": household_summary,
|
108 |
+
"vet_benefit": int(vet_benefit),
|
109 |
"tax_status": tax_status,
|
110 |
+
"gains": int(gains),
|
111 |
+
"losses": int(losses),
|
112 |
+
"stocks_status": int(stocks_status),
|
113 |
"citizenship": citizenship,
|
114 |
+
"mig_year": int(mig_year),
|
115 |
"country_of_birth_own": country_of_birth_own,
|
116 |
+
"importance_of_record": float(importance_of_record)
|
117 |
}
|
118 |
# Send a POST request to the FastAPI server
|
119 |
response = requests.post("https://rasmodev-income-prediction-fastapi.hf.space/docs#/default/predict_income_predict__post", json=user_input)
|