Import ECMWF GRIB

Important

It is important to be familiar with the BlenderNC nodetree (PRO mode!) to follow this tutorial, and have completed the previous tutorial: Import ECMWF netCDF.

Some data has been provided by ECMWF, and it is included at the main BlenderNC repository in the path blendernc/test/dataset.

blendernc
└── tests
    └── dataset
        ├── ECMWF_data.grib
        ├── ECMWF_data.nc
        ├── ssh_1995-01.nc
        └── ssh_1995-01.zarr

This example will use the file ECMWF_data.grib, and builds up from the previous tutorial: Import ECMWF netCDF.

Import ECMWF netCDF finished by fixing the colormap, material orientation, and updating the colorbar.

../_images/start_grib_tutorial.png

In this tutorial will explore:

  • reading the same dataset but in grib format,

  • explore some of the BlenderNC user preferences,

  • and visualise two fields from the same dataset.

  1. Let’s change to the grib file, by browsing using the node netCDF Path, higlight in purple.

../_images/select_grib.png

Important

You may need to reselect the variable t2m, however you won’t be able to note any change.

../_images/reselect_variable.png
  1. Select all the nodes except for the datacube Path node, by clicking and draging over the BlenderNC nodetree.

../_images/select_nodes.png
  1. Click shift + D to duplicate the nodes, drag them up, to look like:

../_images/duplicate_nodes.png
  1. Now we will connect the nodes and select a different variable “Medium Cloud cover” (mcc):

../_images/select_diff_variable.png
  1. Continue connecting the nodes until the Range node, here, let’s update the variable range. The cloud variable has a range of [0,1].

../_images/update_range.png
  1. Connect all the nodes:

../_images/connect_all_nodes.png
  1. To make our life easiers, we will rename both images to “Clouds” and “Temperature”. You can rename the images by clicking below the image preview higlighted in cyan.

../_images/change_image_name.png

Note

After you rename the image, you will be able to notice the change of the name in the material (see previous image higligted in orange). Also if you click over the image preview in the Image output node, you will see:

../_images/image_preview.png
  1. Let’s add another sphere, you can simply press shift+D+Return to duplicate the existing sphere. Let’s also rename the spheres to keep track of our workflow.

../_images/rename_sphere.png
  1. Both spheres have the same material, thus we will add a new material, by clicking the icon higlighted in green.

../_images/add_material.png
  1. Let’s change the image used in the material to the image “Clouds”. This is why is useful to change the image and object names.

../_images/change_image.png
  1. Now, we can only see the “Clouds”, in order to have an animation with two fields, we will add an alpha channel to the clouds, by connecting the output of the “Clouds” image texture output to the alpha input of the ``Principal BSDF``(highlighted in magenta).

../_images/add_alpha.png

Note

If you are using Eevee as a Render Engine, you will need to change some the material settings (Click over the material settings, higlighted in cyan):

../_images/material_settings.png

Then select the Blend Mode to Alpha Blend, optionally you can allow Show Backface.

../_images/select_blend_mode.png
  1. After you apply the alpha channel, you should be able to see both spheres:

../_images/alpha_channel.png
  1. We are using the same colormap for both datasets and it’s confusing. We can change the colormap, of the “Clouds” by selecting the clouds object, then change the colormap.

../_images/change_colormap_rain.png

Note

Instead of using the same dataset, now you can experiment by adding another datacube Path node and use a different dataset and animating multiple variables.

If you render the image (press F12), your image should resemble:

../_images/temp_plus_clouds.png