-
Notifications
You must be signed in to change notification settings - Fork 1
/
streamlit.py
39 lines (32 loc) · 1.2 KB
/
streamlit.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import streamlit as st
from pathlib import Path
import base64
import requests
from MSCI.gui.utils import load_image_from_url, add_custom_css
from MSCI.gui.landing_page import landing_page
from MSCI.gui.peptide_analysis import peptide_twins_analysis, plot_spectra
from MSCI.gui.peptide_checker import peptide_twins_checker
def main():
st.set_page_config(layout="wide")
add_custom_css()
# URL of the image on GitHub
logo_url = "https://github.com/proteomicsunitcrg/MSCI/raw/main/docs/MSCI_logor.png"
logo_image = load_image_from_url(logo_url)
with st.sidebar:
if logo_image:
st.markdown(f"""
<p align="center">
<img src="data:image/png;base64,{logo_image}" alt="logo" width="300" height="300">
</p>
""", unsafe_allow_html=True)
st.header("MSCI")
option = st.radio("Choose an option", ("MSCI", "Peptide Twins Analysis", "Peptide Twins Checker"))
if option == "MSCI":
landing_page()
elif option == "Peptide Twins Analysis":
peptide_twins_analysis()
plot_spectra()
elif option == "Peptide Twins Checker":
peptide_twins_checker()
if __name__ == "__main__":
main()