-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
regenerate geojson for RES=6 #19
Comments
Couldn't generate at H3 resolution 6 (see resolutions) for the entire snapshot. Memory usage at 24.23GB.
Code: > ptm <- proc.time()
> # grid resolution
> # 3 = 15 mins
> # 6 =
> RES <- 6
>
> # map defaults
> column <- "es"
> label <- "ES(50)"
> trans <- "identity"
> crs <- "+proj=eqc +lat_ts=0 +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs +type=crs"
> limits <- c(0,50)
>
>
> # make grid
> grid_dec <- res_changes(occ, RES)
Error: memory exhausted (limit reached?) So, now we have to figure out what the capacity is for running this locally, or explore other more performant solutions. Like |
My system info:
|
probably subsetting to us marine waters. @mimidiorio do you have a polygon for the region of interest? That will help with compute resources. |
@MathewBiddle USwaters shapefile is here |
Tried to run the H3 grid at resolution 6 for 1 year (1970-1971) between 0 < Lat < 74.7, 160 < Lon < -40 (an extremely rough approximation of US waters bounding box). dec_beg <- 1970
occ_dec <-
occ %>%
filter(between(decimalLatitude,0.00,74.7)) %>%
filter(between(decimalLongitude,-180.0,-40.0) | between(decimalLongitude,160.0,180.0)) %>%
filter(
date_year >= dec_beg,
date_year <= dec_beg+1) Even with this significant reduction in data, I ran into It used used 24.37GB memory before it bailed. What do we do now?At H3 resolution 6 we are creating hexagons with the average area of 36 km^2 (according to the spec). I think resolution 4 (1,770 km^2) or 5 (252 km^2) would be more feasible and could significantly reduce the processing needed to generate the data. I'll try to run the grid for resolution 5 and see if that succeeds with this massive reduction in data. |
Phooey. If you can get H4 to run, let's check that out. Have asked for NODD space/access. Not really sure what exactly we need, but seeing what might be available to us. Any specs or requirements I can relay to the NODD team would help. |
@mimidiorio you can find the tests for the different resolutions at:
|
I have been testing with subsetting the OBIS snapshot down to the polygon @mimidiorio provided (.shp added to the PR above, let me know if this is not okay). Even with that significant reduction in data (35million records down to 39k) it still takes a long time to run the H3 gridding process at resolution 6. One positive is that I am no longer running into memory limitations. But, I am still only testing with one year of data (1970-1971). The next step is to dig into the grid generating function to see why that is taking so long. Is it generating a global grid and then trying to compute for all grids? We only need it to generate for the regions of interest. We might be able to optimize |
I think I'm getting a clearer picture. Building a grid at resolution 6 takes a long time! So, how can we optimize that process to build a grid only for data we have? |
@mimidiorio I was able to make res=6 indicator from 1970-1971. See the geosjon at: |
https://h3geo.org/docs/core-library/restable/#average-area-in-km2
globe/use_parquet_file_for_globe.Rmd
Line 196 in b649e5b
Record how much time it takes.
The text was updated successfully, but these errors were encountered: