COSIMA / access-om3

ACCESS-OM3 global ocean-sea ice-wave coupled model
13 stars 7 forks source link

`d<comp>.streams.xml` inconsistencies #193

Closed dougiesquire closed 4 months ago

dougiesquire commented 4 months ago

There are inconsistencies between the d<comp>.streams.xml files in some of our configurations and those generated by the scripts in om3-scripts/data_stream_xml_generation. Specifically, in the RYF configurations (at least the ones I looked at):

@ezhilsabareesh8, which is right and are there any other inconsistencies?

ezhilsabareesh8 commented 4 months ago

@dougiesquire Some variables starts at 1:30 hrs and ends at 22:30 hrs, while the some variables starts at 0:00 hrs and ends at 21:00 hrs. To make the start time uniform for all variable and to eliminate max dt limit error we offset some of the variables, refer here.

dougiesquire commented 4 months ago

So are our RYF configs currently wrong?

ezhilsabareesh8 commented 4 months ago

Similarly an offset of -43200 is set only in IAF configs to match the RYF, since IAF starts at noon, we shifted it to midnight similar to RYF

dougiesquire commented 4 months ago

But the scripts don't discriminate on RYF vs IAF - they just always set the offsets to the IAF values

ADDED: So, for example, if I try to generate drof.streams.xml for an RYF config:

$ generate_xml_drof.py 1900 1900

I get a drof.streams.xml file with streams that have offset = -43200.

ezhilsabareesh8 commented 4 months ago

There's a bug in the code then, will fix it. The drof.streams.xml files in the configs seems to be fine.

ezhilsabareesh8 commented 4 months ago

Thanks @dougiesquire for picking this. error. Fixed denerate_xml_drof.py to set zero offset for RYFs in this PR.

dougiesquire commented 4 months ago

Thanks @ezhilsabareesh8. I think generate_xml_datm.py also needs a similar change.

ezhilsabareesh8 commented 4 months ago

I think generate_xml_datm.py also needs a similar change.

DATM is fine, both the RYF and IAF dataset starts at midnight. The offset is required only for few variables which starts at 1:30 hrs, which is already implemented in the code.

dougiesquire commented 4 months ago

Okay, so does that mean what's in our current RYF configs are wrong?

E.g. https://github.com/COSIMA/MOM6-CICE6/blob/070493071c807e26071062ed14be795f150426de/datm.streams.xml#L4-L23

ezhilsabareesh8 commented 4 months ago

DATM is fine, both the RYF and IAF dataset starts at midnight. The offset is required only for few variables which starts at 1:30 hrs, which is already implemented in the code.

Apologise, I think I didn't explain clearly. The offset of -5400 for some variables is required only in IAF whereas in RYF everything is uniform and starts at 0:00 hrs. I had a quick look at the dataset to confirm it, datm.streams.xml is consistent with the data. The negative offset of 5400 should be set only for IAF, will modify the code.

dougiesquire commented 4 months ago

Closed by https://github.com/COSIMA/om3-scripts/pull/17