From 9aa0217b93f6bca2095aa2e94b53f618b40f04e8 Mon Sep 17 00:00:00 2001 From: Benoit Frisque Date: Thu, 24 Oct 2024 17:01:49 +0200 Subject: [PATCH] new structure --- Dashboards/utils/colors.py | 48 ------------------ Dashboards/utils/css_reader.py | 24 --------- {Dashboards => dashboard}/Documentation_DB.md | 0 Dashboards/dashboard.py => dashboard/app.py | 8 +-- .../assets/img/amandinea_punctata.jpg | Bin .../assets/img/anaptychia_ciliaris.jpg | Bin .../assets/img/candelaria_concolor.jpg | Bin .../assets/img/candelariella.jpg | Bin .../assets/img/crustaces_lirelles.jpg | Bin .../assets/img/crustaces_poudreux.jpg | Bin .../assets/img/diploicia_canescens.jpg | Bin .../assets/img/evernia_prunastri.jpg | Bin .../assets/img/flavoparmelia_caperata.jpg | Bin .../assets/img/hyperphyscia_adglutinata.jpg | Bin .../assets/img/hypogymnia_physodes.jpg | Bin .../assets/img/hypotrachyna_afrevoluta.jpg | Bin .../assets/img/lecanora.jpg | Bin .../assets/img/lichen_crustace.jpg | Bin .../assets/img/lichen_foliace.jpg | Bin .../assets/img/lichen_fruticuleux.jpg | Bin .../assets/img/melanelixia_glabratula.jpg | Bin .../assets/img/melanohalea_exasperata.jpg | Bin .../assets/img/parmelia_saxatilis.jpg | Bin .../assets/img/parmelia_sulcata.jpg | Bin .../assets/img/parmelina_tiliacea.jpg | Bin .../assets/img/parmotrema_perlatum.jpg | Bin .../assets/img/pertusaria_pertusa.jpg | Bin .../assets/img/phaeophyscia_orbicularis.jpg | Bin .../assets/img/physcia_adscendens.jpg | Bin .../assets/img/physcia_aipolia.jpg | Bin .../assets/img/physcia_leptalea.jpg | Bin .../assets/img/physconia_distorta.jpg | Bin .../assets/img/physconia_grisea.jpg | Bin .../assets/img/pleurosticta_acetabulum.jpg | Bin .../assets/img/polycauliona_polycarpa.jpg | Bin .../assets/img/pseudevernia_furfuracea.jpg | Bin .../assets/img/punctelia_sp_.jpg | Bin .../assets/img/ramalina_farinacea.jpg | Bin .../assets/img/ramalina_fastigiata.jpg | Bin .../assets/img/ramalina_fraxinea.jpg | Bin .../assets/img/usnea.jpg | Bin .../assets/img/xanthoria_parietina.jpg | Bin .../assets/lichen_species_ecology.csv | 0 {Dashboards => dashboard}/charts.py | 2 +- {Dashboards => dashboard}/constants.py | 0 {Dashboards => dashboard}/demo_dash.py | 0 {Dashboards => dashboard}/demo_streamlit.py | 0 .../my_data => my_data}/computed_datasets.py | 2 +- {Dashboards/my_data => my_data}/datasets.py | 2 +- {Dashboards/my_data => my_data}/db_connect.py | 0 {Dashboards/my_data => my_data}/model.py | 2 +- .../exploratory_data_analysis.ipynb | 0 .../notebooks => notebooks}/plots.ipynb | 0 .../dash_hist4_pxbar.py | 0 .../gauge_charts.py | 2 +- .../hist3_pxbar.py | 0 .../hist4_pxbar.py | 0 .../xanthoria parietina.jpg | Bin 58 files changed, 9 insertions(+), 81 deletions(-) delete mode 100644 Dashboards/utils/colors.py delete mode 100644 Dashboards/utils/css_reader.py rename {Dashboards => dashboard}/Documentation_DB.md (100%) rename Dashboards/dashboard.py => dashboard/app.py (97%) rename {Dashboards => dashboard}/assets/img/amandinea_punctata.jpg (100%) rename {Dashboards => dashboard}/assets/img/anaptychia_ciliaris.jpg (100%) rename {Dashboards => dashboard}/assets/img/candelaria_concolor.jpg (100%) rename {Dashboards => dashboard}/assets/img/candelariella.jpg (100%) rename {Dashboards => dashboard}/assets/img/crustaces_lirelles.jpg (100%) rename {Dashboards => dashboard}/assets/img/crustaces_poudreux.jpg (100%) rename {Dashboards => dashboard}/assets/img/diploicia_canescens.jpg (100%) rename {Dashboards => dashboard}/assets/img/evernia_prunastri.jpg (100%) rename {Dashboards => dashboard}/assets/img/flavoparmelia_caperata.jpg (100%) rename {Dashboards => dashboard}/assets/img/hyperphyscia_adglutinata.jpg (100%) rename {Dashboards => dashboard}/assets/img/hypogymnia_physodes.jpg (100%) rename {Dashboards => dashboard}/assets/img/hypotrachyna_afrevoluta.jpg (100%) rename {Dashboards => dashboard}/assets/img/lecanora.jpg (100%) rename {Dashboards => dashboard}/assets/img/lichen_crustace.jpg (100%) rename {Dashboards => dashboard}/assets/img/lichen_foliace.jpg (100%) rename {Dashboards => dashboard}/assets/img/lichen_fruticuleux.jpg (100%) rename {Dashboards => dashboard}/assets/img/melanelixia_glabratula.jpg (100%) rename {Dashboards => dashboard}/assets/img/melanohalea_exasperata.jpg (100%) rename {Dashboards => dashboard}/assets/img/parmelia_saxatilis.jpg (100%) rename {Dashboards => dashboard}/assets/img/parmelia_sulcata.jpg (100%) rename {Dashboards => dashboard}/assets/img/parmelina_tiliacea.jpg (100%) rename {Dashboards => dashboard}/assets/img/parmotrema_perlatum.jpg (100%) rename {Dashboards => dashboard}/assets/img/pertusaria_pertusa.jpg (100%) rename {Dashboards => dashboard}/assets/img/phaeophyscia_orbicularis.jpg (100%) rename {Dashboards => dashboard}/assets/img/physcia_adscendens.jpg (100%) rename {Dashboards => dashboard}/assets/img/physcia_aipolia.jpg (100%) rename {Dashboards => dashboard}/assets/img/physcia_leptalea.jpg (100%) rename {Dashboards => dashboard}/assets/img/physconia_distorta.jpg (100%) rename {Dashboards => dashboard}/assets/img/physconia_grisea.jpg (100%) rename {Dashboards => dashboard}/assets/img/pleurosticta_acetabulum.jpg (100%) rename {Dashboards => dashboard}/assets/img/polycauliona_polycarpa.jpg (100%) rename {Dashboards => dashboard}/assets/img/pseudevernia_furfuracea.jpg (100%) rename {Dashboards => dashboard}/assets/img/punctelia_sp_.jpg (100%) rename {Dashboards => dashboard}/assets/img/ramalina_farinacea.jpg (100%) rename {Dashboards => dashboard}/assets/img/ramalina_fastigiata.jpg (100%) rename {Dashboards => dashboard}/assets/img/ramalina_fraxinea.jpg (100%) rename {Dashboards => dashboard}/assets/img/usnea.jpg (100%) rename {Dashboards => dashboard}/assets/img/xanthoria_parietina.jpg (100%) rename {Dashboards => dashboard}/assets/lichen_species_ecology.csv (100%) rename {Dashboards => dashboard}/charts.py (98%) rename {Dashboards => dashboard}/constants.py (100%) rename {Dashboards => dashboard}/demo_dash.py (100%) rename {Dashboards => dashboard}/demo_streamlit.py (100%) rename {Dashboards/my_data => my_data}/computed_datasets.py (99%) rename {Dashboards/my_data => my_data}/datasets.py (98%) rename {Dashboards/my_data => my_data}/db_connect.py (100%) rename {Dashboards/my_data => my_data}/model.py (98%) rename {Dashboards/notebooks => notebooks}/exploratory_data_analysis.ipynb (100%) rename {Dashboards/notebooks => notebooks}/plots.ipynb (100%) rename {Dashboards/visualisation => visualisation}/dash_hist4_pxbar.py (100%) rename {Dashboards/visualisation => visualisation}/gauge_charts.py (98%) rename {Dashboards/visualisation => visualisation}/hist3_pxbar.py (100%) rename {Dashboards/visualisation => visualisation}/hist4_pxbar.py (100%) rename {Dashboards/visualisation => visualisation}/xanthoria parietina.jpg (100%) diff --git a/Dashboards/utils/colors.py b/Dashboards/utils/colors.py deleted file mode 100644 index 1d5cfc3..0000000 --- a/Dashboards/utils/colors.py +++ /dev/null @@ -1,48 +0,0 @@ -def hex_to_rgb(hex_color): - """Convert hex color to RGB.""" - hex_color = hex_color.lstrip('#') - return tuple(int(hex_color[i:i+2], 16) for i in (0, 2, 4)) - -def rgb_to_hex(rgb_color): - """Convert RGB color to hex.""" - return '#{:02x}{:02x}{:02x}'.format(*rgb_color) - -def lighten_color(rgb_color, factor=0.5): - """Lighten the color by mixing it with white.""" - white = (255, 255, 255) - return tuple(int((1 - factor) * c + factor * w) for c, w in zip(rgb_color, white, strict=False)) - -def create_pastel_palette(base_palette, factor=0.5): - """Create a pastel version of the base color palette.""" - pastel_palette = [] - for hex_color in base_palette: - rgb_color = hex_to_rgb(hex_color) - pastel_rgb = lighten_color(rgb_color, factor) - pastel_hex = rgb_to_hex(pastel_rgb) - pastel_palette.append(pastel_hex) - return pastel_palette - - -if __name__ == "__main__": - - base_color_palette = [ - "#333D43", - "#37444C", - "#3A4C58", - "#3C5665", - "#3D6176", - "#3C6D8C", - "#387CA6", - "#4A86AB", - "#608FAD", - "#799AAF", - "#90A7B5", - "#A6B6BF", - "#BDC6CC", -] - - # Create a pastel version of the base color palette - pastel_color_palette = create_pastel_palette(base_color_palette, factor=0.7) - - # Print the pastel color palette - print("Pastel Color Palette:", pastel_color_palette) diff --git a/Dashboards/utils/css_reader.py b/Dashboards/utils/css_reader.py deleted file mode 100644 index a6de7d4..0000000 --- a/Dashboards/utils/css_reader.py +++ /dev/null @@ -1,24 +0,0 @@ -import os -import cssutils - -# Get the absolute path to the CSS file in the parent directory -current_dir = os.path.dirname(os.path.abspath(__file__)) -parent_dir = os.path.abspath(os.path.join(current_dir, os.pardir)) -css_file_path = os.path.join(parent_dir, 'assets', 'styles.css') - -# Load the CSS file -with open(css_file_path, "r") as file: - css_content = file.read() - -# Parse the CSS -css_parser = cssutils.parseString(css_content) - -def get_css_properties(selector): - properties = {} - for rule in css_parser: - if rule.type == rule.STYLE_RULE and rule.selectorText == selector: - for property in rule.style: - properties[property.name] = property.value - # if property.value: # Check if the property has a non-empty value - - return properties diff --git a/Dashboards/Documentation_DB.md b/dashboard/Documentation_DB.md similarity index 100% rename from Dashboards/Documentation_DB.md rename to dashboard/Documentation_DB.md diff --git a/Dashboards/dashboard.py b/dashboard/app.py similarity index 97% rename from Dashboards/dashboard.py rename to dashboard/app.py index df6b9a5..c62156b 100644 --- a/Dashboards/dashboard.py +++ b/dashboard/app.py @@ -8,10 +8,10 @@ from dash_iconify import DashIconify from datetime import datetime -from Dashboards.my_data.datasets import get_useful_data -from Dashboards.my_data.computed_datasets import merge_tables, calc_degrees_pollution, calc_vdl, count_lichen, count_lichen_per_species, count_species_per_observation, count_lichen_per_lichen_id, group_lichen_by_observation_and_thallus -from Dashboards.charts import blank_figure, create_map, create_hist1_nb_species, create_hist2_vdl, create_hist3, create_pie_thallus, create_hist4, create_gauge_chart -from Dashboards.constants import MAP_SETTINGS, BASE_COLOR_PALETTE, BODY_FONT_FAMILY, POSITIVE_GAUGE_COLOR_PALETTE, NEGATIVE_GAUGE_COLOR_PALETTE, TRANSLATIONS_EN_FR, GRID_STYLE, CARD_STYLE, MAP_STYLE, FLEX_COLUMNS_CONTAINER_STYLE +from my_data.datasets import get_useful_data +from my_data.computed_datasets import merge_tables, calc_degrees_pollution, calc_vdl, count_lichen, count_lichen_per_species, count_species_per_observation, count_lichen_per_lichen_id, group_lichen_by_observation_and_thallus +from dashboard.charts import blank_figure, create_map, create_hist1_nb_species, create_hist2_vdl, create_hist3, create_pie_thallus, create_hist4, create_gauge_chart +from dashboard.constants import MAP_SETTINGS, BASE_COLOR_PALETTE, BODY_FONT_FAMILY, POSITIVE_GAUGE_COLOR_PALETTE, NEGATIVE_GAUGE_COLOR_PALETTE, TRANSLATIONS_EN_FR, GRID_STYLE, CARD_STYLE, MAP_STYLE, FLEX_COLUMNS_CONTAINER_STYLE _dash_renderer._set_react_version("18.2.0") diff --git a/Dashboards/assets/img/amandinea_punctata.jpg b/dashboard/assets/img/amandinea_punctata.jpg similarity index 100% rename from Dashboards/assets/img/amandinea_punctata.jpg rename to dashboard/assets/img/amandinea_punctata.jpg diff --git a/Dashboards/assets/img/anaptychia_ciliaris.jpg b/dashboard/assets/img/anaptychia_ciliaris.jpg similarity index 100% rename from Dashboards/assets/img/anaptychia_ciliaris.jpg rename to dashboard/assets/img/anaptychia_ciliaris.jpg diff --git a/Dashboards/assets/img/candelaria_concolor.jpg b/dashboard/assets/img/candelaria_concolor.jpg similarity index 100% rename from Dashboards/assets/img/candelaria_concolor.jpg rename to dashboard/assets/img/candelaria_concolor.jpg diff --git a/Dashboards/assets/img/candelariella.jpg b/dashboard/assets/img/candelariella.jpg similarity index 100% rename from Dashboards/assets/img/candelariella.jpg rename to dashboard/assets/img/candelariella.jpg diff --git a/Dashboards/assets/img/crustaces_lirelles.jpg b/dashboard/assets/img/crustaces_lirelles.jpg similarity index 100% rename from Dashboards/assets/img/crustaces_lirelles.jpg rename to dashboard/assets/img/crustaces_lirelles.jpg diff --git a/Dashboards/assets/img/crustaces_poudreux.jpg b/dashboard/assets/img/crustaces_poudreux.jpg similarity index 100% rename from Dashboards/assets/img/crustaces_poudreux.jpg rename to dashboard/assets/img/crustaces_poudreux.jpg diff --git a/Dashboards/assets/img/diploicia_canescens.jpg b/dashboard/assets/img/diploicia_canescens.jpg similarity index 100% rename from Dashboards/assets/img/diploicia_canescens.jpg rename to dashboard/assets/img/diploicia_canescens.jpg diff --git a/Dashboards/assets/img/evernia_prunastri.jpg b/dashboard/assets/img/evernia_prunastri.jpg similarity index 100% rename from Dashboards/assets/img/evernia_prunastri.jpg rename to dashboard/assets/img/evernia_prunastri.jpg diff --git a/Dashboards/assets/img/flavoparmelia_caperata.jpg b/dashboard/assets/img/flavoparmelia_caperata.jpg similarity index 100% rename from Dashboards/assets/img/flavoparmelia_caperata.jpg rename to dashboard/assets/img/flavoparmelia_caperata.jpg diff --git a/Dashboards/assets/img/hyperphyscia_adglutinata.jpg b/dashboard/assets/img/hyperphyscia_adglutinata.jpg similarity index 100% rename from Dashboards/assets/img/hyperphyscia_adglutinata.jpg rename to dashboard/assets/img/hyperphyscia_adglutinata.jpg diff --git a/Dashboards/assets/img/hypogymnia_physodes.jpg b/dashboard/assets/img/hypogymnia_physodes.jpg similarity index 100% rename from Dashboards/assets/img/hypogymnia_physodes.jpg rename to dashboard/assets/img/hypogymnia_physodes.jpg diff --git a/Dashboards/assets/img/hypotrachyna_afrevoluta.jpg b/dashboard/assets/img/hypotrachyna_afrevoluta.jpg similarity index 100% rename from Dashboards/assets/img/hypotrachyna_afrevoluta.jpg rename to dashboard/assets/img/hypotrachyna_afrevoluta.jpg diff --git a/Dashboards/assets/img/lecanora.jpg b/dashboard/assets/img/lecanora.jpg similarity index 100% rename from Dashboards/assets/img/lecanora.jpg rename to dashboard/assets/img/lecanora.jpg diff --git a/Dashboards/assets/img/lichen_crustace.jpg b/dashboard/assets/img/lichen_crustace.jpg similarity index 100% rename from Dashboards/assets/img/lichen_crustace.jpg rename to dashboard/assets/img/lichen_crustace.jpg diff --git a/Dashboards/assets/img/lichen_foliace.jpg b/dashboard/assets/img/lichen_foliace.jpg similarity index 100% rename from Dashboards/assets/img/lichen_foliace.jpg rename to dashboard/assets/img/lichen_foliace.jpg diff --git a/Dashboards/assets/img/lichen_fruticuleux.jpg b/dashboard/assets/img/lichen_fruticuleux.jpg similarity index 100% rename from Dashboards/assets/img/lichen_fruticuleux.jpg rename to dashboard/assets/img/lichen_fruticuleux.jpg diff --git a/Dashboards/assets/img/melanelixia_glabratula.jpg b/dashboard/assets/img/melanelixia_glabratula.jpg similarity index 100% rename from Dashboards/assets/img/melanelixia_glabratula.jpg rename to dashboard/assets/img/melanelixia_glabratula.jpg diff --git a/Dashboards/assets/img/melanohalea_exasperata.jpg b/dashboard/assets/img/melanohalea_exasperata.jpg similarity index 100% rename from Dashboards/assets/img/melanohalea_exasperata.jpg rename to dashboard/assets/img/melanohalea_exasperata.jpg diff --git a/Dashboards/assets/img/parmelia_saxatilis.jpg b/dashboard/assets/img/parmelia_saxatilis.jpg similarity index 100% rename from Dashboards/assets/img/parmelia_saxatilis.jpg rename to dashboard/assets/img/parmelia_saxatilis.jpg diff --git a/Dashboards/assets/img/parmelia_sulcata.jpg b/dashboard/assets/img/parmelia_sulcata.jpg similarity index 100% rename from Dashboards/assets/img/parmelia_sulcata.jpg rename to dashboard/assets/img/parmelia_sulcata.jpg diff --git a/Dashboards/assets/img/parmelina_tiliacea.jpg b/dashboard/assets/img/parmelina_tiliacea.jpg similarity index 100% rename from Dashboards/assets/img/parmelina_tiliacea.jpg rename to dashboard/assets/img/parmelina_tiliacea.jpg diff --git a/Dashboards/assets/img/parmotrema_perlatum.jpg b/dashboard/assets/img/parmotrema_perlatum.jpg similarity index 100% rename from Dashboards/assets/img/parmotrema_perlatum.jpg rename to dashboard/assets/img/parmotrema_perlatum.jpg diff --git a/Dashboards/assets/img/pertusaria_pertusa.jpg b/dashboard/assets/img/pertusaria_pertusa.jpg similarity index 100% rename from Dashboards/assets/img/pertusaria_pertusa.jpg rename to dashboard/assets/img/pertusaria_pertusa.jpg diff --git a/Dashboards/assets/img/phaeophyscia_orbicularis.jpg b/dashboard/assets/img/phaeophyscia_orbicularis.jpg similarity index 100% rename from Dashboards/assets/img/phaeophyscia_orbicularis.jpg rename to dashboard/assets/img/phaeophyscia_orbicularis.jpg diff --git a/Dashboards/assets/img/physcia_adscendens.jpg b/dashboard/assets/img/physcia_adscendens.jpg similarity index 100% rename from Dashboards/assets/img/physcia_adscendens.jpg rename to dashboard/assets/img/physcia_adscendens.jpg diff --git a/Dashboards/assets/img/physcia_aipolia.jpg b/dashboard/assets/img/physcia_aipolia.jpg similarity index 100% rename from Dashboards/assets/img/physcia_aipolia.jpg rename to dashboard/assets/img/physcia_aipolia.jpg diff --git a/Dashboards/assets/img/physcia_leptalea.jpg b/dashboard/assets/img/physcia_leptalea.jpg similarity index 100% rename from Dashboards/assets/img/physcia_leptalea.jpg rename to dashboard/assets/img/physcia_leptalea.jpg diff --git a/Dashboards/assets/img/physconia_distorta.jpg b/dashboard/assets/img/physconia_distorta.jpg similarity index 100% rename from Dashboards/assets/img/physconia_distorta.jpg rename to dashboard/assets/img/physconia_distorta.jpg diff --git a/Dashboards/assets/img/physconia_grisea.jpg b/dashboard/assets/img/physconia_grisea.jpg similarity index 100% rename from Dashboards/assets/img/physconia_grisea.jpg rename to dashboard/assets/img/physconia_grisea.jpg diff --git a/Dashboards/assets/img/pleurosticta_acetabulum.jpg b/dashboard/assets/img/pleurosticta_acetabulum.jpg similarity index 100% rename from Dashboards/assets/img/pleurosticta_acetabulum.jpg rename to dashboard/assets/img/pleurosticta_acetabulum.jpg diff --git a/Dashboards/assets/img/polycauliona_polycarpa.jpg b/dashboard/assets/img/polycauliona_polycarpa.jpg similarity index 100% rename from Dashboards/assets/img/polycauliona_polycarpa.jpg rename to dashboard/assets/img/polycauliona_polycarpa.jpg diff --git a/Dashboards/assets/img/pseudevernia_furfuracea.jpg b/dashboard/assets/img/pseudevernia_furfuracea.jpg similarity index 100% rename from Dashboards/assets/img/pseudevernia_furfuracea.jpg rename to dashboard/assets/img/pseudevernia_furfuracea.jpg diff --git a/Dashboards/assets/img/punctelia_sp_.jpg b/dashboard/assets/img/punctelia_sp_.jpg similarity index 100% rename from Dashboards/assets/img/punctelia_sp_.jpg rename to dashboard/assets/img/punctelia_sp_.jpg diff --git a/Dashboards/assets/img/ramalina_farinacea.jpg b/dashboard/assets/img/ramalina_farinacea.jpg similarity index 100% rename from Dashboards/assets/img/ramalina_farinacea.jpg rename to dashboard/assets/img/ramalina_farinacea.jpg diff --git a/Dashboards/assets/img/ramalina_fastigiata.jpg b/dashboard/assets/img/ramalina_fastigiata.jpg similarity index 100% rename from Dashboards/assets/img/ramalina_fastigiata.jpg rename to dashboard/assets/img/ramalina_fastigiata.jpg diff --git a/Dashboards/assets/img/ramalina_fraxinea.jpg b/dashboard/assets/img/ramalina_fraxinea.jpg similarity index 100% rename from Dashboards/assets/img/ramalina_fraxinea.jpg rename to dashboard/assets/img/ramalina_fraxinea.jpg diff --git a/Dashboards/assets/img/usnea.jpg b/dashboard/assets/img/usnea.jpg similarity index 100% rename from Dashboards/assets/img/usnea.jpg rename to dashboard/assets/img/usnea.jpg diff --git a/Dashboards/assets/img/xanthoria_parietina.jpg b/dashboard/assets/img/xanthoria_parietina.jpg similarity index 100% rename from Dashboards/assets/img/xanthoria_parietina.jpg rename to dashboard/assets/img/xanthoria_parietina.jpg diff --git a/Dashboards/assets/lichen_species_ecology.csv b/dashboard/assets/lichen_species_ecology.csv similarity index 100% rename from Dashboards/assets/lichen_species_ecology.csv rename to dashboard/assets/lichen_species_ecology.csv diff --git a/Dashboards/charts.py b/dashboard/charts.py similarity index 98% rename from Dashboards/charts.py rename to dashboard/charts.py index 7a15018..ceb952e 100644 --- a/Dashboards/charts.py +++ b/dashboard/charts.py @@ -1,6 +1,6 @@ import plotly.express as px import plotly.graph_objects as go -from Dashboards.constants import BASE_COLOR_PALETTE, PASTEL_COLOR_PALETTE, PLOTLY_LAYOUT, MAP_SETTINGS +from dashboard.constants import BASE_COLOR_PALETTE, PASTEL_COLOR_PALETTE, PLOTLY_LAYOUT, MAP_SETTINGS """ diff --git a/Dashboards/constants.py b/dashboard/constants.py similarity index 100% rename from Dashboards/constants.py rename to dashboard/constants.py diff --git a/Dashboards/demo_dash.py b/dashboard/demo_dash.py similarity index 100% rename from Dashboards/demo_dash.py rename to dashboard/demo_dash.py diff --git a/Dashboards/demo_streamlit.py b/dashboard/demo_streamlit.py similarity index 100% rename from Dashboards/demo_streamlit.py rename to dashboard/demo_streamlit.py diff --git a/Dashboards/my_data/computed_datasets.py b/my_data/computed_datasets.py similarity index 99% rename from Dashboards/my_data/computed_datasets.py rename to my_data/computed_datasets.py index a554375..d79195d 100644 --- a/Dashboards/my_data/computed_datasets.py +++ b/my_data/computed_datasets.py @@ -1,7 +1,7 @@ import pandas as pd import numpy as np -from Dashboards.constants import SQUARE_COLUMNS, ORIENTATIONS +from dashboard.constants import SQUARE_COLUMNS, ORIENTATIONS # Merge table_df with lichen_df, lichen_species_df and observation_df def merge_tables(table_df, lichen_df, observation_df): diff --git a/Dashboards/my_data/datasets.py b/my_data/datasets.py similarity index 98% rename from Dashboards/my_data/datasets.py rename to my_data/datasets.py index a462933..3997594 100644 --- a/Dashboards/my_data/datasets.py +++ b/my_data/datasets.py @@ -121,7 +121,7 @@ def get_lichen_ecology(): def get_lichen_ecology_csv(): parent_dir = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) - lichen_ecology_csv_path = os.path.join(parent_dir, 'assets', 'lichen_species_ecology.csv') + lichen_ecology_csv_path = os.path.join(parent_dir, 'dashboard', 'assets', 'lichen_species_ecology.csv') lichen_ecology_df = pd.read_csv(lichen_ecology_csv_path, delimiter=';') return lichen_ecology_df diff --git a/Dashboards/my_data/db_connect.py b/my_data/db_connect.py similarity index 100% rename from Dashboards/my_data/db_connect.py rename to my_data/db_connect.py diff --git a/Dashboards/my_data/model.py b/my_data/model.py similarity index 98% rename from Dashboards/my_data/model.py rename to my_data/model.py index 5bba3d0..2fb4666 100644 --- a/Dashboards/my_data/model.py +++ b/my_data/model.py @@ -1,6 +1,6 @@ from sqlalchemy import Column, BigInteger, Integer, String, ForeignKey, ARRAY, Boolean, Date, Text, Float from sqlalchemy.orm import declarative_base, relationship -from Dashboards.my_data.db_connect import engine +from my_data.db_connect import engine Base = declarative_base() diff --git a/Dashboards/notebooks/exploratory_data_analysis.ipynb b/notebooks/exploratory_data_analysis.ipynb similarity index 100% rename from Dashboards/notebooks/exploratory_data_analysis.ipynb rename to notebooks/exploratory_data_analysis.ipynb diff --git a/Dashboards/notebooks/plots.ipynb b/notebooks/plots.ipynb similarity index 100% rename from Dashboards/notebooks/plots.ipynb rename to notebooks/plots.ipynb diff --git a/Dashboards/visualisation/dash_hist4_pxbar.py b/visualisation/dash_hist4_pxbar.py similarity index 100% rename from Dashboards/visualisation/dash_hist4_pxbar.py rename to visualisation/dash_hist4_pxbar.py diff --git a/Dashboards/visualisation/gauge_charts.py b/visualisation/gauge_charts.py similarity index 98% rename from Dashboards/visualisation/gauge_charts.py rename to visualisation/gauge_charts.py index fceb285..f2cfd90 100644 --- a/Dashboards/visualisation/gauge_charts.py +++ b/visualisation/gauge_charts.py @@ -3,7 +3,7 @@ from dash import Dash, html, dcc, Output, Input from my_data.datasets import get_lichen_data, get_lichen_species_data, get_observation_data, get_table_data, get_tree_species, get_lichen_ecology from my_data.computed_datasets import df_frequency -from Dashboards.charts import create_gauge_chart +from dashboard.charts import create_gauge_chart chemin_dossier_parent = Path(__file__).parent.parent sys.path.append(str(chemin_dossier_parent)) diff --git a/Dashboards/visualisation/hist3_pxbar.py b/visualisation/hist3_pxbar.py similarity index 100% rename from Dashboards/visualisation/hist3_pxbar.py rename to visualisation/hist3_pxbar.py diff --git a/Dashboards/visualisation/hist4_pxbar.py b/visualisation/hist4_pxbar.py similarity index 100% rename from Dashboards/visualisation/hist4_pxbar.py rename to visualisation/hist4_pxbar.py diff --git a/Dashboards/visualisation/xanthoria parietina.jpg b/visualisation/xanthoria parietina.jpg similarity index 100% rename from Dashboards/visualisation/xanthoria parietina.jpg rename to visualisation/xanthoria parietina.jpg