KB-VQA / app.py
m7mdal7aj's picture
Update app.py
c183786 verified
raw
history blame
936 Bytes
import streamlit as st
import torch
import bitsandbytes
import accelerate
import scipy
import copy
from PIL import Image
import torch.nn as nn
import pandas as pd
from my_model.object_detection import detect_and_draw_objects
from my_model.captioner.image_captioning import get_caption
from my_model.gen_utilities import free_gpu_resources
from my_model.KBVQA import KBVQA, prepare_kbvqa_model
from my_model.utilities.st_utils import UIManager, StateManager
def main():
ui_manager = UIManager()
selection = ui_manager.display_sidebar()
ui_manager.display_selected_page("Home")
ui_manager.display_selected_page("Dataset Analysis")
ui_manager.display_selected_page("Finetuning and Evaluation Results")
ui_manager.display_selected_page("Run Inference")
ui_manager.display_selected_page("Code")
ui_manager.display_selected_page("More Pages will follow .. ")
if __name__ == "__main__":
main()