Eemansleepdeprived commited on
Commit
d602b4d
·
1 Parent(s): f32e461

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -8,7 +8,10 @@ from csv import writer
8
  # st.title('Dawg Detection 🐶')
9
  st.markdown("<h1 style='text-align: center; color: white;'>Dawg Detection 🐶</h1>", unsafe_allow_html=True)
10
  jury=True
11
- butt=st.button('Configure',disabled=jury)
 
 
 
12
  if butt==True:
13
  os.system('git clone https://github.com/WongKinYiu/yolov7')
14
  os.system('%cd yolov7')
@@ -19,7 +22,7 @@ if butt==True:
19
  os.system('conda install pytorch torchvision torchaudio -c pytorch -y')
20
  os.system('pip install pyyaml')
21
  os.system('pip install scipy')
22
- jury=False
23
 
24
 
25
  bob='python yolov7/detect.py --weights yolov7.pt --classes 16 --conf 0.25 --img-size 640 --source Images/seesh.png --exist-ok --save-conf --save-txt'
 
8
  # st.title('Dawg Detection 🐶')
9
  st.markdown("<h1 style='text-align: center; color: white;'>Dawg Detection 🐶</h1>", unsafe_allow_html=True)
10
  jury=True
11
+ if 'jury' not in st.session_state:
12
+ st.session_state.jury = False
13
+
14
+ butt=st.button('Configure',disabled=st.session_state.jury,help='Press This And Wait A Few Seconds If You Are Running The Website For The First Time')
15
  if butt==True:
16
  os.system('git clone https://github.com/WongKinYiu/yolov7')
17
  os.system('%cd yolov7')
 
22
  os.system('conda install pytorch torchvision torchaudio -c pytorch -y')
23
  os.system('pip install pyyaml')
24
  os.system('pip install scipy')
25
+ st.session_state.jury = True
26
 
27
 
28
  bob='python yolov7/detect.py --weights yolov7.pt --classes 16 --conf 0.25 --img-size 640 --source Images/seesh.png --exist-ok --save-conf --save-txt'