minju0730 commited on
Commit
b40dbb3
ยท
verified ยท
1 Parent(s): e87af7e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -4
app.py CHANGED
@@ -26,8 +26,9 @@ st.write(''' ์ „๋ฌธ๊ฐ€ OOO์— ๋”ฐ๋ฅด๋ฉด ~~~~~''')
26
 
27
 
28
  # ์‚ฌ์ง„ ์‚ฝ์ž…
29
- st.image('photo1.jpg', caption='์ง€๋‚œ 4์›”20์ผ ๊ฒฝํฌ๋Œ€ ๊ต๋‚ด์—์„œ ํ•™์ƒ๋“ค์ด ํ‘ธ๋“œํŠธ๋Ÿญ์—์„œ ์Œ์‹์„ ๊ตฌ๋งคํ•˜๊ณ  ์žˆ๋‹ค')
30
- st.image('photo2.jpg', caption='๊ฒฝํฌ๋Œ€ ๊ทผ์ฒ˜ ๋ง›์ง‘ ์ง€๋„(--- ์ œ๊ณต)')
 
31
 
32
  # ๋ฐ์ดํ„ฐ ๋ถˆ๋Ÿฌ์˜ค๊ธฐ
33
  df = pd.read_excel('data_traffic_accidents.xlsx', index_col=0)
@@ -56,14 +57,14 @@ st.image('network.png')
56
  # ๊ทธ๋ž˜ํ”„ html ๋ณด์—ฌ์ฃผ๊ธฐ
57
  st.write('''์ทจ์žฌํŒ€์€ ๊ตํ†ต์‚ฌ๊ณ  ์‚ฌ๊ณ ๊ฑด์ˆ˜์™€ ์‚ฌ๋ง์ž์ˆ˜ ๊ฐ„์˜ ๊ด€๊ณ„๋ฅผ ๊ทธ๋ž˜ํ”„๋กœ ํ‘œ์‹œํ–ˆ๋‹ค ๋ถ„์„๊ฒฐ๊ณผ, ~~์„ค๋ช…~~
58
  ๊ทธ๋ž˜ํ”„ ๊ฐ ์ ์— ๋งˆ์šฐ์Šค๋ฅผ ๋†“์œผ๋ฉด ์ง€์—ญ ์ •๋ณด๊ฐ€ ๋‚˜ํƒ€๋‚œ๋‹ค''')
59
- with open('๋ฌด์ธ์ ํฌ_์ข…๋ฅ˜.html', 'r', encoding='utf-8') as f:
60
  html_content1 = f.read()
61
  st.components.v1.html(html_content1, height=500) # markdown๋ณด๋‹ค ๋ณต์žกํ•œ html ํŒŒ์ผ ์ž‘๋™์— ๊ฐ•ํ•จ
62
 
63
  # ์ง€๋„ html ๋ณด์—ฌ์ฃผ๊ธฐ
64
  st.write('''์ทจ์žฌํŒ€์€ ์„œ์šธ์‹œ ์ฃผ์š” ๋Œ€ํ•™์˜ ์œ„์น˜์™€ ์ •๋ณด๋ฅผ ์ง€๋„์— ํ‘œ๊ธฐํ•ด ๋ณด์•˜๋‹ค. ๋ถ„์„๊ฒฐ๊ณผ, ~~์„ค๋ช…~~
65
  ์ง€๋„ ์œ„ ํ‘œ๊ธฐ ์ง€์ ์— ๋งˆ์šฐ์Šค๋ฅผ ๋†“์œผ๋ฉด ๊ด€๋ จ ์ •๋ณด๊ฐ€ ๋‚˜ํƒ€๋‚œ๋‹ค''')
66
- with open('์ง€์—ญ๋ณ„_์ ˆ๋„๊ฑด์ˆ˜_map.html', 'r', encoding='utf-8') as f:
67
  html_content2 = f.read()
68
  st.components.v1.html(html_content2, height=500)
69
 
 
26
 
27
 
28
  # ์‚ฌ์ง„ ์‚ฝ์ž…
29
+ st.image('photo1.jpeg', caption='๋ฌด์ธ์ ํฌ ์‚ฌ์ง„')
30
+ st.image('photo2.jpeg', caption='๋งค์žฅ๋‚ด cctv')
31
+ st.image('photo3.jpeg', caption='์ถœ์ž…์ธ์ฆ์žฅ์น˜')
32
 
33
  # ๋ฐ์ดํ„ฐ ๋ถˆ๋Ÿฌ์˜ค๊ธฐ
34
  df = pd.read_excel('data_traffic_accidents.xlsx', index_col=0)
 
57
  # ๊ทธ๋ž˜ํ”„ html ๋ณด์—ฌ์ฃผ๊ธฐ
58
  st.write('''์ทจ์žฌํŒ€์€ ๊ตํ†ต์‚ฌ๊ณ  ์‚ฌ๊ณ ๊ฑด์ˆ˜์™€ ์‚ฌ๋ง์ž์ˆ˜ ๊ฐ„์˜ ๊ด€๊ณ„๋ฅผ ๊ทธ๋ž˜ํ”„๋กœ ํ‘œ์‹œํ–ˆ๋‹ค ๋ถ„์„๊ฒฐ๊ณผ, ~~์„ค๋ช…~~
59
  ๊ทธ๋ž˜ํ”„ ๊ฐ ์ ์— ๋งˆ์šฐ์Šค๋ฅผ ๋†“์œผ๋ฉด ์ง€์—ญ ์ •๋ณด๊ฐ€ ๋‚˜ํƒ€๋‚œ๋‹ค''')
60
+ with open('bokeh_plot.html', 'r', encoding='utf-8') as f:
61
  html_content1 = f.read()
62
  st.components.v1.html(html_content1, height=500) # markdown๋ณด๋‹ค ๋ณต์žกํ•œ html ํŒŒ์ผ ์ž‘๋™์— ๊ฐ•ํ•จ
63
 
64
  # ์ง€๋„ html ๋ณด์—ฌ์ฃผ๊ธฐ
65
  st.write('''์ทจ์žฌํŒ€์€ ์„œ์šธ์‹œ ์ฃผ์š” ๋Œ€ํ•™์˜ ์œ„์น˜์™€ ์ •๋ณด๋ฅผ ์ง€๋„์— ํ‘œ๊ธฐํ•ด ๋ณด์•˜๋‹ค. ๋ถ„์„๊ฒฐ๊ณผ, ~~์„ค๋ช…~~
66
  ์ง€๋„ ์œ„ ํ‘œ๊ธฐ ์ง€์ ์— ๋งˆ์šฐ์Šค๋ฅผ ๋†“์œผ๋ฉด ๊ด€๋ จ ์ •๋ณด๊ฐ€ ๋‚˜ํƒ€๋‚œ๋‹ค''')
67
+ with open('folium_map.html', 'r', encoding='utf-8') as f:
68
  html_content2 = f.read()
69
  st.components.v1.html(html_content2, height=500)
70