UMD-AOSC / UMD-SST

Testbed sea surface analysis system
Apache License 2.0
1 stars 2 forks source link

use BUMP for basic hz correlation #36

Closed travissluka closed 3 years ago

travissluka commented 3 years ago

implement the staticbinit.x application. This will use BUMP to calculate the files needed for a basic horizontal correlation. operator

at this point, the above dirac ctest should produce output fields with increments that are spread out horizontally

travissluka commented 3 years ago

... things that I know will need to be added to the code

loganchen39 commented 3 years ago

@travissluka When I run test for staticbinit.x, it gives the following error. 9: Create BUMP 9: Exception: FieldSet: cannot find field "sea_surface_temperature"

I am not so sure about this staticbinit.x and the background error covariance. Below are my questions.

  1. Does the staticbinit.x read an SST background, i.e. Data/19850101_regridded_sst.nc ? I've provided it in the yaml file in "background" sector. It seems not.
  2. What is the expected output from staticbinit.x? Is it a static Background Error Covariance Matrix in netCDF format? Our analysis grid is 360x180 (=64800), so will the covariance matrix be 64800x64800? I'm checking several materials, still not sure how it's implemented. I'll also discuss with Jim and go check his SODA code about this covariance matrix.

I've updated the code to feature/staticbinit.x branch.

travissluka commented 3 years ago

try this in your staticbinit.yaml

background error:
  covariance model: BUMP
  bump:
    verbosity: main
    datadir: Data
    forced_radii: 1
    method: cor
    new_nicas: 1
    ntry: 3
    prefix: Chen
    resol: 6.0
    mpicom: 2
    rh: 
      sea_surface_temperature: [3000.0e3]
    rv:
      sea_surface_temperature: [1]
    strategy: specific_univariate

a couple of notes there:

You'll have to implement those stubs you added in Fields and Geometry, as that is where BUMP is pulling its information from.

In order to quickly get the code to run without crashing, I added:

    atlas::FieldSet * Geometry::atlasFieldSet() const {
      atlas::FieldSet * fs = new atlas::FieldSet();
      fs->add(atlasFunctionSpace_->lonlat());
      return fs;
    }

and

    void Field:s:setAtlas(atlas::FieldSet *f) const {
      f->add((*atlasFieldSet_)[0]);
    }

clearly not the correct way to it (dangling pointer!).

travissluka commented 3 years ago

also, correct, I don't think the background file is read in and used for anything here