Spaces:
Build error
Build error
Update app.py
Browse files1 unmodified line234567898 unmodified lines181920212223242526272829242526272830313233343536373839303140414243441 unmodified lineimport numpy as npimport pickleimport streamlit.components.v1 as componentsfrom sklearn.preprocessing import LabelEncoderle = import LabelEncoder()
# Load the pickled modeldef load_model():8 unmodified lines # Add input fields for High, Open, and Low values image = '17.png' st.image(image, use_column_width=True)
def transform(text): text= le.fit_transform(text) return text[0] st.subheader("Enter the following values:")
Bhk = st.number_input("Bhk") Size = st.number_input("Size") Area_Type = st.number_input("Area_Type") Area_Locality = st.number_input("Area_Locality") City = st.number_input("City") Furnishing_Status = st.number_input("Furnishing_Status") Tenant_Preferred = st.number_input("Tenant_Preferred") Area_Type = st.text_input("Area Type") Area_Type = transform(['Area_Type']) Area_Locality = st.number_input("Area Locality") City = st.text_input("City") City = transform(['City']) Furnishing_Status = st.text_input("Furnishing Status") Furnishing_Status = transform(['Furnishing_Status']) Tenant_Preferred = st.text_input("Tenant Preferred") Tenant_Preferred = transform(['Tenant_Preferred']) Bathroom = st.number_input("Bathroom") Point_of_Contact = st.number_input("Point_of_Contact") Point_of_Contact = st.text_input("Point of Contact") Point_of_Contact = transform(['Point_of_Contact']) # Create a feature list from the user inputs features = [[Bhk,Size,Area_Type,Area_Locality,City,Furnishing_Status,Tenant_Preferred,Bathroom,Point_of_Contact]]app.py+17-7