Spaces:
Build error
Build error
temp footer
Browse files
app.py
CHANGED
|
@@ -8,7 +8,6 @@ from model import *
|
|
| 8 |
|
| 9 |
# # TODO:
|
| 10 |
# - Reformat the model introduction
|
| 11 |
-
# - Center the images using the 3 column method
|
| 12 |
# - Make the iterative text generation
|
| 13 |
|
| 14 |
def gen_show_caption(sub_prompt=None, cap_prompt = ""):
|
|
@@ -131,4 +130,34 @@ with center:
|
|
| 131 |
if sub is None and imageLoader.text_transform(cap_prompt) is not "":
|
| 132 |
st.write("Without a specified subreddit we default to /r/pics")
|
| 133 |
for i in range(num_captions):
|
| 134 |
-
gen_show_caption(sub, imageLoader.text_transform(cap_prompt))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8 |
|
| 9 |
# # TODO:
|
| 10 |
# - Reformat the model introduction
|
|
|
|
| 11 |
# - Make the iterative text generation
|
| 12 |
|
| 13 |
def gen_show_caption(sub_prompt=None, cap_prompt = ""):
|
|
|
|
| 130 |
if sub is None and imageLoader.text_transform(cap_prompt) is not "":
|
| 131 |
st.write("Without a specified subreddit we default to /r/pics")
|
| 132 |
for i in range(num_captions):
|
| 133 |
+
gen_show_caption(sub, imageLoader.text_transform(cap_prompt))
|
| 134 |
+
|
| 135 |
+
|
| 136 |
+
footer="""<style>
|
| 137 |
+
a:link , a:visited{
|
| 138 |
+
color: blue;
|
| 139 |
+
background-color: transparent;
|
| 140 |
+
text-decoration: underline;
|
| 141 |
+
}
|
| 142 |
+
|
| 143 |
+
a:hover, a:active {
|
| 144 |
+
color: red;
|
| 145 |
+
background-color: transparent;
|
| 146 |
+
text-decoration: underline;
|
| 147 |
+
}
|
| 148 |
+
|
| 149 |
+
.footer {
|
| 150 |
+
position: fixed;
|
| 151 |
+
left: 0;
|
| 152 |
+
bottom: 0;
|
| 153 |
+
width: 100%;
|
| 154 |
+
background-color: white;
|
| 155 |
+
color: black;
|
| 156 |
+
text-align: center;
|
| 157 |
+
}
|
| 158 |
+
</style>
|
| 159 |
+
<div class="footer">
|
| 160 |
+
<p>Developed with ❤ by <a style='display: block; text-align: center;' href="https://www.heflin.dev/" target="_blank">Heflin Stephen Raj S</a></p>
|
| 161 |
+
</div>
|
| 162 |
+
"""
|
| 163 |
+
st.markdown(footer,unsafe_allow_html=True)
|