# Cookbook database on highres model, how can I run though it faster?

**URL:** <https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577>\
**Category:** Technical\
**Created:** [21 March 2023 23:43 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577 "2023-03-21T23:43:58Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![ars599](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/ars599/32/821_2.png) [@ars599](https://forum.access-hive.org.au/u/ars599)\
**Post date:** [21 March 2023 23:43 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577/1 "2023-03-21T23:43:58Z")

</div>

Hi there,

I am trying to use cm2 1degree and 1/4degree data:

# CM2 database

session\_CM2 = cc.database.create\_session(‘/g/data/p73/archive/non-CMIP/ACCESS-CM2/CM2.db’)  
expt\_CM2\_025 = ‘cj877’  
expt\_CM2\_1 = ‘bz687’

Then I need to calculate MOC, apply EOF on the Pacific region SST and save the data. However, that took me more than an hour, and I failed. Is there a smart way to do it?

Regards,

Arnold

---

<div class="post-metadata">

**Author:** ![ars599](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/ars599/32/821_2.png) [@ars599](https://forum.access-hive.org.au/u/ars599)\
**Post date:** [23 March 2023 13:59 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577/2 "2023-03-23T13:59:47Z")

</div>

Second OM2 database-related issue:

session\_OM2 = cc.database.create\_session(‘/g/data/ik11/databases/cosima\_master.db’)  
expt\_OM2\_025 = ‘025deg\_jra55\_ryf9091\_gadi’  
expt\_OM2\_1 = ‘1deg\_jra55\_ryf9091\_gadi’

vName=‘u’  
u50\_OM2\_025 = cc.querying.getvar(expt=expt\_OM2\_025, variable=vName,  
session=session\_OM2, frequency=‘1 monthly’,  
attrs={‘cell\_methods’: ‘time: mean’},  
start\_time=‘1951-01-01 00:00:00’,  
end\_time=‘2000-12-31 00:00:00’)

somehow I got this error message:  
“VariableNotFoundError: No files were found containing ‘u’ in the ‘025deg\_jra55\_ryf9091\_gadi’ experiment”

Not sure where did wrong. I can find u is under ocean.nc …

---

<div class="post-metadata">

**Author:** ![Aidan](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/aidan/32/42_2.png) [@Aidan](https://forum.access-hive.org.au/u/Aidan)\
**Post date:** [23 March 2023 23:16 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577/3 "2023-03-23T23:16:10Z")

</div>

> [@ars599](#):
>
> I am trying to use cm2 1degree and 1/4degree data

There are some issues with the CM2 data that make it very slow to process, and I believe it has to do with the number and structure of the variables, but @dougiesquire knows more of the detail so he might be able to tell you more.

---

<div class="post-metadata">

**Author:** ![rmholmes](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/rmholmes/32/117_2.png) [@rmholmes](https://forum.access-hive.org.au/u/rmholmes)\
**Post date:** [23 March 2023 23:31 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577/4 "2023-03-23T23:31:12Z")

</div>

> [@ars599](#):
>
> Not sure where did wrong. I can find u is under ocean.nc …

`ocean.nc` is yearly output so this call won’t pick it up due to the `frequency` input. It looks like there might not be any monthly output for `u` in this run. It’s RYF, so if you want the data feel free to extend the run (or I can do it if you need it)?

---

<div class="post-metadata">

**Author:** ![clairecarouge](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/clairecarouge/32/380_2.png) [@clairecarouge](https://forum.access-hive.org.au/u/clairecarouge)\
**Post date:** [23 March 2023 23:41 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577/5 "2023-03-23T23:41:16Z")

</div>

Arnold, I don’t know if you know about it but the COSIMA Cookbook also has a [Data Explorer](https://cosima-recipes.readthedocs.io/en/latest/Tutorials/Using_Explorer_tools.html#Exploring-a-Cookbook-Database) that allows you to find which experiments have what outputs.

This way you can either check that the experiment you are interested in has the variables you need. Or inversely, which experiments have the variables you need.

---

<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:** [24 March 2023 00:11 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577/6 "2023-03-24T00:11:53Z")

</div>

> [@Aidan](#):
>
> There are some issues with the CM2 data that make it very slow to process, and I believe it has to do with the number and structure of the variables, but @dougiesquire knows more of the detail so he might be able to tell you more.

Yes, there are issues with those CM2 files that make them very slow to process. There’s some info [here](https://github.com/ACCESS-NRI/ACCESS-MED/issues/2). The issue is not with the cookbook.

We’re working on a way to make those files more usable, but it’s not ready yet - hopefully soon though!

---

<div class="post-metadata">

**Author:** ![ars599](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.access-hive.org.au/ars599/32/821_2.png) [@ars599](https://forum.access-hive.org.au/u/ars599)\
**Post date:** [28 March 2023 06:44 UTC](https://forum.access-hive.org.au/t/cookbook-database-on-highres-model-how-can-i-run-though-it-faster/577/7 "2023-03-28T06:44:41Z")

</div>

Hmmmmm, the CM2 database contains CICE, ATM, and OCN. SST can be found in both CICE and ocean models. However, to obtain data from the atmosphere model, one needs to deal with the stash code and map it to the data, which can take a considerable amount of time. Thank you, guys!
