Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/eo_processing/openeo/processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -443,17 +443,17 @@ def generate_nonEO_feature_cube(
**processing_options: Dict[str, Union[str, bool, int | float, List[str], List[int | float]]]) -> DataCube:

""" Warper to generate the data cube of all nonEO data based on a collections list of the form [(collection, [band1, band2, ...])]"""
temporal_extent = [start, end]
temporal_extent = None

chunk_size: int = processing_options.get("openeo_chunk_size", CHUNK_SIZE)

for collection, bands, reproj, year in collections_list:
for collection, bands, reproj, year, stac_url in collections_list:
#first need to distinguish between STAC and collection
#we assume that they will allways be an url type of link in contrary with a collections which should just be a name
if temporal_extent:
if year:
temporal_extent = [f"{year}-01-01T00:00:00Z", f"{year}-12-31T23:59:59Z"]
STAC_url = get_stac_collection_url(collection)
else:
temporal_extent = None
STAC_url = get_stac_collection_url(collection, stac_url)
isSTAC = STAC_url is not None

#secondly we know there are some specific case of reprojection EG DEM should be bilinear iso near
Expand Down
7 changes: 5 additions & 2 deletions src/eo_processing/utils/jobmanager.py
Original file line number Diff line number Diff line change
Expand Up @@ -782,6 +782,7 @@ def create_job_dataframe(gdf: Union[gpd.GeoDataFrame, List], year: int, file_nam
discriminator: Optional[str] = None, target_crs: Optional[int] = None,
version: Optional[str] = None,
model_ID: Optional[str] = None,
nonEO_file: Optional[str] = None,
storage_options: Optional[storage_option_format] = None,
organization_id : Optional[int] = None, path_global_grid: Optional[str] = None,
feature_bbox: Optional[Tuple[float, float, float, float]] = None) -> gpd.GeoDataFrame:
Expand Down Expand Up @@ -817,11 +818,11 @@ def create_job_dataframe(gdf: Union[gpd.GeoDataFrame, List], year: int, file_nam
if isinstance(gdf, gpd.GeoDataFrame):
# we are preparing a inference or post-processing actions
columns = ['name', 'tileID', 'target_epsg', 'bbox', 'file_prefix', 'start_date', 'end_date','export_workspace',
's3_prefix', 'organization_id', 's2_tileid_list']
's3_prefix', 'organization_id', 's2_tileid_list','nonEO_file']
dtypes = {'name': 'string', 'tileID': 'string', 'target_epsg': 'UInt16',
'file_prefix': 'string', 'start_date': 'string', 'end_date': 'string', 's3_prefix': 'string',
'geometry': 'geometry', 'bbox': 'string', 'organization_id':'UInt16','s2_tileid_list':'string',
'export_workspace':'string'}
'export_workspace':'string','nonEO_file' : 'string'}

job_df = gdf.copy()

Expand Down Expand Up @@ -862,6 +863,8 @@ def create_job_dataframe(gdf: Union[gpd.GeoDataFrame, List], year: int, file_nam
job_df['s3_prefix'] = None
job_df['export_workspace'] = None

# set no EO list Should be later replaced by an extraction method straight out of the model metadata.
job_df['nonEO_file'] = nonEO_file
# a fix since the "name" column has to be unique
job_df['tileID'] = job_df[tile_col].copy()
if discriminator:
Expand Down
Loading