Skip to content

Commit

Permalink
Revert "fix source wise for indexmorpher"
Browse files Browse the repository at this point in the history
This reverts commit 3e03934.
  • Loading branch information
hammannr committed Dec 11, 2024
1 parent 3e03934 commit 5b2b684
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ likelihood_config:
- name: science_run
default_source_class: alea.template_source.TemplateSource
likelihood_type: blueice.likelihood.UnbinnedLogLikelihood
source_wise_interpolation: false
likelihood_config: {"morpher": "IndexMorpher"}
analysis_space:
- cs1: np.arange(0, 102, 2)
Expand Down
8 changes: 1 addition & 7 deletions alea/models/blueice_extended_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,16 +296,9 @@ def _process_blueice_config(self, config, template_folder_list):
# get blueice likelihood_config if it's given
likelihood_config = config.get("likelihood_config", None)

source_wise_interpolation = config.get("source_wise_interpolation", True)

if source_wise_interpolation and likelihood_config:
if likelihood_config.get("morpher") == "IndexMorpher":
raise ValueError("Source-wise interpolation is not yet supported for IndexMorpher.")

blueice_config = {
"pdf_base_config": pdf_base_config,
"likelihood_config": likelihood_config,
"source_wise_interpolation": source_wise_interpolation,
}
return blueice_config

Expand Down Expand Up @@ -342,6 +335,7 @@ def _build_ll_from_config(
# Iterate through each likelihood term in the configuration
for config in likelihood_config["likelihood_terms"]:
blueice_config = self._process_blueice_config(config, template_folder_list)
blueice_config.setdefault("source_wise_interpolation", True)

likelihood_class = cast(Callable, locate(config["likelihood_type"]))
if likelihood_class is None:
Expand Down

0 comments on commit 5b2b684

Please sign in to comment.