Multilingual-VQA / apps /article.py
gchhablani's picture
Fix tensorboard - last attempt
f54892c
raw
history blame
2.97 kB
import streamlit as st
from apps.utils import read_markdown
from .streamlit_tensorboard import st_tensorboard, kill_tensorboard
from .utils import Toc
def app(state=None):
#kill_tensorboard()
toc = Toc()
st.info("Welcome to our Multilingual-VQA demo. Please use the navigation sidebar to move to our demo, or scroll below to read all about our project. πŸ€— In case the sidebar isn't properly rendered, please change to a smaller window size and back to full screen.")
st.header("Table of contents")
toc.placeholder()
toc.header("Introduction and Motivation")
st.write(read_markdown("intro/intro.md"))
toc.subheader("Novel Contributions")
st.write(read_markdown("intro/contributions.md"))
toc.header("Methodology")
toc.subheader("Pre-training")
st.write(read_markdown("pretraining/intro.md"))
# col1, col2 = st.beta_columns([5,5])
st.image(
"./misc/article/Multilingual-VQA.png",
caption="Masked LM model for Image-text Pre-training.",
)
toc.subsubheader("MLM Dataset")
st.write(read_markdown("pretraining/data.md"))
toc.subsubheader("MLM Model")
st.write(read_markdown("pretraining/model.md"))
toc.subsubheader("MLM Training Logs")
st.info("In case the TensorBoard logs are not displayed, please visit this link: https://huggingface.co/flax-community/multilingual-vqa-pt-ckpts/tensorboard")
if state.tb1 is None:
state.tb1 = st_tensorboard(logdir='./logs/pretrain_logs', port=6006)
toc.subheader("Finetuning")
toc.subsubheader("VQA Dataset")
st.write(read_markdown("finetuning/data.md"))
toc.subsubheader("VQA Model")
st.write(read_markdown("finetuning/model.md"))
toc.subsubheader("VQA Training Logs")
st.info("In case the TensorBoard logs are not displayed, please visit this link: https://huggingface.co/flax-community/multilingual-vqa-pt-60k-ft/tensorboard")
if state.tb2 is None:
state.tb2 = st_tensorboard(logdir='./logs/finetune_logs', port=6007)
toc.header("Challenges and Technical Difficulties")
st.write(read_markdown("challenges.md"))
toc.header("Limitations")
st.write(read_markdown("limitations.md"))
toc.header("Conclusion, Future Work, and Social Impact")
toc.subheader("Conclusion")
st.write(read_markdown("conclusion_future_work/conclusion.md"))
toc.subheader("Future Work")
st.write(read_markdown("conclusion_future_work/future_work.md"))
toc.subheader("Social Impact")
st.write(read_markdown("conclusion_future_work/social_impact.md"))
toc.header("References")
st.write(read_markdown("references.md"))
toc.header("Checkpoints")
st.write(read_markdown("checkpoints/checkpoints.md"))
toc.subheader("Other Checkpoints")
st.write(read_markdown("checkpoints/other_checkpoints.md"))
toc.header("Acknowledgements")
st.write(read_markdown("acknowledgements.md"))
toc.generate()