# Why is there only 2 years of data for net\_sfc\_heating in ACCESS-OM2 RYF9091 runs?

**URL:** <https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350>\
**Category:** Experiments\
**Tags:** python, help, cosima\
**Created:** [26 March 2025 01:34 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350 "2025-03-26T01:34:04Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![sb4233](https://avatars.discourse-cdn.com/v4/letter/s/85f322/32.png) [@sb4233](https://forum.access-hive.org.au/u/sb4233)\
**Post date:** [26 March 2025 01:34 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350/1 "2025-03-26T01:34:04Z")

</div>

I am looking at the output variables from `access_01deg_jra55v13_ryf9091` runs for a heat budget analysis and I am accessing the data using` cosima-cookbook`.

I noticed that `net_sfc_heating` has only ~2 years (`1900-01-01` to `1902-10-01`) of data available while other variables are available for a longer period of time.

I understand that the runs are essentially representing the same calendar year (i.e., if neglecting model internal variability) but is there a specific reason for the limited output for `net_sfc_heating`?

![image](https://us1.discourse-cdn.com/flex020/uploads/access1/original/2X/2/237cdabeae18e92bd9b4a349c86508b9e998ea75.png)

---

<div class="post-metadata">

**Author:** ![dougiesquire](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/dougiesquire/32/16_2.png) [@dougiesquire](https://forum.access-hive.org.au/u/dougiesquire)\
**Post date:** [26 March 2025 11:17 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350/2 "2025-03-26T11:17:29Z")

</div>

According to [ACCESS-OM2 Control Experiments](https://forum.access-hive.org.au/t/access-om2-control-experiments/258) I think @AndyHoggANU is responsible for that experiment. Possibly he can recall/help.

---

<div class="post-metadata">

**Author:** ![AndyHoggANU](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/andyhogganu/32/43_2.png) [@AndyHoggANU](https://forum.access-hive.org.au/u/AndyHoggANU)\
**Post date:** [26 March 2025 21:26 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350/3 "2025-03-26T21:26:22Z")

</div>

Hi Sugata, I can’t remember specifically why we made those changes - that run was kicked off about 6 years ago - but I do recall that we don’t usually use `net_sfc_heating` as the heat flux diagnostic, as it’s inaccurate. If you look at this recipe:

> <https://github.com/COSIMA/cosima-recipes/blob/main/Recipes/Surface_Water_Mass_Transformation.ipynb>

You’ll see that we define heat flux in MOM5 as:

```auto
"heat_flux": ["sfc_hflux_coupler", "sfc_hflux_from_runoff", "frazil_3d_int_z", "sfc_hflux_pme"]

```

That is, we add those 4 components. I would give that a go.

(Note that I tried to quickly test this with the intake catalog and had errors loading the data – @CharlesTurner might be able to cross-check if he gets the same errors?)

Also, I would consider using a newer run - possibly one of the IAF cycles - to look at this diagnostic (depending on what you need it for)?

---

<div class="post-metadata">

**Author:** ![sb4233](https://avatars.discourse-cdn.com/v4/letter/s/85f322/32.png) [@sb4233](https://forum.access-hive.org.au/u/sb4233)\
**Post date:** [26 March 2025 22:07 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350/4 "2025-03-26T22:07:19Z")

</div>

Thank you!! this is very helpful.

I have been trying to look at the heat budget terms over Indonesian seas based on [mom-ocean.github.io/assets/pdfs/ESM2M\_heat\_budget.pdf](https://mom-ocean.github.io/assets/pdfs/ESM2M_heat_budget.pdf). Now that I checked this doc carefully it does mention `net surface heat flux = radiative + turbulent + mass heat + frazil` (and subsequent variable names in section 1.3.3).

The reason I didn’t use the IAF runs is because not all the variables, required for closing the heat budget, are saved. Just the main ones like `temp_xflux_adv` , `temp_yflux_adv` etc. Please let me know if I am wrong.

So I had no choice but to use the RYF runs, which has all the heat budget variables available.

Also just curious to know, why ‘`temp_zflux_adv`’ is not saved in any of the ACCESS runs?

---

<div class="post-metadata">

**Author:** ![AndyHoggANU](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/andyhogganu/32/43_2.png) [@AndyHoggANU](https://forum.access-hive.org.au/u/AndyHoggANU)\
**Post date:** [27 March 2025 01:21 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350/5 "2025-03-27T01:21:08Z")

</div>

I think cycle4 might have some monthly temperature fluxes saved. Will try to check it out.

In the meantime, based on your questions it seems like we need a cosima-recipe for the heat budget calculation (I had a quick look, but I can’t see an existing recipe). Maybe @Hangyum has something he could post which might be a starting point?

---

<div class="post-metadata">

**Author:** ![Hangyum](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/hangyum/32/561_2.png) [@Hangyum](https://forum.access-hive.org.au/u/Hangyum)\
**Post date:** [27 March 2025 23:21 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350/6 "2025-03-27T23:21:24Z")

</div>

Yes, I will start a recipe for the heat budget calculation.

---

<div class="post-metadata">

**Author:** ![CharlesTurner](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/charlesturner/32/2518_2.png) [@CharlesTurner](https://forum.access-hive.org.au/u/CharlesTurner)\
**Post date:** [30 March 2025 23:15 UTC](https://forum.access-hive.org.au/t/why-is-there-only-2-years-of-data-for-net-sfc-heating-in-access-om2-ryf9091-runs/4350/7 "2025-03-30T23:15:30Z")

</div>

Sorry Andy, only just looking at this now.

I’ve had a look at the ESM Datastore for the catalog, and it looks like for whatever reason, the model stopped writing `net_sfc_heating` out at that time step?

```python
>>> import intake

>>> cat = intake.cat.access_nri
>>> esm_ds = cat['01deg_jra55v13_ryf9091']
>>> esm_ds.search(variable='net_sfc_heating').df.path

0 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output000/ocean/ocean_month.nc
1 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output001/ocean/ocean_month.nc
2 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output002/ocean/ocean_month.nc
3 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output003/ocean/ocean_month.nc
4 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output004/ocean/ocean_month.nc
5 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output005/ocean/ocean_month.nc
6 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output006/ocean/ocean_month.nc
7 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output007/ocean/ocean_month.nc
Name: path, dtype: object

# Did something funny happen with ocean_month files?

>>> esm_ds.search(file_id='ocean_month').df.path.head(20)

0 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output000/ocean/ocean_month.nc
1 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output001/ocean/ocean_month.nc
2 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output002/ocean/ocean_month.nc
3 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output003/ocean/ocean_month.nc
4 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output004/ocean/ocean_month.nc
5 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output005/ocean/ocean_month.nc
6 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output006/ocean/ocean_month.nc
7 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output007/ocean/ocean_month.nc
8 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output008/ocean/ocean_month.nc
9 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output009/ocean/ocean_month.nc
10 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output010/ocean/ocean_month.nc
11 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output011/ocean/ocean_month.nc
12 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output012/ocean/ocean_month.nc
13 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output013/ocean/ocean_month.nc
14 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output014/ocean/ocean_month.nc
15 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output015/ocean/ocean_month.nc
16 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output016/ocean/ocean_month.nc
17 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output017/ocean/ocean_month.nc
18 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output018/ocean/ocean_month.nc
19 /g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output019/ocean/ocean_month.nc
Name: path, dtype: object

# Nope - so let's look at the files manually (ie. is this an intake problem)

>>> import xarray as xr

>>> ds1 = xr.open_dataset("/g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output007/ocean/ocean_month.nc")
>>> vars1 = [v for v in ds1.variables]
>>> ds2 = xr.open_dataset("/g/data/ik11/outputs/access-om2-01/01deg_jra55v13_ryf9091/output008/ocean/ocean_month.nc")
>>> vars2 = [v for v in ds.variables]

>>> set(vars1) - set(vars2)
{'net_sfc_heating'}

```

So it looks like `net_sfc_heating` output was turned off to me?

I can load that data just fine though:

```python
>>> from dask.distributed import Client
>>> client = Client(threads_per_worker=1)
>>> esm_ds.search(variable='net_sfc_heating').to_dask()
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
/g/data/xp65/public/apps/med_conda/envs/analysis3-25.02/lib/python3.11/site-packages/intake_esm/source.py:82: FutureWarning: In a future version of xarray decode_timedelta will default to False rather than None. To silence this warning, set decode_timedelta to True, False, or a 'CFTimedeltaCoder' instance.
  ds = xr.open_dataset(url, **xarray_open_kwargs)
<xarray.Dataset> Size: 1GB
Dimensions: (time: 33, yt_ocean: 2700, xt_ocean: 3600)
Coordinates:
  * xt_ocean (xt_ocean) float64 29kB -279.9 -279.8 ... 79.85 79.95
  * yt_ocean (yt_ocean) float64 22kB -81.11 -81.07 ... 89.94 89.98
  * time (time) object 264B 1900-01-16 12:00:00 ... 1902-09-16 00...
Data variables:
    net_sfc_heating (time, yt_ocean, xt_ocean) float32 1GB dask.array<chunksize=(1, 675, 900), meta=np.ndarray>
Attributes: (12/16)
    filename: ocean_month.nc
    title: ACCESS-OM2-01
    grid_type: mosaic
    grid_tile: 1
    intake_esm_vars: ['net_sfc_heating']
    intake_esm_attrs:filename: ocean_month.nc
    ... ...
    intake_esm_attrs:variable_standard_name: ,,,,,,sea_surface_height_above_...
    intake_esm_attrs:variable_cell_methods: ,,,,,,time: mean,time: mean,tim...
    intake_esm_attrs:variable_units: degrees_E,degrees_N,days since ...
    intake_esm_attrs:realm: ocean
    intake_esm_attrs:_data_format_: netcdf
    intake_esm_dataset_key: ocean_month.1mon

```
