Update app.py
Browse files
app.py
CHANGED
@@ -104,7 +104,42 @@ def object_detection_app():
|
|
104 |
# ... Implement your code for object detection ...
|
105 |
pass
|
106 |
|
107 |
-
# Main function
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
108 |
|
109 |
if __name__ == "__main__":
|
110 |
main()
|
|
|
104 |
# ... Implement your code for object detection ...
|
105 |
pass
|
106 |
|
107 |
+
# Main function
|
108 |
+
def main():
|
109 |
+
st.sidebar.title("Navigation")
|
110 |
+
selection = st.sidebar.radio("Go to", ["Home", "Dataset Analysis", "Evaluation Results", "Run Inference", "Dissertation Report", "Object Detection"])
|
111 |
+
|
112 |
+
if selection == "Home":
|
113 |
+
st.title("MultiModal Learning for Knowledg-Based Visual Question Answering")
|
114 |
+
st.write("Home page content goes here...")
|
115 |
+
|
116 |
+
elif selection == "Dissertation Report":
|
117 |
+
st.title("Dissertation Report")
|
118 |
+
st.write("Click the link below to view the PDF.")
|
119 |
+
# Example to display a link to a PDF
|
120 |
+
st.download_button(
|
121 |
+
label="Download PDF",
|
122 |
+
data=open("Files/Dissertation Report.pdf", "rb"),
|
123 |
+
file_name="example.pdf",
|
124 |
+
mime="application/octet-stream"
|
125 |
+
)
|
126 |
+
|
127 |
+
|
128 |
+
elif selection == "Evaluation Results":
|
129 |
+
st.title("Evaluation Results")
|
130 |
+
st.write("This is a Place Holder until the contents are uploaded.")
|
131 |
+
|
132 |
+
|
133 |
+
elif selection == "Dataset Analysis":
|
134 |
+
st.title("OK-VQA Dataset Analysis")
|
135 |
+
st.write("This is a Place Holder until the contents are uploaded.")
|
136 |
+
|
137 |
+
|
138 |
+
elif selection == "Run Inference":
|
139 |
+
run_inference()
|
140 |
+
|
141 |
+
elif selection == "Object Detection":
|
142 |
+
run_object_detection()
|
143 |
|
144 |
if __name__ == "__main__":
|
145 |
main()
|