Skip to content

Commit

Permalink
Revert "Merge pull request GEO-BON#177 from GEO-BON/loadFromStac_resa…
Browse files Browse the repository at this point in the history
…mpling"

This reverts commit 703ddc7, reversing
changes made to 114470c.
  • Loading branch information
jmlord committed Oct 4, 2024
1 parent 703ddc7 commit 34916d5
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 10 deletions.
10 changes: 2 additions & 8 deletions pipelines/SDM/SDM_maxEnt.json
Original file line number Diff line number Diff line change
Expand Up @@ -417,8 +417,8 @@
"id": "119",
"type": "io",
"position": {
"x": 514.7177806924453,
"y": 273.83554287387864
"x": 521.7177806924453,
"y": 279.83554287387864
},
"data": {
"descriptionFile": "data>loadFromStac.yml"
Expand Down Expand Up @@ -548,8 +548,6 @@
"q3"
]
}
<<<<<<< HEAD
=======
},
{
"id": "132",
Expand All @@ -570,7 +568,6 @@
"median"
]
}
>>>>>>> main
}
],
"edges": [
Expand Down Expand Up @@ -937,16 +934,13 @@
"target": "119",
"targetHandle": "resampling",
"id": "reactflow__edge-131-119resampling"
<<<<<<< HEAD
=======
},
{
"source": "132",
"sourceHandle": null,
"target": "119",
"targetHandle": "aggregation",
"id": "reactflow__edge-132-119aggregation"
>>>>>>> main
}
],
"inputs": {
Expand Down
7 changes: 6 additions & 1 deletion scripts/data/loadFromStac.R
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ if("resampling" %in% names(input)){
resampling="near"
}

if("aggregation" %in% names(input)){
aggregation=input$aggregation
}else{
aggregation="first"
}

if("taxa" %in% names(input)){ #EXTRACT GBIF HEATMAPS
collections_items <- paste0("gbif_heatmaps|", input$taxa, "-heatmap")
Expand Down Expand Up @@ -71,7 +76,7 @@ cube_args <- list(stac_path = input$stac_url,
t1 = NULL,
spatial.res = input$spatial_res, # in meters
temporal.res = "P1D",
aggregation = "first",
aggregation = aggregation,
resampling = resampling)

proj <- input$proj
Expand Down
2 changes: 1 addition & 1 deletion scripts/data/loadFromStacFun.R
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ load_cube <-
t1 = format(lubridate::as_datetime('2200-01-01'), "%Y-%m-%dT%H:%M:%SZ"),
spatial.res = NULL,
temporal.res = "P1Y",
aggregation = "first",
aggregation = "mean",
resampling = "near") {
s <- rstac::stac(stac_path)
if (!inherits(bbox, "bbox"))
Expand Down

0 comments on commit 34916d5

Please sign in to comment.