Hi, I have a problema with the bulk files generation using the make_ERA5 function for the Benguela_LR case in the croco v2.0. For croco_blk_ERA5_Y2005M01.nc the bulk_time variable begin with the following values:
bulk_time = [45985575.9946237;45985725.9973118;45985876;45986024;45986176…]
The attributes indicate that the unit of the variable is in days, I assume it is days from the time of initialization (2000-01-01). However, the values do not match.
double bulk_time(bulk_time), shape = [748], Chunking = [524288], Deflate = 0
:long_name = "bulk formulation execution time"
:units = "days"
:cycle_length = 0
Then, when I try to run the model I get the following error because the times values of inputs files do not match:
SET_CYCLE ERROR: non-cycling regime, but model time exceeds
time of the last available data record for variable: bulk_time
TDAYS = 1827. TLAST = 0.4610E+08
I believe that is a problema with the convert process.
@sbahamondez
Welcome you on croCO.
which .m file you used for ERA5 to download the data.
It helps me. look at your problem better.
SET_CYCLE ERROR: non-cycling regime. it may be 360 or 365. .
I used ERA5_request.py and after ERA5_convert.py.
Right now, identify that the files in ERA5_native_Benguela_LR correspond to seconds since 1970-01-01, but in ERA5_convert.py following appear:
Convert time from hours since 1900-1-1 0:0:0 into days since Yorig-1-1 0:0:0
time = time / 24.
time = time - date.toordinal(date(Yorig,1,1)) \
+ date.toordinal(date(1900,1,1))
@sbahamondez
Why not! use your own test case. I will check.
Best
Subhadeep
Hi, I’m having the same problem. Did you manage to solve the problem?
@eduardolima255 @sbahamondez
after looking at your problem finds that cds API will expire soon and cds beta API is now available. but complete transition not done yet. can you share your file with me. email: subhadeepmaishal@kgpian.iitkgp.ac.in or upload file somewhere and share the link. to run ERA5_convert.py
. only one month of data. For ERA5 use CROCO_TOOLS v1.3.1 .
Best All,
Subhadeep
Yes, ok.
As mentioned by sbahamondez, I noticed that the ERA5 temporal data uses January 1, 1970, as a reference. I ran a test by downloading the data from ERA5_request.py for own area, selecting 2015 as the start and end year, with January as the start month and March as the end month. I noticed that the data downloaded from ERA5 is in units of seconds. The script ERA5_convert.py use:
Convert time from hours since 1900-1-1 0:0:0 into days since Yorig-1-1 0:0:0
time = time / 24.
time = time - date.toordinal(date(Yorig, 1, 1))
+ date.toordinal(date(1900, 1, 1))
However, since the data is in seconds, I changed time = time / 24. to time = time / 86400. to convert from seconds to days. After that, I ran the model and didn’t get the bulk_time error, but it resulted in an ABNORMAL JOB END BLOW UP error. I’m investigating this new error.
@eduardolima255 ok. send me your file. see what can i do. both file.
Best
1 Like
I solved the BLOW JOB by decreasing the dt[sec]. The change in ERA5_convert.py worked fine:
time = time / 86400. # 24
time = time - date.toordinal(date(Yorig,1,1)) \
+ date.toordinal(date(1970,1,1)) # change 1900 to 1970
inform @sbahamondez how you solved it. may be in massage. Helps others with your best. otherwise what is a model , what is CROCO. looking for real :: *.
Best,
Subhadeep
Hello, i’m sending the requested files.
I used CROCO v2.0.0 and CROCO_TOOLS v2.0.0
the files used in preprocessing step:
download_mercator_python.m (5.8 KB)
ERA5_convert.py (4.1 KB)
era5_crocotools_param.py (2.7 KB)
ERA5_request.py (6.8 KB)
the files used to compiling:
cppdefs.h (44.7 KB)
param.h (33.6 KB)
run_croco_inter.bash:
run_croco_inter.bash - Google Drive (it’s not possible to upload directly here)
i don’t need a file.
@sbahamondez check your problem is solved or not. find the script modified by @eduardolima255 .
If it works then thanks @eduardolima255 . I will discuss this in croco-dev gitlab. we will merge it soon.
Thank you! Eduardo.
Best,
Subhadeep
Hi @smaishal, sorry for my delayed response. I had a problem about notifications.
Indeed I solved the problem using the same that Eduardo indicated.
time = time / 86400.
time = time - date.toordinal(date(Yorig,1,1))
+ date.toordinal(date(1970,1,1))
Best Regards,
Sergio Bahamóndez