sp1505 commited on
Commit
9d389ca
·
verified ·
1 Parent(s): ac35b35

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +18 -18
app.py CHANGED
@@ -7,28 +7,28 @@ st.title("Product Sales Prediction App")
7
  st.write("This tool predicts production sales prediction. Enter the required information below.")
8
 
9
  # Collect user input based on dataset columns
10
- weight = st.number_input("Product Weight", min_value=1, max_value=99999999)
11
- sugarcontent = st.selectbox("Product Sugar Content", ["Low Sugar", "No Sugar", "Regular Sugar", "reg"])
12
- area = st.number_input("Product allocated area", min_value=1, max_value=9999999)
13
- producttype = st.selectbox("Product type", ["Frozen Foods", "Dairy", "Canned", "Baking Goods", "Health and Hygiene", "Snack Foods", "Meat", "Household", "Hard Drinks", "Fruits and Vegetables",
14
  "Breads", "Others", "Starchy Foods", "Seafood"])
15
- productmrp = st.number_input("Product MRP", value=100)
16
- year = st.number_input("Store establishment year", value=2007)
17
- storesize = st.selectbox("store size", ["Small", "Medium", "High"])
18
- citytype = st.selectbox("City type", ["Tier1", "Tier2", "Tier3"])
19
- storetype = st.selectbox("store type", ["Supermarket Type1", "Supermarket Type2", "Food Mart", "Departmental Store"])
20
 
21
  # Convert categorical inputs to match model training
22
  customer_data = {
23
- 'Product Weight': weight,
24
- 'Product Sugar Content':sugarcontent,
25
- 'Product allocated area': area,
26
- 'Product Type': producttype,
27
- 'Product MRP': productmrp,
28
- 'Store establishment year': year,
29
- 'store size': storesize,
30
- 'City type': citytype,
31
- 'store type': storetype,
32
  }
33
 
34
 
 
7
  st.write("This tool predicts production sales prediction. Enter the required information below.")
8
 
9
  # Collect user input based on dataset columns
10
+ weight = st.number_input("Product_Weight", min_value=1.0)
11
+ sugarcontent = st.selectbox("Product_Sugar_Content", ["Low Sugar", "No Sugar", "Regular Sugar", "reg"])
12
+ area = st.number_input("Product_Allocated_Area", min_value=1, max_value=9999999)
13
+ producttype = st.selectbox("Product_Type", ["Frozen Foods", "Dairy", "Canned", "Baking Goods", "Health and Hygiene", "Snack Foods", "Meat", "Household", "Hard Drinks", "Fruits and Vegetables",
14
  "Breads", "Others", "Starchy Foods", "Seafood"])
15
+ productmrp = st.number_input("Product_MRP", value=100)
16
+ year = st.number_input("Store_Establishment_Year", value=2007)
17
+ storesize = st.selectbox("Store_Size", ["Small", "Medium", "High"])
18
+ citytype = st.selectbox("Store_Location_City_Type", ["Tier1", "Tier2", "Tier3"])
19
+ storetype = st.selectbox("Store_Type", ["Supermarket Type1", "Supermarket Type2", "Food Mart", "Departmental Store"])
20
 
21
  # Convert categorical inputs to match model training
22
  customer_data = {
23
+ 'Product_Weight': weight,
24
+ 'Product_Sugar_Content':sugarcontent,
25
+ 'Product_Allocated_Area': area,
26
+ 'Product_Type': producttype,
27
+ 'Product_MRP': productmrp,
28
+ 'Store_Establishment_Year': year,
29
+ 'Store_Size': storesize,
30
+ 'Store_Location_City_Type': citytype,
31
+ 'Store_Type': storetype,
32
  }
33
 
34