-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Labels
Description
After initialising a DistributionMaker including the osc.prob3 service with default initialisation arguments (in particular, tomography_type=None) , subsequent changes of the electron fractions (YeI, YeO, YeM) do not lead to reproducible total event counts.
An example code snippet that exposes the issue is
modell = DistributionMaker("IceCube_3y_neutrinos.cfg")
print(modell.params.YeM.value)
verteilung = modell.get_outputs(return_sum=True)[0]
count = verteilung.num_entries
print(count)
modell.params.YeM.value = 0.5 * ureg.dimensionless
print(modell.params.YeM.value)
count = modell.get_outputs(return_sum=True)[0].num_entries
print(count)
modell.params.reset_all()
print(modell.params.YeM.value) # reset to original value
count = modell.get_outputs(return_sum=True)[0].num_entries
print(count) # but count differs
count = modell.get_outputs(return_sum=True)[0].num_entries
print(count) # count remains the same
While the above behaviour can be fixed for example by creating a new Layers instance after
Line 362 in 1637c22
| self.YeI = YeI; self.YeO = YeO; self.YeM = YeM |
self.layers = Layers(self.earth_model, self.detector_depth, self.prop_height) (also requires additionally setting the three attributes in __init__, so that they are available in compute_function), we should probably look into why the modification of an existing Layer's electron fraction seems to go awry (values in self.layers.density).