-
Hi I am using the tutorial from Caravan_part1_Earth_Engine.ipynb and there is a part that says: " The shapefile needs to have one field that indicates the basin/gauge ID, which will be used to link the derived data to the individual basin. Make sure to adapt the corresponding variable in the "General configuration" section below. " ASSET_NAME = ''
OUTPUT_FOLDER_NAME = ''
BASIN_ID_FIELD = ''
BASIN_PREFIX = ''
AREA_MAX_THRESHOLD = 2000
AREA_MIN_THRESHOLD = 50 The basin_ID field in my shp file is:
(This table has 1070 12-level basins) In the tutorial, everything runs good but there is a part: Perform Intersection and download data where an error rises and says:
I thought this error was due to my mistake of using level-3 basins, so I changed it to the 12-level but still rising error. Could you give me any clue, please? edit 3: I have fixed geometries from hydroBASINS but same error (with different basin_ID) yields. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
Hey @maby200 Edit: See answer in my first comment below this post. To be honest, I am not quite sure I understand what happens here, as I have never seen such an error. It seems like there is a mismatch over basin-id's that are returned from # list of all available basins
basin_ids = basins.aggregate_array(BASIN_ID_FIELD).getInfo() which is used to populate the results dictionary just below # dictionary to store the results
results = {b: defaultdict(list) for b in basin_ids} So any basin id that is in your shapefile in the column name like the value of On another note: You probably don't want to process 1070 basins all at once. I should maybe add this to the wiki guide. There are two reasons for this: The raw generated text files (spatial average per basin, per feature, and per hour) of ERA5L is still huge. As a reference, I process basins in batches of ~600 polygons and the raw text files that are saved in Drive (and then processed in the second notebook) are still in the range of 80-90GB. You can extrapolate from that how large it would be for 1070 basins and if that fits into your Drive. It will also take quite a while (~2-3 days) before all EE tasks will be completed. So what I usually do is to split my shapefile into smaller groups, then process them sequentially, one after the other. |
Beta Was this translation helpful? Give feedback.
Hey @maby200
Edit: See answer in my first comment below this post.
To be honest, I am not quite sure I understand what happens here, as I have never seen such an error. It seems like there is a mismatch over basin-id's that are returned from
which is used to populate the results dictionary just below
So any basin id that is in your shapefile in the column name like the value of
BASIN_ID_FIELD
, should exist as a key in the results dictionary. If you want, you can send my your basin shape file or share the asset wit…