diff --git a/src/pyhf/modifiers/histosys.py b/src/pyhf/modifiers/histosys.py index 5120a84b36..0680018a3b 100644 --- a/src/pyhf/modifiers/histosys.py +++ b/src/pyhf/modifiers/histosys.py @@ -57,19 +57,19 @@ def append(self, key, channel, sample, thismod, defined_samp): ) def finalize(self): - for sample in self.builder_data.values(): - for sample_property in sample.values(): - sample_property["data"]["mask"] = default_backend.concatenate( - sample_property["data"]["mask"] + for modifier in self.builder_data.values(): + for sample in modifier.values(): + sample["data"]["mask"] = default_backend.concatenate( + sample["data"]["mask"] ) - sample_property["data"]["lo_data"] = default_backend.concatenate( - sample_property["data"]["lo_data"] + sample["data"]["lo_data"] = default_backend.concatenate( + sample["data"]["lo_data"] ) - sample_property["data"]["hi_data"] = default_backend.concatenate( - sample_property["data"]["hi_data"] + sample["data"]["hi_data"] = default_backend.concatenate( + sample["data"]["hi_data"] ) - sample_property["data"]["nom_data"] = default_backend.concatenate( - sample_property["data"]["nom_data"] + sample["data"]["nom_data"] = default_backend.concatenate( + sample["data"]["nom_data"] ) return self.builder_data diff --git a/src/pyhf/modifiers/shapesys.py b/src/pyhf/modifiers/shapesys.py index 326e04d932..a137f30b86 100644 --- a/src/pyhf/modifiers/shapesys.py +++ b/src/pyhf/modifiers/shapesys.py @@ -62,16 +62,16 @@ def append(self, key, channel, sample, thismod, defined_samp): ) def finalize(self): - for sample in self.builder_data.values(): - for sample_property in sample.values(): - sample_property["data"]["mask"] = default_backend.concatenate( - sample_property["data"]["mask"] + for modifier in self.builder_data.values(): + for sample in modifier.values(): + sample["data"]["mask"] = default_backend.concatenate( + sample["data"]["mask"] ) - sample_property["data"]["uncrt"] = default_backend.concatenate( - sample_property["data"]["uncrt"] + sample["data"]["uncrt"] = default_backend.concatenate( + sample["data"]["uncrt"] ) - sample_property["data"]["nom_data"] = default_backend.concatenate( - sample_property["data"]["nom_data"] + sample["data"]["nom_data"] = default_backend.concatenate( + sample["data"]["nom_data"] ) return self.builder_data diff --git a/src/pyhf/modifiers/staterror.py b/src/pyhf/modifiers/staterror.py index 23164f6266..7d3a0e5105 100644 --- a/src/pyhf/modifiers/staterror.py +++ b/src/pyhf/modifiers/staterror.py @@ -53,16 +53,16 @@ def append(self, key, channel, sample, thismod, defined_samp): ) def finalize(self): - for sample in self.builder_data.values(): - for sample_property in sample.values(): - sample_property["data"]["mask"] = default_backend.concatenate( - sample_property["data"]["mask"] + for modifier in self.builder_data.values(): + for sample in modifier.values(): + sample["data"]["mask"] = default_backend.concatenate( + sample["data"]["mask"] ) - sample_property["data"]["uncrt"] = default_backend.concatenate( - sample_property["data"]["uncrt"] + sample["data"]["uncrt"] = default_backend.concatenate( + sample["data"]["uncrt"] ) - sample_property["data"]["nom_data"] = default_backend.concatenate( - sample_property["data"]["nom_data"] + sample["data"]["nom_data"] = default_backend.concatenate( + sample["data"]["nom_data"] ) return self.builder_data