Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -7,7 +7,7 @@ import pickle
|
|
7 |
with open("model.pkl", "rb") as f:
|
8 |
model = pickle.load(f)
|
9 |
|
10 |
-
st.write(""" # Mobile Price-Range Prediction""")
|
11 |
st.sidebar.header("Choose Phone Specs")
|
12 |
|
13 |
def input_features():
|
@@ -30,4 +30,4 @@ st.write(feats)
|
|
30 |
if st.button("Result"):
|
31 |
#res = requests.post(url = "http://0.0.0.0:8008/predict", data=json.dumps(data)).text
|
32 |
res = model.predict(feats)
|
33 |
-
st.subheader(f"Predicted Price Range: {res}")
|
|
|
7 |
with open("model.pkl", "rb") as f:
|
8 |
model = pickle.load(f)
|
9 |
|
10 |
+
st.write(""" # Mobile Price-Range Prediction\n ## Prices ranges from 0 to 3""")
|
11 |
st.sidebar.header("Choose Phone Specs")
|
12 |
|
13 |
def input_features():
|
|
|
30 |
if st.button("Result"):
|
31 |
#res = requests.post(url = "http://0.0.0.0:8008/predict", data=json.dumps(data)).text
|
32 |
res = model.predict(feats)
|
33 |
+
st.subheader(f"Predicted Price Range: {res[0]}")
|