Spaces:
Sleeping
Sleeping
qqubb
commited on
Commit
·
09a1ec9
1
Parent(s):
21f8f36
make download buttons visible
Browse files- __pycache__/utils.cpython-310.pyc +0 -0
- app.py +19 -16
__pycache__/utils.cpython-310.pyc
CHANGED
Binary files a/__pycache__/utils.cpython-310.pyc and b/__pycache__/utils.cpython-310.pyc differ
|
|
app.py
CHANGED
@@ -48,7 +48,7 @@ st.markdown(
|
|
48 |
unsafe_allow_html=True,
|
49 |
)
|
50 |
|
51 |
-
st.title("AI ACTCELERATE")
|
52 |
|
53 |
selected_example = st.selectbox("Select an example project", list(directories.keys()))
|
54 |
uploaded_files = st.file_uploader("or upload Compliance Cards", type="yaml", accept_multiple_files=True)
|
@@ -113,11 +113,12 @@ with project_col:
|
|
113 |
|
114 |
updated_project_cc = yaml.dump(project_cc, sort_keys=False)
|
115 |
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
|
|
121 |
)
|
122 |
else:
|
123 |
st.write("Missing project file")
|
@@ -159,11 +160,12 @@ with data_col:
|
|
159 |
|
160 |
data_cc_yaml_data = yaml.dump(data_cc, sort_keys=False)
|
161 |
|
162 |
-
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
|
|
167 |
)
|
168 |
else:
|
169 |
st.write("Missing data file")
|
@@ -199,11 +201,12 @@ with model_col:
|
|
199 |
|
200 |
model_cc_yaml_data = yaml.dump(model_cc, sort_keys=False)
|
201 |
|
202 |
-
|
203 |
-
|
204 |
-
|
205 |
-
|
206 |
-
|
|
|
207 |
)
|
208 |
else:
|
209 |
st.write("Missing data file")
|
|
|
48 |
unsafe_allow_html=True,
|
49 |
)
|
50 |
|
51 |
+
st.title(":flag-eu: AI ACTCELERATE :scales: :rocket:")
|
52 |
|
53 |
selected_example = st.selectbox("Select an example project", list(directories.keys()))
|
54 |
uploaded_files = st.file_uploader("or upload Compliance Cards", type="yaml", accept_multiple_files=True)
|
|
|
113 |
|
114 |
updated_project_cc = yaml.dump(project_cc, sort_keys=False)
|
115 |
|
116 |
+
st.download_button(
|
117 |
+
label=f"Download Updated Project CC as YAML",
|
118 |
+
data=updated_project_cc,
|
119 |
+
file_name="updated_project.yaml",
|
120 |
+
mime="text/yaml",
|
121 |
+
use_container_width = True
|
122 |
)
|
123 |
else:
|
124 |
st.write("Missing project file")
|
|
|
160 |
|
161 |
data_cc_yaml_data = yaml.dump(data_cc, sort_keys=False)
|
162 |
|
163 |
+
st.download_button(
|
164 |
+
label=f"Download Updated {card[0]} CC as YAML",
|
165 |
+
data=data_cc_yaml_data,
|
166 |
+
file_name=f"updated_{card[0]}.yaml",
|
167 |
+
mime="text/yaml",
|
168 |
+
use_container_width = True
|
169 |
)
|
170 |
else:
|
171 |
st.write("Missing data file")
|
|
|
201 |
|
202 |
model_cc_yaml_data = yaml.dump(model_cc, sort_keys=False)
|
203 |
|
204 |
+
st.download_button(
|
205 |
+
label=f"Download Updated {card[0]} CC as YAML",
|
206 |
+
data=model_cc_yaml_data,
|
207 |
+
file_name=f"updated_{card[0]}.yaml",
|
208 |
+
mime="text/yaml",
|
209 |
+
use_container_width = True
|
210 |
)
|
211 |
else:
|
212 |
st.write("Missing data file")
|