Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Log onto a machine and start a new terminal. Start If at ECMWF, start Metview by simply typing on the command line:

Code Block
languagebash
module swap metview/new
metview &

You will see something like this:

...

Metview's home folder maps to $HOME/metview, so we will copy some data into our new folder (we could also create symlinks).

If at ECMWF, do the following:

Code Block
languagebash
cp -r /home/graphics/cgx/tutorials/metview_intro $HOME/metview/

Otherwise, download the tarball from the parent page and uncompress it into the $HOME/metview folder.

Within Metview's GUI, navigate into the new metview_intro folder and notice then into the 1_intro folder. Notice the new GRIB icon called t_fc.grib.

Simple visualisation

To visualise this data, right-click on its icon and select visualise. You will now see the Display Window. Its toolbars can all be moved, docked, undocked and hidden to suit your preferences. The plot uses a simple default styling. Try the following features from the toolbar:

...

Create a new icon - select Mars Retrieval from the list. Edit the icon and set the following parameters to retrieve relative humidity on a 1x1 degree grid on the standard MARS pressure levels:

ParameterValue
ParamR
Grid1/1

Save the icon, then right-click and Execute it. The icon's title should change colour like this:

...

Icon management: rename this icon to "get_r". Now make a duplicate of the icon and rename that one to "get_t". Edit this new one, change Param to T, save the icon and now directly right-click and Visualise it. The Execute step is performed automatically for you because the data has not yet been retrieved.

Right-click on get_t and choose Save Result to save the GRIB data as a file called my_t.grib in the current directory. There is normally no need to do this unless you plan to use the data outside of this Metview session.

...

Right-click somewhere on the Metview desktop and select Create New Python Script. Edit the new icon to bring up Metview's code editor. You may have to re-arrange your windows slightly, but drop the get_t icon into the code editor. The Python equivalent code is generated, and the result is stored in a variable with the same name as the icon (get_t). Use the mv.write() command as shown in the screenshot, then run the script using the Run button in the editor. Your new GRIB file should appear! You should also be able to run this from the command line the same as any Python script.

...

Right-click somewhere on the Metview desktop and select Create New Icon. From the list, select Geographical View and click OK.. Right-click the new icon and choose Edit. Set the following parameter:

ParameterValue
Map ProjectionPolar Stereographic

and click OK. Now right-click and Visualise this icon. Drop the GRIB file icon (t_fc.grib) into the Display Window to view it in this projection. Zoom controls etc work as normal. You can also right-click and Visualise the GRIB file and then drop the Geographic View icon into the Display Window to apply that view to the data.

...