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

Refactor, DensityEstimatingSource #5

Merged
merged 9 commits into from
Aug 22, 2016
Merged

Refactor, DensityEstimatingSource #5

merged 9 commits into from
Aug 22, 2016

Conversation

JelleAalbers
Copy link
Owner

This is a refactor to reduce complexity and enhance extensibility. Well, that says pretty much nothing :-)

  • A new Source class DensityEstimatingSource can be used when you want to estimate the PDF from events, but don't want to generate events with the simulate() method. For example, load events from some data file, or run an external Monte Carlo.
  • PDF interpolation / morphing in likelihood space is split off from LogLikelihood into a separate file pdf_morphers.
    • Different morphers (currently GridInterpolator and RadialInterpolator) have their own classes.
    • You can control which morpher is used by the morpher option to thelikelihood_config option of LogLikelihood.
    • Similarly, use morpher_config to set morpher-specific config options.
    • Source and Model are now properly separated, model no longer passes its own self to source.
  • The individual-source parallelization has been removed. I don't suppose we'll need it again: you usually want to generate several models in parallel (for shape uncertainties).
  • Various other private / internal stuff has been moved around.

@coveralls
Copy link

Coverage Status

Coverage increased (+8.0%) to 83.562% when pulling 4de1159 on refactor_ into 1ef5f98 on master.

@coveralls
Copy link

Coverage Status

Coverage increased (+7.9%) to 83.436% when pulling 98dbc17 on refactor_ into 1ef5f98 on master.

Otherwise you have to be very careful when to call which parent init.
Now it's clear init is for setting up config, pdf computation is
separate.
@JelleAalbers JelleAalbers merged commit 3caa744 into master Aug 22, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants