This is the second week of my summer intern. I continued the development of model-data comparison package. I improved some modules that were developed last week and also added some new modules.
The first improvement is on the unit conversion module. A common situation is that earth scientists may want to do unit conversion in batch mode, so I changed the unit converter so that it can support multiple NetCDF variables simultaneously. Following that, I created a new module called SaveVariablesToFiles that can save multiple result variables to a list of files. I believe the batch processing capability is also very useful for many other modules, such as regrid, spatial subset etc. I can extent this work to those modules easily.
My major work in this week is to improve regrid module. Regrid seems an extremely important function for model output comparison as different model outputs need to line up before any comparison work can be done. The regrid module I developed last week needs users to specify either the bounding box or a template file before regridding. However, that needs too many inputs from the users. After talking to my mentors, I modified the module so that it can detect bounding box from the input automatically and users just need to set the latitude/longitude intervals. The big challenge is to handle the jump in 180 degree longitude (form positive to negative). I finally solved this problem with a nice procedure.
Another improvement to regrid is to add support for NetCDF variables with curvilinear grids. Many curvilinear NetCDF variables come without bound definition (define the extent of each cell). However, the regrid function needs bound definition to do resampling. Most of current regrid procedures cannot handle this issue. I developed a procedure to create bounds automatically for curvilinear NetCDF variables before regridding. Again, the jump in 180 degree longitude is properly handled. Now the regridding can support both rectangular and curvilinear grids.
A new module I created this week is spatial subset module. Current Vistrails/UV-CDAT only supports fixed region spatial subsetting. With the new module, earth scientist can do spatial subsetting by any user-defined mask (with any shape).
In addition to the the development, I took part in a teleconference today (Friday). The major goal of this conference is to solicit needs//real science scenarios from earth scientist. They gave us quite a few suggestions during today’s meeting. I’ll talk with my mentors later on to see how to incorporate there suggestions into our work.