Skip to content

Add a new preprocessor to extend the functionality #161

@geek-yang

Description

@geek-yang

Following the suggestions from PR #152, we need a new preprocessor to provide the following options to the user:

  • spatial selection (so selecting a certain spatial extent with lat and lon)
  • regridding
  • apply land/sea mask

Hint for implementation:

  • spatial selection da.sel(lat=slice(20, 30), lon=slice(110, 140))
  • for regridding, we can do simple interpolation with da.interp() or da.interp_like(), and for complex ones with xesmf (e.g. regridder = xe.Regridder(ds, ds_out, "bilinear") and then ds_out = regridder(ds))
  • apply land/sea mask da.where(np.isnan(mask))

And more importantly, as a user, I would need a preprocessor that can deal with NaN in different ways (e.g. interpolation, mean, etc).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions