Skip to content

Commit

Permalink
Fix dimension aggregate running
Browse files Browse the repository at this point in the history
  • Loading branch information
timlinux committed Oct 6, 2024
1 parent 69bdd5f commit 6a02772
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions geest/core/workflows/dimension_aggregation_workflow.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def __init__(self, item: JsonTreeItem, feedback: QgsFeedback):
"""
super().__init__(item, feedback)
self.aggregation_attributes = self.item.getDimensionAttributes()
self.id = self.aggregation_attributes[f"Dimension ID"].lower().replace(" ", "_")
self.id = self.attributes["id"].lower().replace(" ", "_")
self.layers = self.aggregation_attributes.get(f"Factors", [])
self.weight_key = "Factor Weighting"
self.result_file_tag = "Dimension Result File"
Expand All @@ -44,10 +44,7 @@ def output_path(self, extension: str) -> str:
str: Path to the aggregated raster file.
"""
directory = os.path.join(
self.workflow_directory,
self.attributes.get("Dimension ID").lower().replace(" ", "_"),
)
directory = os.path.join(self.workflow_directory, self.id)
# Create the directory if it doesn't exist
if not os.path.exists(directory):
os.makedirs(directory)
Expand Down

0 comments on commit 6a02772

Please sign in to comment.