Tinsae commited on
Commit
9df66d4
·
1 Parent(s): 154d2a2
app.py CHANGED
@@ -1,8 +1,8 @@
1
  import streamlit as st
2
  from streamlit_option_menu import option_menu
3
- #import ast
4
  from PIL import Image
5
- #import leafmap.foliumap as leafmap
6
  from apps import home,eda,models,demo
7
 
8
  st.set_page_config(layout="wide")
 
1
  import streamlit as st
2
  from streamlit_option_menu import option_menu
3
+ import ast
4
  from PIL import Image
5
+ import leafmap.foliumap as leafmap
6
  from apps import home,eda,models,demo
7
 
8
  st.set_page_config(layout="wide")
apps/__pycache__/demo.cpython-37.pyc ADDED
Binary file (362 Bytes). View file
 
apps/__pycache__/eda.cpython-37.pyc ADDED
Binary file (360 Bytes). View file
 
apps/__pycache__/home.cpython-37.pyc ADDED
Binary file (1.33 kB). View file
 
apps/__pycache__/models.cpython-37.pyc ADDED
Binary file (366 Bytes). View file
 
apps/demo.py CHANGED
@@ -1,4 +1,5 @@
1
  import streamlit as st
 
2
 
3
 
4
  def app():
 
1
  import streamlit as st
2
+ import leafmap.foliumap as leafmap
3
 
4
 
5
  def app():
apps/eda.py CHANGED
@@ -1,4 +1,5 @@
1
  import streamlit as st
 
2
 
3
  def app():
4
  st.title("EDA")
 
1
  import streamlit as st
2
+ import leafmap.foliumap as leafmap
3
 
4
  def app():
5
  st.title("EDA")
apps/home.py CHANGED
@@ -1,7 +1,5 @@
1
  import streamlit as st
2
- import pandas as pd
3
- import folium
4
- from streamlit_folium import st_folium
5
 
6
  def app():
7
 
@@ -27,22 +25,19 @@ def app():
27
  # layers = None
28
 
29
 
30
- # url = "https://services.terrascope.be/wms/v2"
31
- # m = leafmap.Map(center=(42.3, 14), zoom=6)
32
- # m.to_streamlit(height=height)
33
- map = folium.Map(location=[42.3, 14], zoom_start=6, scrollWheelZoom=True, tiles='CartoDB positron')
34
-
35
- choropleth = folium.Choropleth(
36
- geo_data='data/limits_IT_provinces.geojson',
37
- #data=df,
38
- #columns=('State Name', 'State Total Reports Quarter'),
39
- #key_on='feature.properties.name',
40
- #line_opacity=0.8,
41
- #highlight=True
42
- )
43
- choropleth.geojson.add_to(map)
44
 
45
- st_folium(map, width=800, height=600)
 
 
 
 
 
 
46
 
 
47
 
48
 
 
 
 
 
1
  import streamlit as st
2
+ import leafmap.foliumap as leafmap
 
 
3
 
4
  def app():
5
 
 
25
  # layers = None
26
 
27
 
28
+ url = "https://services.terrascope.be/wms/v2"
 
 
 
 
 
 
 
 
 
 
 
 
 
29
 
30
+ m = leafmap.Map(center=(42.3, 14), zoom=6)
31
+ m.add_geojson("data/limits_IT_provinces.geojson")
32
+ # if layers is not None:
33
+ # for layer in layers:
34
+ # m.add_wms_layer(
35
+ # url, layers=layer, name=layer, attribution=" ", transparent=True
36
+ # )
37
 
38
+ m.to_streamlit(height=height)
39
 
40
 
41
+ # def get_layers(url):
42
+ # options = leafmap.get_wms_layers(url)
43
+ # return options
apps/models.py CHANGED
@@ -1,5 +1,5 @@
1
  import streamlit as st
2
-
3
 
4
 
5
  def app():
 
1
  import streamlit as st
2
+ import leafmap.foliumap as leafmap
3
 
4
 
5
  def app():
requirements.txt CHANGED
@@ -1,3 +1,3 @@
1
- folium
2
- streamlit_folium
3
  streamlit-option-menu
 
1
+ leafmap
2
+ owslib
3
  streamlit-option-menu