Spaces:
Running
Running
update app.py
Browse files
app.py
CHANGED
@@ -1,9 +1,6 @@
|
|
1 |
import streamlit as st
|
2 |
import json
|
3 |
|
4 |
-
print(geemap.__version__)
|
5 |
-
print(folium.__version__)
|
6 |
-
print(geemap.Report())
|
7 |
|
8 |
st.set_page_config(layout="wide")
|
9 |
m = st.markdown(
|
@@ -18,15 +15,23 @@ div.stButton > button:first-child {
|
|
18 |
)
|
19 |
|
20 |
|
21 |
-
|
|
|
|
|
|
|
22 |
with open("datasets.json") as f:
|
23 |
-
|
24 |
-
|
|
|
|
|
25 |
|
26 |
-
#
|
27 |
-
st.
|
28 |
-
selected_dataset = st.selectbox("Select a Dataset ID", dataset_ids)
|
29 |
|
30 |
-
#
|
31 |
-
|
32 |
-
|
|
|
|
|
|
|
|
|
|
1 |
import streamlit as st
|
2 |
import json
|
3 |
|
|
|
|
|
|
|
4 |
|
5 |
st.set_page_config(layout="wide")
|
6 |
m = st.markdown(
|
|
|
15 |
)
|
16 |
|
17 |
|
18 |
+
import streamlit as st
|
19 |
+
import json
|
20 |
+
|
21 |
+
# Load dataset categories and sub-options from JSON file
|
22 |
with open("datasets.json") as f:
|
23 |
+
sentinel_categories = json.load(f)
|
24 |
+
|
25 |
+
# Display title
|
26 |
+
st.title("Sentinel Dataset Selector")
|
27 |
|
28 |
+
# First-level selection box for the main category
|
29 |
+
main_selection = st.selectbox("Select Sentinel Dataset Category", list(sentinel_categories.keys()))
|
|
|
30 |
|
31 |
+
# Check the main selection and display the corresponding sub-options
|
32 |
+
if main_selection:
|
33 |
+
sub_options = sentinel_categories[main_selection]
|
34 |
+
sub_selection = st.selectbox("Select Specific Dataset", sub_options)
|
35 |
+
|
36 |
+
# Display the selected sub-option
|
37 |
+
st.write(f"**Selected Dataset ID:** {sub_selection}")
|