Spaces:
Sleeping
Sleeping
Upload 10 files
Browse files- .gitattributes +1 -0
- Smartphone_price_predictor.ipynb +0 -0
- Smartphones_price.csv +0 -0
- app.py +42 -0
- df.pkl +3 -0
- mobile.mp4 +0 -0
- mobile.png +0 -0
- mobile01.png +3 -0
- pipe.pkl +3 -0
- screencapture.png +0 -0
- smartphone.png +0 -0
.gitattributes
CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
36 |
+
mobile01.png filter=lfs diff=lfs merge=lfs -text
|
Smartphone_price_predictor.ipynb
ADDED
The diff for this file is too large to render.
See raw diff
|
|
Smartphones_price.csv
ADDED
The diff for this file is too large to render.
See raw diff
|
|
app.py
ADDED
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import streamlit as st
|
2 |
+
import pickle
|
3 |
+
import numpy as np
|
4 |
+
|
5 |
+
# import the model
|
6 |
+
pipe = pickle.load(open('pipe.pkl','rb'))
|
7 |
+
df = pickle.load(open('df.pkl','rb'))
|
8 |
+
|
9 |
+
st.title("Smartphone Price Predictor")
|
10 |
+
# Main page content
|
11 |
+
st.image('mobile.png', use_column_width=True)
|
12 |
+
|
13 |
+
# brand
|
14 |
+
Company = st.selectbox('Brand',df['Brand'].unique())
|
15 |
+
|
16 |
+
# year
|
17 |
+
Released_Year = st.selectbox('Released Year',df['Released Year'].unique())
|
18 |
+
|
19 |
+
# OS
|
20 |
+
Operating_System = st.selectbox('OS',df['OS'].unique())
|
21 |
+
|
22 |
+
# size
|
23 |
+
Display = st.number_input('Display (Inches)')
|
24 |
+
|
25 |
+
# Camera
|
26 |
+
Camera = st.number_input('Camera (MP)')
|
27 |
+
|
28 |
+
# resolution
|
29 |
+
Camera_Resolution= st.selectbox('Camera Resolution',df['Camera Resolution'].unique())
|
30 |
+
|
31 |
+
# Ram
|
32 |
+
Ram = st.number_input('Ram (GB)')
|
33 |
+
|
34 |
+
# Battery
|
35 |
+
Battery = st.number_input('Battery (mAh)')
|
36 |
+
|
37 |
+
|
38 |
+
|
39 |
+
if st.button('Predict Price'):
|
40 |
+
query = np.array([Company, Released_Year, Operating_System, Display, Camera, Camera_Resolution, Ram, Battery])
|
41 |
+
query = query.reshape(1, -1)
|
42 |
+
st.title("The predicted price of this configuration mobile is " + str(int(np.exp(pipe.predict(query)[0]))) + ' TK.')
|
df.pkl
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:bdf31763fce8631ef59884d498005c2348358433b440fddf80a86bc21daa20d1
|
3 |
+
size 133166
|
mobile.mp4
ADDED
Binary file (317 kB). View file
|
|
mobile.png
ADDED
![]() |
mobile01.png
ADDED
![]() |
Git LFS Details
|
pipe.pkl
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b4ea307b7a098fd96750149272ace12963121e89ab8bad9075131f21d3f4504f
|
3 |
+
size 588657
|
screencapture.png
ADDED
![]() |
smartphone.png
ADDED
![]() |