diff --git a/geest/core/algorithms/__init__.py b/geest/core/algorithms/__init__.py index 9b347131..1c241905 100644 --- a/geest/core/algorithms/__init__.py +++ b/geest/core/algorithms/__init__.py @@ -1,3 +1,3 @@ from .area_iterator import AreaIterator from .population_processor import PopulationRasterProcessingTask -from .wee_score_processor import WEEScoreProcessingTask +from .wee_score_processor import WEEByPopulationScoreProcessingTask diff --git a/geest/core/algorithms/wee_score_processor.py b/geest/core/algorithms/wee_score_processor.py index d82819c2..f21ae775 100644 --- a/geest/core/algorithms/wee_score_processor.py +++ b/geest/core/algorithms/wee_score_processor.py @@ -16,12 +16,12 @@ from geest.core.algorithms import AreaIterator -class WEEScoreProcessingTask(QgsTask): +class WEEByPopulationScoreProcessingTask(QgsTask): """ - A QgsTask subclass for calculating WEE SCORE using raster algebra. + A QgsTask subclass for calculating WEE x Population SCORE using raster algebra. It iterates over study areas, calculates the WEE SCORE using aligned input rasters - (GEEST and POP), combines the resulting rasters into a VRT, and applies a QML style. + (WEE and POP), combines the resulting rasters into a VRT, and applies a QML style. Args: study_area_gpkg_path (str): Path to the GeoPackage containing study area masks. @@ -70,7 +70,7 @@ def run(self) -> bool: Executes the WEE SCORE calculation task. """ try: - self.calculate_wee_score() + self.calculate_score() self.generate_vrt() return True except Exception as e: @@ -121,9 +121,9 @@ def validate_rasters( log_message("Validation successful: rasters are aligned.") - def calculate_wee_score(self) -> None: + def calculate_score(self) -> None: """ - Calculates WEE SCORE using raster algebra and saves the result for each area. + Calculates WEE by POP SCORE using raster algebra and saves the result for each area. """ area_iterator = AreaIterator(self.study_area_gpkg_path) for index, (_, _, _, _) in enumerate(area_iterator): @@ -136,15 +136,17 @@ def calculate_wee_score(self) -> None: ) wee_layer = QgsRasterLayer(wee_path, "WEE") pop_layer = QgsRasterLayer(population_path, "POP") - self.validate_rasters(wee_layer, pop_layer) + self.validate_rasters(wee_layer, pop_layer, dimension_check=False) - output_path = os.path.join(self.output_dir, f"wee_score_{index}.tif") + output_path = os.path.join( + self.output_dir, f"wee_by_population_score_{index}.tif" + ) if not self.force_clear and os.path.exists(output_path): log_message(f"Reusing existing raster: {output_path}") self.output_rasters.append(output_path) continue - log_message(f"Calculating WEE SCORE for area {index}") + log_message(f"Calculating WEE by POP SCORE for area {index}") params = { "INPUT_A": wee_layer, @@ -168,11 +170,11 @@ def calculate_wee_score(self) -> None: def generate_vrt(self) -> None: """ - Combines all WEE SCORE rasters into a single VRT and applies a QML style. + Combines all WEE SCORE rasters into a single VRT and ap plies a QML style. """ - vrt_path = os.path.join(self.output_dir, "wee_score.vrt") - qml_path = os.path.join(self.output_dir, "wee_score.qml") - source_qml = resources_path("resources", "qml", "wee_score_style.qml") + vrt_path = os.path.join(self.output_dir, "wee_by_population_score.vrt") + qml_path = os.path.join(self.output_dir, "wee_by_population_score.qml") + source_qml = resources_path("resources", "qml", "wee_by_population_score.qml") params = { "INPUT": self.output_rasters, diff --git a/geest/core/workflows/analysis_aggregation_workflow.py b/geest/core/workflows/analysis_aggregation_workflow.py index c4698e43..febffaa3 100644 --- a/geest/core/workflows/analysis_aggregation_workflow.py +++ b/geest/core/workflows/analysis_aggregation_workflow.py @@ -2,7 +2,10 @@ from qgis.core import QgsFeedback, QgsProcessingContext from qgis.analysis import QgsRasterCalculator, QgsRasterCalculatorEntry from .aggregation_workflow_base import AggregationWorkflowBase -from geest.core.algorithms import PopulationRasterProcessingTask, WEEScoreProcessingTask +from geest.core.algorithms import ( + PopulationRasterProcessingTask, + WEEByPopulationScoreProcessingTask, +) from geest.utilities import resources_path from geest.core import JsonTreeItem @@ -55,9 +58,14 @@ def __init__( feedback=self.feedback, ) population_processor.run() - wee_processor = WEEScoreProcessingTask( + wee_processor = WEEByPopulationScoreProcessingTask( study_area_gpkg_path=self.gpkg_path, working_directory=self.working_directory, force_clear=False, ) wee_processor.run() + # Shamelessly hard coded for now, needs to move to the wee processor class + output = os.path.join( + self.working_directory, "wee_score", "wee_by_population_score.vrt" + ) + item.setAttribute("wee_by_population", output) diff --git a/geest/gui/panels/tree_panel.py b/geest/gui/panels/tree_panel.py index 2f5fd022..4c48d712 100644 --- a/geest/gui/panels/tree_panel.py +++ b/geest/gui/panels/tree_panel.py @@ -476,6 +476,13 @@ def update_action_text(): menu.addAction(clear_results_action) menu.addAction(run_item_action) menu.addAction(add_to_map_action) + add_wee_by_population = QAction("Add WEE by Pop to Map") + add_wee_by_population.triggered.connect( + lambda: self.add_to_map( + item, key="wee_by_population", layer_name="WEE by Population" + ) + ) + menu.addAction(add_wee_by_population) add_study_area_layers_action = QAction("Add Study Area to Map", self) add_study_area_layers_action.triggered.connect(self.add_study_area_to_map) menu.addAction(add_study_area_layers_action) @@ -870,13 +877,14 @@ def add_study_area_to_map(self): f"Added layer: {layer.name()} to group: {geest_group.name()}" ) - def add_to_map(self, item): + def add_to_map(self, item, key="result_file", layer_name=None): """Add the item to the map.""" - layer_uri = item.attribute(f"result_file") - + layer_uri = item.attribute(f"{key}") + log_message(f"Adding {layer_uri} for key {key} to map") if layer_uri: - layer_name = item.data(0) + if not layer_name: + layer_name = item.data(0) layer = QgsRasterLayer(layer_uri, layer_name) if not layer.isValid(): diff --git a/geest/resources/qml/15Classes.qml b/geest/resources/qml/wee_by_population_score.qml similarity index 100% rename from geest/resources/qml/15Classes.qml rename to geest/resources/qml/wee_by_population_score.qml diff --git a/test/test_data/points/fake_childcare.gpkg b/test/test_data/points/fake_childcare.gpkg new file mode 100644 index 00000000..d9486608 Binary files /dev/null and b/test/test_data/points/fake_childcare.gpkg differ diff --git a/test/test_data/points/fake_primary_schools.gpkg b/test/test_data/points/fake_primary_schools.gpkg new file mode 100644 index 00000000..ed65014c Binary files /dev/null and b/test/test_data/points/fake_primary_schools.gpkg differ diff --git a/test/test_data/wee_score/accessibility/Accessibility_score_combined.qml b/test/test_data/wee_score/accessibility/Accessibility_score_combined.qml new file mode 100644 index 00000000..f632630a --- /dev/null +++ b/test/test_data/wee_score/accessibility/Accessibility_score_combined.qml @@ -0,0 +1,177 @@ + + + + 1 + 1 + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + MinMax + WholeRaster + Estimated + 0.02 + 0.98 + 2 + + + + + + + + + + + + + + + + + + + + + + + + resamplingFilter + + 0 + diff --git a/test/test_data/wee_score/accessibility/Accessibility_score_combined.vrt b/test/test_data/wee_score/accessibility/Accessibility_score_combined.vrt new file mode 100644 index 00000000..ee2b7ac9 --- /dev/null +++ b/test/test_data/wee_score/accessibility/Accessibility_score_combined.vrt @@ -0,0 +1,23 @@ + + PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] + 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5530000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + + 0 + 4.5 + 2.0833333333333 + 1.497683396301 + 100 + + 255 + Gray + + accessibility_masked_0.tif + 1 + + + + 255 + + + diff --git a/test/test_data/wee_score/accessibility/accessibility_aggregated_0.tif b/test/test_data/wee_score/accessibility/accessibility_aggregated_0.tif new file mode 100644 index 00000000..4a50828d Binary files /dev/null and b/test/test_data/wee_score/accessibility/accessibility_aggregated_0.tif differ diff --git a/test/test_data/wee_score/accessibility/accessibility_masked_0.tif b/test/test_data/wee_score/accessibility/accessibility_masked_0.tif new file mode 100644 index 00000000..c0122449 Binary files /dev/null and b/test/test_data/wee_score/accessibility/accessibility_masked_0.tif differ diff --git a/test/test_data/wee_score/accessibility/accessibility_masked_0.tif.aux.xml b/test/test_data/wee_score/accessibility/accessibility_masked_0.tif.aux.xml new file mode 100644 index 00000000..3f24ae5e --- /dev/null +++ b/test/test_data/wee_score/accessibility/accessibility_masked_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 4.5 + 2.0833333333333 + 0 + 1.497683396301 + 100 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/WTP_Kindergartens_output_combined.qml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/WTP_Kindergartens_output_combined.qml new file mode 100644 index 00000000..f632630a --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/WTP_Kindergartens_output_combined.qml @@ -0,0 +1,177 @@ + + + + 1 + 1 + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + MinMax + WholeRaster + Estimated + 0.02 + 0.98 + 2 + + + + + + + + + + + + + + + + + + + + + + + + resamplingFilter + + 0 + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/WTP_Kindergartens_output_combined.vrt b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/WTP_Kindergartens_output_combined.vrt new file mode 100644 index 00000000..5e43444b --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/WTP_Kindergartens_output_combined.vrt @@ -0,0 +1,23 @@ + + PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] + 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5530000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + + 0 + 5 + 2.0277777777778 + 1.9788620623299 + 100 + + 255 + Gray + + kindergartens_location_masked_0.tif + 1 + + + + 255 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.cpg b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.cpg new file mode 100644 index 00000000..3ad133c0 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.cpg @@ -0,0 +1 @@ +UTF-8 \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.dbf b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.dbf new file mode 100644 index 00000000..6ed3552d Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.dbf differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.prj b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.prj new file mode 100644 index 00000000..9c7aa3ca --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.prj @@ -0,0 +1 @@ +PROJCS["WGS_1984_UTM_Zone_20N",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-63.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]] \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.shp b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.shp new file mode 100644 index 00000000..517810e2 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.shp differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.shx b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.shx new file mode 100644 index 00000000..4b4b568d Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/final_isochrones_0.shx differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_0.tif b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_0.tif new file mode 100644 index 00000000..d404d872 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_0.tif differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_0.tif.aux.xml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_0.tif.aux.xml new file mode 100644 index 00000000..c8149e16 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 0 + 5 + 1.4897959183673 + 1.9179330815462 + 100 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.cpg b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.cpg new file mode 100644 index 00000000..3ad133c0 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.cpg @@ -0,0 +1 @@ +UTF-8 \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.dbf b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.dbf new file mode 100644 index 00000000..9533f5fb Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.dbf differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.prj b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.prj new file mode 100644 index 00000000..9c7aa3ca --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.prj @@ -0,0 +1 @@ +PROJCS["WGS_1984_UTM_Zone_20N",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-63.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]] \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.shp b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.shp new file mode 100644 index 00000000..45e8c5c1 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.shp differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.shx b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.shx new file mode 100644 index 00000000..bbf9a90c Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_area_features_0.shx differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_masked_0.tif b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_masked_0.tif new file mode 100644 index 00000000..d9cfb389 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_masked_0.tif differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_masked_0.tif.aux.xml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_masked_0.tif.aux.xml new file mode 100644 index 00000000..b2f7390a --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_masked_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 5 + 2.0277777777778 + 0 + 1.9788620623299 + 100 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.cpg b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.cpg new file mode 100644 index 00000000..3ad133c0 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.cpg @@ -0,0 +1 @@ +UTF-8 \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.dbf b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.dbf new file mode 100644 index 00000000..fc8261e8 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.dbf differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.prj b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.prj new file mode 100644 index 00000000..9c7aa3ca --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.prj @@ -0,0 +1 @@ +PROJCS["WGS_1984_UTM_Zone_20N",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-63.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]] \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.shp b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.shp new file mode 100644 index 00000000..7ccacf60 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.shp differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.shx b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.shx new file mode 100644 index 00000000..8d3052ca Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/kindergartens_location_merged_isochrones_0.shx differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/WTP_Primary_Schools_output_combined.qml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/WTP_Primary_Schools_output_combined.qml new file mode 100644 index 00000000..f632630a --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/WTP_Primary_Schools_output_combined.qml @@ -0,0 +1,177 @@ + + + + 1 + 1 + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + MinMax + WholeRaster + Estimated + 0.02 + 0.98 + 2 + + + + + + + + + + + + + + + + + + + + + + + + resamplingFilter + + 0 + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/WTP_Primary_Schools_output_combined.vrt b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/WTP_Primary_Schools_output_combined.vrt new file mode 100644 index 00000000..ed413385 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/WTP_Primary_Schools_output_combined.vrt @@ -0,0 +1,23 @@ + + PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] + 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5530000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + + 0 + 5 + 2.1388888888889 + 1.8878673708385 + 100 + + 255 + Gray + + primary_school_location_masked_0.tif + 1 + + + + 255 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.cpg b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.cpg new file mode 100644 index 00000000..3ad133c0 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.cpg @@ -0,0 +1 @@ +UTF-8 \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.dbf b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.dbf new file mode 100644 index 00000000..d97b60a8 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.dbf differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.prj b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.prj new file mode 100644 index 00000000..9c7aa3ca --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.prj @@ -0,0 +1 @@ +PROJCS["WGS_1984_UTM_Zone_20N",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-63.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]] \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.shp b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.shp new file mode 100644 index 00000000..3155bffe Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.shp differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.shx b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.shx new file mode 100644 index 00000000..f8854c1e Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/final_isochrones_0.shx differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_0.tif b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_0.tif new file mode 100644 index 00000000..e1dc603a Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_0.tif differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_0.tif.aux.xml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_0.tif.aux.xml new file mode 100644 index 00000000..889c6fb4 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 0 + 5 + 1.6122448979592 + 1.8496147037342 + 100 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.cpg b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.cpg new file mode 100644 index 00000000..3ad133c0 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.cpg @@ -0,0 +1 @@ +UTF-8 \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.dbf b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.dbf new file mode 100644 index 00000000..9533f5fb Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.dbf differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.prj b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.prj new file mode 100644 index 00000000..9c7aa3ca --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.prj @@ -0,0 +1 @@ +PROJCS["WGS_1984_UTM_Zone_20N",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-63.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]] \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.shp b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.shp new file mode 100644 index 00000000..400341d2 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.shp differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.shx b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.shx new file mode 100644 index 00000000..c52735d7 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_area_features_0.shx differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_masked_0.tif b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_masked_0.tif new file mode 100644 index 00000000..449c19f3 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_masked_0.tif differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_masked_0.tif.aux.xml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_masked_0.tif.aux.xml new file mode 100644 index 00000000..f9018a96 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_masked_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 5 + 2.1388888888889 + 0 + 1.8878673708385 + 100 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.cpg b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.cpg new file mode 100644 index 00000000..3ad133c0 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.cpg @@ -0,0 +1 @@ +UTF-8 \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.dbf b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.dbf new file mode 100644 index 00000000..d3e964ab Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.dbf differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.prj b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.prj new file mode 100644 index 00000000..9c7aa3ca --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.prj @@ -0,0 +1 @@ +PROJCS["WGS_1984_UTM_Zone_20N",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",-63.0],PARAMETER["Scale_Factor",0.9996],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]] \ No newline at end of file diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.shp b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.shp new file mode 100644 index 00000000..d0526a8d Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.shp differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.shx b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.shx new file mode 100644 index 00000000..9e3d5c77 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/primary_school_location_merged_isochrones_0.shx differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_aggregated_0.tif b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_aggregated_0.tif new file mode 100644 index 00000000..4a50828d Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_aggregated_0.tif differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_combined.qml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_combined.qml new file mode 100644 index 00000000..f632630a --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_combined.qml @@ -0,0 +1,177 @@ + + + + 1 + 1 + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + MinMax + WholeRaster + Estimated + 0.02 + 0.98 + 2 + + + + + + + + + + + + + + + + + + + + + + + + resamplingFilter + + 0 + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_combined.vrt b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_combined.vrt new file mode 100644 index 00000000..53ddc8b9 --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_combined.vrt @@ -0,0 +1,23 @@ + + PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] + 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5530000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + + 0 + 4.5 + 2.0833333333333 + 1.497683396301 + 100 + + 255 + Gray + + women_s_travel_patterns_masked_0.tif + 1 + + + + 255 + + + diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_masked_0.tif b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_masked_0.tif new file mode 100644 index 00000000..c0122449 Binary files /dev/null and b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_masked_0.tif differ diff --git a/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_masked_0.tif.aux.xml b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_masked_0.tif.aux.xml new file mode 100644 index 00000000..3f24ae5e --- /dev/null +++ b/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_masked_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 4.5 + 2.0833333333333 + 0 + 1.497683396301 + 100 + + + diff --git a/test/test_data/wee_score/admin0.gpkg b/test/test_data/wee_score/admin0.gpkg index acad32be..d0ee66aa 100644 Binary files a/test/test_data/wee_score/admin0.gpkg and b/test/test_data/wee_score/admin0.gpkg differ diff --git a/test/test_data/wee_score/admin0.gpkg-shm b/test/test_data/wee_score/admin0.gpkg-shm deleted file mode 100644 index fe9ac284..00000000 Binary files a/test/test_data/wee_score/admin0.gpkg-shm and /dev/null differ diff --git a/test/test_data/wee_score/admin0.gpkg-wal b/test/test_data/wee_score/admin0.gpkg-wal deleted file mode 100644 index e69de29b..00000000 diff --git a/test/test_data/wee_score/error.txt b/test/test_data/wee_score/error.txt new file mode 100644 index 00000000..117e4bc8 --- /dev/null +++ b/test/test_data/wee_score/error.txt @@ -0,0 +1,16 @@ +Failed to process Do Not Use: Unable to execute algorithm +Could not load source layer for INPUT: invalid value +Traceback (most recent call last): + File "/home/timlinux/.local/share/QGIS/QGIS3/profiles/GEEST2/python/plugins/geest/core/workflows/workflow_base.py", line 240, in execute + area_raster = self._subset_raster_layer( + ^^^^^^^^^^^^^^^^^^^^^^^^^^ + File "/home/timlinux/.local/share/QGIS/QGIS3/profiles/GEEST2/python/plugins/geest/core/workflows/workflow_base.py", line 394, in _subset_raster_layer + aoi = processing.run( + ^^^^^^^^^^^^^^^ + File "/nix/store/klsdmdrqkafiqhgcmvryqy4zli1ksxh2-qgis-unwrapped-3.38.3/share/qgis/python/plugins/processing/tools/general.py", line 109, in run + return Processing.runAlgorithm(algOrName, parameters, onFinish, feedback, context) + ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + File "/nix/store/klsdmdrqkafiqhgcmvryqy4zli1ksxh2-qgis-unwrapped-3.38.3/share/qgis/python/plugins/processing/core/Processing.py", line 186, in runAlgorithm + raise QgsProcessingException(msg) +_core.QgsProcessingException: Unable to execute algorithm +Could not load source layer for INPUT: invalid value diff --git a/test/test_data/wee_score/example_result.tif b/test/test_data/wee_score/example_result.tif new file mode 100644 index 00000000..78bd1b68 Binary files /dev/null and b/test/test_data/wee_score/example_result.tif differ diff --git a/test/test_data/wee_score/population/population.tif.aux.xml b/test/test_data/wee_score/example_result.tif.aux.xml similarity index 58% rename from test/test_data/wee_score/population/population.tif.aux.xml rename to test/test_data/wee_score/example_result.tif.aux.xml index 262d8265..ce6a88d9 100644 --- a/test/test_data/wee_score/population/population.tif.aux.xml +++ b/test/test_data/wee_score/example_result.tif.aux.xml @@ -2,9 +2,9 @@ 1 - 3 - 2 - 0.81649658092773 + 15 + 8 + 4.3204937989386 93.75 diff --git a/test/test_data/wee_score/model.json b/test/test_data/wee_score/model.json index d89936f4..ba9ae62c 100644 --- a/test/test_data/wee_score/model.json +++ b/test/test_data/wee_score/model.json @@ -49,12 +49,11 @@ "output_filename": "workplace_discrimination", "description": "Workplace Discrimination involves laws that address gender biases and stereotypes that hinder women's career advancement, especially in male-dominated fields.", "default_dimension_weighting": 0.333333, - "analysis_mode": "factor_aggregation", + "analysis_mode": "", "result": "factor_aggregation Workflow Completed", "execution_start_time": "2024-12-18T23:25:31.713939", "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/contextual/workplace_discrimination/workplace_discrimination_combined.vrt", - "execution_end_time": "2024-12-18T23:25:32.528534", - "error_file": null + "execution_end_time": "2024-12-18T23:25:32.528534" }, { "name": "Regulatory Frameworks", @@ -96,12 +95,11 @@ "output_filename": "regulatory_frameworks", "description": "Regulatory Frameworks pertain to laws and policies that protect women\u2019s employment rights, such as childcare support and parental leave, influencing their workforce participation", "default_dimension_weighting": 0.3333333, - "analysis_mode": "factor_aggregation", + "analysis_mode": "", "result": "factor_aggregation Workflow Completed", "execution_start_time": "2024-12-18T23:25:32.656651", "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/contextual/regulatory_frameworks/regulatory_frameworks_combined.vrt", - "execution_end_time": "2024-12-18T23:25:33.511264", - "error_file": null + "execution_end_time": "2024-12-18T23:25:33.511264" }, { "name": "Financial Inclusion", @@ -143,25 +141,23 @@ "output_filename": "financial_inclusion", "description": "Financial Inclusion involves laws concerning women\u2019s access to financial resources like loans and credit, which is crucial for starting businesses and investing in economic opportunities.", "default_dimension_weighting": 0.333333, - "analysis_mode": "factor_aggregation", + "analysis_mode": "", "result": "factor_aggregation Workflow Completed", "execution_start_time": "2024-12-18T23:25:33.683431", "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/contextual/financial_inclusion/financial_inclusion_combined.vrt", - "execution_end_time": "2024-12-18T23:25:34.529052", - "error_file": null + "execution_end_time": "2024-12-18T23:25:34.529052" } ], - "analysis_weighting": 1.0, + "analysis_weighting": 0.5, "description": "The Contextual Dimension refers to the laws and policies that shape workplace gender discrimination, financial autonomy, and overall gender empowerment. Although this dimension may vary between countries due to differences in legal frameworks, it remains consistent within a single country, as national policies and regulations are typically applied uniformly across countries.", "id": "contextual", "output_filename": "Contextual_score", "default_analysis_weighting": 0.333333, - "analysis_mode": "dimension_aggregation", + "analysis_mode": "", "result": "dimension_aggregation Workflow Completed", "execution_start_time": "2024-12-18T23:25:35.741929", "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/contextual/Contextual_score_combined.vrt", - "execution_end_time": "2024-12-18T23:25:36.623506", - "error_file": null + "execution_end_time": "2024-12-18T23:25:36.623506" }, { "name": "Accessibility", @@ -177,7 +173,7 @@ "output_filename": "WTP_Kindergartens_output", "description": "", "default_factor_weighting": 0.2, - "factor_weighting": 0.2, + "factor_weighting": "0.50", "index_score": 0, "use_index_score": 0, "default_multi_buffer_distances": "400, 800, 1200, 1500, 2000", @@ -193,8 +189,20 @@ "use_nighttime_lights": 0, "use_environmental_hazards": 0, "use_street_lights": 0, - "analysis_mode": "Do Not Use", - "guid": "ef86b2c4-f4b3-4552-8dc4-a619c54e53d6" + "analysis_mode": "use_multi_buffer_point", + "guid": "ef86b2c4-f4b3-4552-8dc4-a619c54e53d6", + "multi_buffer_point_layer_name": "fake_childcare", + "multi_buffer_point_layer_source": "/home/timlinux/dev/python/GEEST2/test/test_data/points/fake_childcare.gpkg|layername=fake_childcare", + "multi_buffer_point_layer_provider_type": "ogr", + "multi_buffer_point_layer_crs": "EPSG:32620", + "multi_buffer_point_layer_wkb_type": 1, + "multi_buffer_point_layer_id": "fake_childcare_6a120423_4837_409e_893c_cc06dd1bde8f", + "multi_buffer_point_shapefile": "", + "result": "use_multi_buffer_point Workflow Completed", + "execution_start_time": "2024-12-19T11:03:05.436850", + "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/accessibility/women_s_travel_patterns/kindergartens_location/WTP_Kindergartens_output_combined.vrt", + "execution_end_time": "2024-12-19T11:03:07.870440", + "error_file": null }, { "indicator": "Location of primary schools", @@ -202,7 +210,7 @@ "output_filename": "WTP_Primary_Schools_output", "description": "", "default_factor_weighting": 0.2, - "factor_weighting": 0.2, + "factor_weighting": "0.50", "index_score": 0, "use_index_score": 0, "default_multi_buffer_distances": "400, 800, 1200, 1500, 2000", @@ -218,8 +226,20 @@ "use_nighttime_lights": 0, "use_environmental_hazards": 0, "use_street_lights": 0, - "analysis_mode": "Do Not Use", - "guid": "7af1017c-c360-4630-a1e5-ac4874473e35" + "analysis_mode": "use_multi_buffer_point", + "guid": "7af1017c-c360-4630-a1e5-ac4874473e35", + "multi_buffer_point_layer_name": "fake_primary_schools", + "multi_buffer_point_layer_source": "/home/timlinux/dev/python/GEEST2/test/test_data/points/fake_primary_schools.gpkg|layername=fake_primary_schools", + "multi_buffer_point_layer_provider_type": "ogr", + "multi_buffer_point_layer_crs": "EPSG:32620", + "multi_buffer_point_layer_wkb_type": 1, + "multi_buffer_point_layer_id": "fake_primary_schools_1e5dc698_693d_48f5_afbb_f0e542c94e0a", + "multi_buffer_point_shapefile": "", + "result": "use_multi_buffer_point Workflow Completed", + "execution_start_time": "2024-12-19T11:03:08.098036", + "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/accessibility/women_s_travel_patterns/primary_school_location/WTP_Primary_Schools_output_combined.vrt", + "execution_end_time": "2024-12-19T11:03:10.000410", + "error_file": null }, { "indicator": "Location of groceries", @@ -227,7 +247,7 @@ "output_filename": "WTP_Groceries_output", "description": "", "default_factor_weighting": 0.2, - "factor_weighting": 0.2, + "factor_weighting": "0.00", "index_score": 0, "use_index_score": 0, "default_multi_buffer_distances": "400, 800, 1200, 1500, 2000", @@ -243,7 +263,7 @@ "use_nighttime_lights": 0, "use_environmental_hazards": 0, "use_street_lights": 0, - "analysis_mode": "Do Not Use", + "analysis_mode": "use_multi_buffer_point", "guid": "b0f37ad1-b728-4aa8-8bd6-40e60545a5a7" }, { @@ -252,7 +272,7 @@ "output_filename": "WTP_Pharmacies_output", "description": "", "default_factor_weighting": 0.2, - "factor_weighting": 0.2, + "factor_weighting": "0.00", "index_score": 0, "use_index_score": 0, "default_multi_buffer_distances": "400, 800, 1200, 1500, 2000", @@ -268,7 +288,7 @@ "use_nighttime_lights": 0, "use_environmental_hazards": 0, "use_street_lights": 0, - "analysis_mode": "Do Not Use", + "analysis_mode": "use_multi_buffer_point", "guid": "f96c74f4-492e-484b-b4e7-d72566071911" }, { @@ -277,7 +297,7 @@ "output_filename": "WTP_Green_Spaces_output", "description": "", "default_factor_weighting": 0.2, - "factor_weighting": 0.2, + "factor_weighting": "0.00", "index_score": 0, "use_index_score": 0, "default_multi_buffer_distances": "400, 800, 1200, 1500, 2000", @@ -293,20 +313,20 @@ "use_nighttime_lights": 0, "use_environmental_hazards": 0, "use_street_lights": 0, - "analysis_mode": "Do Not Use", + "analysis_mode": "use_multi_buffer_point", "guid": "6e7df235-9af3-4168-ba97-1004e289d7c7" } ], - "dimension_weighting": 0.2, + "dimension_weighting": 1.0, "id": "women_s_travel_patterns", "output_filename": "women_s_travel_patterns", "description": "Women\u2019s Travel Patterns (WTP) refer to the unique travel behaviors of women, often involving multiple stops for household or caregiving tasks, making proximity to essential services like markets, supermarkets, childcare centers, primary schools, pharmacies, and green spaces crucial.", "default_dimension_weighting": 0.2, "analysis_mode": "", - "result": "", - "execution_start_time": "", - "result_file": "", - "execution_end_time": "" + "result": "factor_aggregation Workflow Completed", + "execution_start_time": "2024-12-19T11:03:10.163971", + "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/accessibility/women_s_travel_patterns/women_s_travel_patterns_combined.vrt", + "execution_end_time": "2024-12-19T11:03:11.113707" }, { "name": "Access to Public Transport", @@ -338,7 +358,7 @@ "guid": "270bf387-5131-43c9-85f3-75d5c04df854" } ], - "dimension_weighting": 0.2, + "dimension_weighting": 0.0, "id": "access_to_public_transport", "output_filename": "access_to_public_transport", "description": "Access to Public Transport focuses on the availability and proximity of public transportation stops, which is crucial for women, especially those who rely on buses, trains, or trams to access jobs, education, and essential services.", @@ -379,7 +399,7 @@ "guid": "06ce6151-d70a-4564-bfc9-ca72989555e3" } ], - "dimension_weighting": 0.2, + "dimension_weighting": 0.0, "id": "access_to_health_facilities", "output_filename": "access_to_health_facilities", "description": "Access to Health Facilities evaluates how easily women can reach healthcare services in terms of distance, impacting their well-being and ability to participate in the workforce.", @@ -420,7 +440,7 @@ "guid": "b4e36508-0005-4f1d-864c-c679dde965c1" } ], - "dimension_weighting": 0.2, + "dimension_weighting": 0.0, "id": "access_to_education_and_training_facilities", "output_filename": "access_to_education_and_training_facilities", "description": "Access to Education and Training Facilities assesses the proximity to higher education institutions and training centers, influencing women's ability to gain necessary qualifications.", @@ -461,7 +481,7 @@ "guid": "cc080fdb-b57a-4fb6-9868-0afb610684bd" } ], - "dimension_weighting": 0.2, + "dimension_weighting": 0.0, "id": "access_to_financial_facilities", "output_filename": "access_to_financial_facilities", "description": "Access to Financial Facilities focuses on the proximity of banks and financial institutions, which is essential for women\u2019s economic empowerment and ability to access credit.", @@ -473,16 +493,16 @@ "execution_end_time": "" } ], - "analysis_weighting": 0.0, + "analysis_weighting": 0.5, "description": "The Accessibility Dimension evaluates women\u2019s daily mobility by examining their access to essential services. Levels of enablement for work access in this dimension are determined by service areas, which represent the geographic zones that facilities like childcare, supermarkets, universities, banks, and clinics can serve based on proximity. The nearer these facilities are to where women live, the more supportive and enabling the environment becomes for their participation in the workforce.", "id": "accessibility", "output_filename": "Accessibility_score", "default_analysis_weighting": 0.33333, "analysis_mode": "", - "result": "", - "execution_start_time": "", - "result_file": "", - "execution_end_time": "" + "result": "dimension_aggregation Workflow Completed", + "execution_start_time": "2024-12-19T11:03:11.276901", + "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/accessibility/Accessibility_score_combined.vrt", + "execution_end_time": "2024-12-19T11:03:12.223477" }, { "name": "Place Characterization", @@ -965,25 +985,25 @@ ], "result": "analysis_aggregation Workflow Completed", "result_file": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/_combined.vrt", - "execution_start_time": "2024-12-18T23:36:00.070532", - "execution_end_time": "2024-12-18T23:36:00.912866", + "execution_start_time": "2024-12-19T13:07:59.647020", + "execution_end_time": "2024-12-19T13:08:00.475715", "error": "", "error_file": null, "aggregation_layer": null, - "aggregation_layer_name": "", - "aggregation_layer_source": "", - "aggregation_layer_provider_type": "", + "aggregation_layer_name": "administrative_boundary", + "aggregation_layer_source": "/home/timlinux/dev/python/GEEST2/data/StLucia/saintluciagis.gpkg|layername=administrative_boundary", + "aggregation_layer_provider_type": "ogr", "aggregation_layer_crs": "", - "aggregation_layer_wkb_type": "", - "aggregation_layer_id": "", + "aggregation_layer_wkb_type": 6, + "aggregation_layer_id": "administrative_boundary_7f19d49d_e23e_4737_9d7e_8fc99db4ef72", "aggregation_shapefile": "", "population_layer": null, - "population_layer_name": "population", - "population_layer_source": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/population/population.tif", + "population_layer_name": "lca_ppp_2020_UNadj_constrained", + "population_layer_source": "/home/timlinux/dev/python/GEEST2/data/StLucia/Population/lca_ppp_2020_UNadj_constrained.tif", "population_layer_provider_type": "gdal", - "population_layer_crs": "EPSG:32620", + "population_layer_crs": "EPSG:4326", "population_layer_wkb_type": "", - "population_layer_id": "population_c608de24_709a_4ad5_a451_12d344147a79", + "population_layer_id": "lca_ppp_2020_UNadj_constrained_ec945779_3222_4975_9f04_3312e7855d64", "population_shapefile": "", "point_mask_layer": null, "point_mask_layer_name": "", @@ -1009,5 +1029,6 @@ "raster_mask_layer_wkb_type": "", "raster_mask_layer_id": "", "raster_mask_shapefile": "", - "analysis_mode": "analysis_aggregation" + "analysis_mode": "analysis_aggregation", + "wee_by_population": "/home/timlinux/dev/python/GEEST2/test/test_data/wee_score/wee_score/wee_by_population_score.vrt" } \ No newline at end of file diff --git a/test/test_data/wee_score/population/clipped_0.tif b/test/test_data/wee_score/population/clipped_0.tif index 25f4d4f6..7b50e6f9 100644 Binary files a/test/test_data/wee_score/population/clipped_0.tif and b/test/test_data/wee_score/population/clipped_0.tif differ diff --git a/test/test_data/wee_score/population/clipped_0.tif.aux.xml b/test/test_data/wee_score/population/clipped_0.tif.aux.xml index 93d38c0d..a2178786 100644 --- a/test/test_data/wee_score/population/clipped_0.tif.aux.xml +++ b/test/test_data/wee_score/population/clipped_0.tif.aux.xml @@ -1,11 +1,11 @@ - 1 - 3 - 2 - 0.81649658092773 - 41.67 + 13 + 65 + 33.003046458492 + 9.1863995888524 + 28.82 diff --git a/test/test_data/wee_score/population/clipped_population.vrt b/test/test_data/wee_score/population/clipped_population.vrt index 558838b9..d21310de 100644 --- a/test/test_data/wee_score/population/clipped_population.vrt +++ b/test/test_data/wee_score/population/clipped_population.vrt @@ -1,15 +1,15 @@ - - PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] - 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5530000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AXIS["Latitude",NORTH],AXIS["Longitude",EAST],AUTHORITY["EPSG","4326"]] + -6.1019166280774705e+01, 8.3333332806324108e-04, 0.0000000000000000e+00, 1.4039999930666639e+01, 0.0000000000000000e+00, -8.3333332921810537e-04 -9999 Gray clipped_0.tif 1 - - - + + + -9999 diff --git a/test/test_data/wee_score/population/population.asc.aux.xml b/test/test_data/wee_score/population/population.asc.aux.xml deleted file mode 100644 index e1f2d894..00000000 --- a/test/test_data/wee_score/population/population.asc.aux.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - 1 - 3 - 2.0714285714286 - 0.79859570624992 - 87.5 - - - diff --git a/test/test_data/wee_score/population/reclassified_0.qml b/test/test_data/wee_score/population/reclassified_0.qml new file mode 100644 index 00000000..562f5286 --- /dev/null +++ b/test/test_data/wee_score/population/reclassified_0.qml @@ -0,0 +1,156 @@ + + + + 1 + 1 + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + None + WholeRaster + Estimated + 0.02 + 0.98 + 2 + + + + + + + + + + + + + + resamplingFilter + + 0 + diff --git a/test/test_data/wee_score/population/reclassified_0.tif b/test/test_data/wee_score/population/reclassified_0.tif index 602b21a0..748e25f7 100644 Binary files a/test/test_data/wee_score/population/reclassified_0.tif and b/test/test_data/wee_score/population/reclassified_0.tif differ diff --git a/test/test_data/wee_score/population/reclassified_0.tif.aux.xml b/test/test_data/wee_score/population/reclassified_0.tif.aux.xml index f1e1aa6d..83e69542 100644 --- a/test/test_data/wee_score/population/reclassified_0.tif.aux.xml +++ b/test/test_data/wee_score/population/reclassified_0.tif.aux.xml @@ -1,11 +1,11 @@ - 2 3 - 2.5 - 0.5 - 20.41 + 2 + 1 + 0.81649658092773 + 30.61 diff --git a/test/test_data/wee_score/population/reclassified_population.vrt b/test/test_data/wee_score/population/reclassified_population.vrt index 83e608d3..f57d3f25 100644 --- a/test/test_data/wee_score/population/reclassified_population.vrt +++ b/test/test_data/wee_score/population/reclassified_population.vrt @@ -1,16 +1,16 @@ PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5540000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 - - 0 + + -9999 Gray reclassified_0.tif 1 - + - 0 + -9999 diff --git a/test/test_data/wee_score/population/relassified_population.vrt b/test/test_data/wee_score/population/relassified_population.vrt new file mode 100644 index 00000000..9f2ec859 --- /dev/null +++ b/test/test_data/wee_score/population/relassified_population.vrt @@ -0,0 +1,23 @@ + + PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] + 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5540000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + + 1 + 3 + 2 + 0.81649658092773 + 28.57 + + -9999 + Gray + + reclassified_0.tif + 1 + + + + -9999 + + + diff --git a/test/test_data/wee_score/population/resampled_0.tif b/test/test_data/wee_score/population/resampled_0.tif index 748e25f7..eaf31250 100644 Binary files a/test/test_data/wee_score/population/resampled_0.tif and b/test/test_data/wee_score/population/resampled_0.tif differ diff --git a/test/test_data/wee_score/population/resampled_0.tif.aux.xml b/test/test_data/wee_score/population/resampled_0.tif.aux.xml index 5dd89061..7e1a5148 100644 --- a/test/test_data/wee_score/population/resampled_0.tif.aux.xml +++ b/test/test_data/wee_score/population/resampled_0.tif.aux.xml @@ -1,11 +1,11 @@ - 1 - 3 - 2 - 0.81649658092773 - 30.61 + 7 + 4613 + 1397.8387096774 + 1218.8843681899 + 63.27 diff --git a/test/test_data/wee_score/study_area/study_area.gpkg b/test/test_data/wee_score/study_area/study_area.gpkg index 3d663947..e187be96 100644 Binary files a/test/test_data/wee_score/study_area/study_area.gpkg and b/test/test_data/wee_score/study_area/study_area.gpkg differ diff --git a/test/test_data/wee_score/study_area/study_area.gpkg-shm b/test/test_data/wee_score/study_area/study_area.gpkg-shm deleted file mode 100644 index fe9ac284..00000000 Binary files a/test/test_data/wee_score/study_area/study_area.gpkg-shm and /dev/null differ diff --git a/test/test_data/wee_score/study_area/study_area.gpkg-wal b/test/test_data/wee_score/study_area/study_area.gpkg-wal deleted file mode 100644 index e69de29b..00000000 diff --git a/test/test_data/wee_score/wee.asc.aux.xml b/test/test_data/wee_score/wee.asc.aux.xml new file mode 100644 index 00000000..5d7c379f --- /dev/null +++ b/test/test_data/wee_score/wee.asc.aux.xml @@ -0,0 +1,11 @@ + + + + 1 + 5 + 3 + 1.4142135623731 + 93.75 + + + diff --git a/test/test_data/wee_score/wee_masked_0.tif b/test/test_data/wee_score/wee_masked_0.tif index 6cd7f434..cabc4180 100644 Binary files a/test/test_data/wee_score/wee_masked_0.tif and b/test/test_data/wee_score/wee_masked_0.tif differ diff --git a/test/test_data/wee_score/wee_masked_0.tif.aux.xml b/test/test_data/wee_score/wee_masked_0.tif.aux.xml index 9875ba02..418fdaf5 100644 --- a/test/test_data/wee_score/wee_masked_0.tif.aux.xml +++ b/test/test_data/wee_score/wee_masked_0.tif.aux.xml @@ -1,10 +1,10 @@ - 5 - 5 - 5 - 0 + 2.5 + 4.75 + 3.5416666666667 + 0.74884169815048 100 diff --git a/test/test_data/wee_score/wee_score.qgz b/test/test_data/wee_score/wee_score.qgz index d8ed6cf9..c3f87a17 100644 Binary files a/test/test_data/wee_score/wee_score.qgz and b/test/test_data/wee_score/wee_score.qgz differ diff --git a/test/test_data/wee_score/wee_score/validation_points.gpkg b/test/test_data/wee_score/wee_score/validation_points.gpkg new file mode 100644 index 00000000..5c274a72 Binary files /dev/null and b/test/test_data/wee_score/wee_score/validation_points.gpkg differ diff --git a/test/test_data/wee_score/wee_score/wee_by_population_score.qml b/test/test_data/wee_score/wee_score/wee_by_population_score.qml new file mode 100644 index 00000000..d315be00 --- /dev/null +++ b/test/test_data/wee_score/wee_score/wee_by_population_score.qml @@ -0,0 +1,171 @@ + + + + 1 + 1 + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + None + WholeRaster + Estimated + 0.02 + 0.98 + 2 + + + + + + + + + + + + + + + + + + + + + + + + + + resamplingFilter + + 0 + diff --git a/test/test_data/wee_score/wee_score/wee_by_population_score.vrt b/test/test_data/wee_score/wee_score/wee_by_population_score.vrt new file mode 100644 index 00000000..45a34cc2 --- /dev/null +++ b/test/test_data/wee_score/wee_score/wee_by_population_score.vrt @@ -0,0 +1,16 @@ + + PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] + 7.1400000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5530000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + 255 + Gray + + wee_by_population_score_0.tif + 1 + + + + 255 + + + diff --git a/test/test_data/wee_score/wee_score/wee_by_population_score_0.tif b/test/test_data/wee_score/wee_score/wee_by_population_score_0.tif new file mode 100644 index 00000000..9979d71f Binary files /dev/null and b/test/test_data/wee_score/wee_score/wee_by_population_score_0.tif differ diff --git a/test/test_data/wee_score/wee_score/wee_by_population_score_0.tif.aux.xml b/test/test_data/wee_score/wee_score/wee_by_population_score_0.tif.aux.xml new file mode 100644 index 00000000..55f6ca93 --- /dev/null +++ b/test/test_data/wee_score/wee_score/wee_by_population_score_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 14 + 11.466666666667 + 9 + 1.783878421368 + 41.67 + + + diff --git a/test/test_data/wee_score/wee_score/wee_score.qml b/test/test_data/wee_score/wee_score/wee_score.qml new file mode 100644 index 00000000..d315be00 --- /dev/null +++ b/test/test_data/wee_score/wee_score/wee_score.qml @@ -0,0 +1,171 @@ + + + + 1 + 1 + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + None + WholeRaster + Estimated + 0.02 + 0.98 + 2 + + + + + + + + + + + + + + + + + + + + + + + + + + resamplingFilter + + 0 + diff --git a/test/test_data/wee_score/wee_score/wee_score.vrt b/test/test_data/wee_score/wee_score/wee_score.vrt new file mode 100644 index 00000000..6a9ed1e8 --- /dev/null +++ b/test/test_data/wee_score/wee_score/wee_score.vrt @@ -0,0 +1,16 @@ + + PROJCS["WGS 84 / UTM zone 20N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-63],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32620"]] + 7.1500000000000000e+05, 1.0000000000000000e+03, 0.0000000000000000e+00, 1.5520000000000000e+06, 0.0000000000000000e+00, -1.0000000000000000e+03 + + 255 + Gray + + wee_score_0.tif + 1 + + + + 255 + + + diff --git a/test/test_data/wee_score/wee_score/wee_score_0.tif b/test/test_data/wee_score/wee_score/wee_score_0.tif new file mode 100644 index 00000000..eb68b60b Binary files /dev/null and b/test/test_data/wee_score/wee_score/wee_score_0.tif differ diff --git a/test/test_data/wee_score/wee_score/wee_score_0.tif.aux.xml b/test/test_data/wee_score/wee_score/wee_score_0.tif.aux.xml new file mode 100644 index 00000000..ce6a88d9 --- /dev/null +++ b/test/test_data/wee_score/wee_score/wee_score_0.tif.aux.xml @@ -0,0 +1,11 @@ + + + + 1 + 15 + 8 + 4.3204937989386 + 93.75 + + + diff --git a/test/test_data/wee_score/womens_economic_empowerment_-_wee_score_aggregated_0.tif b/test/test_data/wee_score/womens_economic_empowerment_-_wee_score_aggregated_0.tif index bac18575..dc696c8f 100644 Binary files a/test/test_data/wee_score/womens_economic_empowerment_-_wee_score_aggregated_0.tif and b/test/test_data/wee_score/womens_economic_empowerment_-_wee_score_aggregated_0.tif differ diff --git a/test/test_wee_score_processor.py b/test/test_wee_score_processor.py index 4e7aeda0..48684e02 100644 --- a/test/test_wee_score_processor.py +++ b/test/test_wee_score_processor.py @@ -9,7 +9,7 @@ StudyAreaProcessingTask, ) # Adjust the import path as necessary from utilities_for_testing import prepare_fixtures -from geest.core.algorithms import WEEScoreProcessingTask +from geest.core.algorithms import WEEByPopulationScoreProcessingTask class TestWEEScoreProcessingTask(unittest.TestCase): @@ -25,7 +25,7 @@ def setUpClass(cls): cls.feedback = QgsFeedback() def setUp(self): - self.task = WEEScoreProcessingTask( + self.task = WEEByPopulationScoreProcessingTask( # geest_raster_path=f"{self.working_directory}/wee_masked_0.tif", # pop_raster_path=f"{self.working_directory}/population/reclassified_0.tif", study_area_gpkg_path=f"{self.working_directory}/study_area/study_area.gpkg",