Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Class for Conditioned Spatial Random Fields #130

Merged
merged 31 commits into from
Jan 27, 2021
Merged

Conversation

MuellerSeb
Copy link
Member

@MuellerSeb MuellerSeb commented Jan 13, 2021

Closes: #128, #126

This PR adds a new class for conditioned random fields CondSRF.

This class replaces the conditioning feature of the SRF class, which was limited to Ordinary and Simple kriging.

CondSRF behaves similar to the SRF class, but instead of a covariance model, it takes a kriging class as input. With this kriging class, all conditioning related settings are defined.

During refactoring the RandMeth class, a switch to select the sampling strategy was added.

Note

This change breaks backward compatibility, since conditioned random fields are no longer provided by the SRF class.

@MuellerSeb MuellerSeb added enhancement New feature or request Refactoring Code-Refactoring needed here Performance Performance related stuff. labels Jan 13, 2021
@MuellerSeb MuellerSeb added this to the 1.3 milestone Jan 13, 2021
@MuellerSeb MuellerSeb self-assigned this Jan 13, 2021
@MuellerSeb MuellerSeb requested a review from LSchueler January 13, 2021 22:58
@MuellerSeb
Copy link
Member Author

@LSchueler this is ready for review. ☺️

@MuellerSeb MuellerSeb linked an issue Jan 14, 2021 that may be closed by this pull request
Copy link
Member

@LSchueler LSchueler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, the SRF class is looking soo much nicer now!

Really nice work!

I suggest to import gstools.field.base.Field to gstools.field. The import in one of the examples looks a but ugly.

I just made a few small remarks in the code. I think after you have addressed we are ready to go!!

examples/06_conditioned_fields/00_condition_ensemble.py Outdated Show resolved Hide resolved
examples/06_conditioned_fields/00_condition_ensemble.py Outdated Show resolved Hide resolved
gstools/field/cond_srf.py Show resolved Hide resolved
gstools/field/cond_srf.py Outdated Show resolved Hide resolved
gstools/krige/base.py Outdated Show resolved Hide resolved
gstools/krige/krigesum.pyx Outdated Show resolved Hide resolved
gstools/random/rng.py Show resolved Hide resolved
gstools/random/tools.py Show resolved Hide resolved
Copy link
Member

@LSchueler LSchueler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:-) Found another typo ;-)

But anyway, here is a big thumbs up!

@MuellerSeb MuellerSeb merged commit dedfdae into develop Jan 27, 2021
@MuellerSeb MuellerSeb deleted the cond_srf branch January 27, 2021 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Performance Performance related stuff. Refactoring Code-Refactoring needed here
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[RandMeth] switch to select sampling strategy Systematic artifacts with Exponential field generation
2 participants