tutorials icon indicating copy to clipboard operation
tutorials copied to clipboard

Issue on page /notebooks/tutorials/use_your_own_inventory.html

Open pradeeps31 opened this issue 1 year ago • 7 comments

While running the tutorial for using your own inventory for the third case: start from a completely independent inventory.

Here when trying the code workflow.download_ref_tstars('https://cluster.klima.uni-bremen.de/~oggm/ref_mb_params/oggm_v1.4/RGIV62/CRU/centerlines/qc3/pcp2.5')

The model throws the error saying oggm.workflow does not have the attribute 'download_ref_tstars'. I am using OGGM v1.6.2.

AttributeError: module 'oggm.workflow' has no attribute 'download_ref_tstars' oggm error

pradeeps31 avatar Nov 11 '24 13:11 pradeeps31

Hi, it seams you are using a older version of OGGM (older than v1.6.), as the concept of tstar was removed. Can you check

import oggm
oggm.__version__

to see which version you are currently running!

pat-schmitt avatar Nov 12 '24 07:11 pat-schmitt

Or the other way around: which tutorial are you running? It is possibly an older tutorial version that needs updating.

fmaussion avatar Nov 12 '24 07:11 fmaussion

The OGGM version I am running is 1.6.2. As for the tutorial version, I am unsure about it. I accessed the tutorial page redirected from the OGGM website. I am running the tutorial for "Using your our own glacier inventory with OGGM" Kindly let me know how to find which version of the tutorial that I have used. Below is the link for the tutorial which I used:

https://tutorials.oggm.org/stable/notebooks/tutorials/use_your_own_inventory.html#using-your-our-own-glacier-inventory-with-oggm

pradeeps31 avatar Nov 12 '24 08:11 pradeeps31

The link to the tutorial looks good. Have you checked that you are using the right conda environment with oggm v1.6.2 inside of it?

pat-schmitt avatar Nov 12 '24 08:11 pat-schmitt

I'm running oggm using Anaconda, installed with WSL 2 (Ubuntu 20.04.4 LTS) on a Windows PC. I created the conda environment (with python version 3.11.10) using the "environment.yml" file provided on the oggm installation page:

https://docs.oggm.org/en/stable/installing-oggm.html#

Is there any specific package to be reinstalled or different version can be installed?

pradeeps31 avatar Nov 12 '24 09:11 pradeeps31

Your version of OGGM is fine - the tutorial is not. On the link https://tutorials.oggm.org/stable/notebooks/tutorials/use_your_own_inventory.html#using-your-our-own-glacier-inventory-with-oggm we are still recommending to uncomment the lines where download_ref_tstars is used - this is a mistake on our end: this is not necessary anymore

fmaussion avatar Nov 12 '24 09:11 fmaussion

Thank you for getting back to me so quickly and for your help in clarifying the query. I will go ahead with the tutorial without using the commented lines. This can also be updated regarding the commented section on the tutorial page as well.

pradeeps31 avatar Nov 13 '24 09:11 pradeeps31