Upload 3 files
Browse files- README.md +2 -0
- main.py +42 -0
- requirements.txt +4 -0
README.md
ADDED
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
1 |
+
# medNER_V2
|
2 |
+
This app performs Named Entity REcognition of medical entties.
|
main.py
ADDED
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import streamlit as st
|
2 |
+
|
3 |
+
# --- SHARED ON ALL PAGES ---
|
4 |
+
#st.logo(image=":material/medical_information:")
|
5 |
+
#st.logo("/home/ubuntu/Desktop/Univ_Bern/CAS NLP /Module_6/medNER/images/medical_information_24dp_1F1F1F_FILL0_wght400_GRAD0_opsz24.png")
|
6 |
+
st.logo("images/medical_information_24dp_1F1F1F_FILL0_wght400_GRAD0_opsz24.png")
|
7 |
+
st.sidebar.text("Project by SPG")
|
8 |
+
|
9 |
+
|
10 |
+
# --- PAGE SETUP ---
|
11 |
+
home_page = st.Page(
|
12 |
+
page="pages/home.py",
|
13 |
+
title="Home",
|
14 |
+
icon=":material/home:",
|
15 |
+
default=True,)
|
16 |
+
|
17 |
+
type_text_page = st.Page(
|
18 |
+
page="pages/type_text.py",
|
19 |
+
title="type text",
|
20 |
+
icon=":material/keyboard:",
|
21 |
+
default=False,)
|
22 |
+
|
23 |
+
upload_file_page = st.Page(
|
24 |
+
page="pages/upload_file.py",
|
25 |
+
title="upload file",
|
26 |
+
icon=":material/file_upload:",
|
27 |
+
default=False,)
|
28 |
+
|
29 |
+
about_page = st.Page(
|
30 |
+
page="pages/about.py",
|
31 |
+
title="About the app",
|
32 |
+
icon=":material/info:",
|
33 |
+
default=False)
|
34 |
+
|
35 |
+
|
36 |
+
# --- NAVIGATION SETUP ---
|
37 |
+
#pg = st.navigation(pages=[home_page, type_text_page, upload_file_page, about_page]) # WITHOUT SECTIONS
|
38 |
+
pg = st.navigation({"Home": [home_page], "Demo": [type_text_page, upload_file_page], "About": [about_page]}) # WITH SECTIONS
|
39 |
+
|
40 |
+
pg.run()
|
41 |
+
|
42 |
+
|
requirements.txt
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
streamlit==1.41.1
|
2 |
+
pandas==2.2.2
|
3 |
+
torch==2.4.0
|
4 |
+
transformers==4.44.2
|