BrainAI-1 commited on
Commit
6aa4003
ยท
verified ยท
1 Parent(s): 4b26728

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -11,7 +11,8 @@ st.set_page_config(
11
  st.title(":blue[Object Detection] :black_cat:")
12
  st.sidebar.header("๋ฉ”๋‰ด")
13
  source_radio = st.sidebar.radio("์„ ํƒํ•˜์„ธ์š”", ["IMAGE", "VIDEO", "GAME"])
14
- st.session_state.random_class = object_detection.call_class()
 
15
 
16
  if source_radio == "IMAGE":
17
  st.write(":green[์™ผ์ชฝ ๋ฉ”๋‰ด 'Browse files' ๋ฒ„ํŠผ์„ ํด๋ฆญํ•˜์—ฌ ์ด๋ฏธ์ง€ ํŒŒ์ผ์„ ์„ ํƒํ•˜๋ฉด AI ์ถ”๋ก ์ด ์‹œ์ž‘๋ฉ๋‹ˆ๋‹ค.]" )
@@ -65,9 +66,6 @@ elif source_radio == "GAME":
65
  st.header(f':{st.session_state.random_class}: ์ฐพ์„ ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค')
66
 
67
  st.image(result_img)
68
-
69
-
70
-
71
 
72
 
73
 
 
11
  st.title(":blue[Object Detection] :black_cat:")
12
  st.sidebar.header("๋ฉ”๋‰ด")
13
  source_radio = st.sidebar.radio("์„ ํƒํ•˜์„ธ์š”", ["IMAGE", "VIDEO", "GAME"])
14
+ if 'random_class' not in st.session_state:
15
+ st.session_state.random_class = object_detection.call_class()
16
 
17
  if source_radio == "IMAGE":
18
  st.write(":green[์™ผ์ชฝ ๋ฉ”๋‰ด 'Browse files' ๋ฒ„ํŠผ์„ ํด๋ฆญํ•˜์—ฌ ์ด๋ฏธ์ง€ ํŒŒ์ผ์„ ์„ ํƒํ•˜๋ฉด AI ์ถ”๋ก ์ด ์‹œ์ž‘๋ฉ๋‹ˆ๋‹ค.]" )
 
66
  st.header(f':{st.session_state.random_class}: ์ฐพ์„ ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค')
67
 
68
  st.image(result_img)
 
 
 
69
 
70
 
71