CliMA / CliMA/ParameterEstimocean.jl

User interface to `Scented` and `Unscented` Kalman inversions

Open
#77 4 comments 0 reactions 0 assignees View on GitHub
🤥 enhancement 🧹 cleanup
Dominant language
Julia
Stars
22
Forks
6
PR merge metrics
No merged PRs in 30d

Description

## Constructors

The user interface to scented and unscented inversions defines two constructor-looking functions `UnscentedKalmanInversion` and `UnscentedKalmanInversionPostprocess`:

https://github.com/CliMA/OceanTurbulenceParameterEstimation.jl/blob/111e4c50fe33d46d9f7061e3256b9b16d70682c5/src/EnsembleKalmanInversions.jl#L204

https://github.com/CliMA/OceanTurbulenceParameterEstimation.jl/blob/111e4c50fe33d46d9f7061e3256b9b16d70682c5/src/EnsembleKalmanInversions.jl#L240

However, there are no objects / structs with names corresponding to those constructors.

Should we tweak the interface a little bit? It looks like there is a type called `Unscented` in `EnsembleKalmanProcesses.jl`:

https://github.com/CliMA/OceanTurbulenceParameterEstimation.jl/blob/111e4c50fe33d46d9f7061e3256b9b16d70682c5/src/EnsembleKalmanInversions.jl#L224

We could have users construct this object and pass to `EnsembleKalmanInversion`. It looks like the constructor for `EnsembleKalmanProcess` is slightly inconsistent for scented vs unscented inversion --- the scented flavor is

https://github.com/CliMA/OceanTurbulenceParameterEstimation.jl/blob/111e4c50fe33d46d9f7061e3256b9b16d70682c5/src/EnsembleKalmanInversions.jl#L155

We can still handle this.

## Post-processing

If we want to keep the post-processing function, I think we should call it something like `postprocess(eki::EnsembleKalmanInversion)`; then we can do the right thing whether `eki` represents a scented or unscented process.

However, another possibility is to give a kwarg to `iterate!`:

```julia
function iterate!(eki; iterations=1, postprocess=false)
```

when users select `postprocess=true`, we post-process results and store them inside the EKI object.

What do others think about these ideas? @adelinehillier @Zhengyu-Huang @navidcy

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the cited constructors and EnsembleKalmanProcess usage in src/EnsembleKalmanInversions.jl, then compare the Unscented type in EnsembleKalmanProcesses.jl. Review the open alternatives for constructing scented and unscented inversions and for post-processing. Done means the project has an agreed, consistent interface and the issue's proposed behavior is resolved.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
backend-api-design
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.