Commit 570948f
committed
Fix per-module channel map slicing in light MC truth generation
adc0 = imod // adc_per_mod * adc_per_mod rounds the module index down as
if it were an ADC index, so every module m > 0 sliced another module's
block of the channel map. The resulting global SiPM indices all fall
below the module's offset, get clamped to -1, and np.take then reads the
last SiPM of the module's light_dat for every cell: each
mc_truth/light_module{m} (m > 0) row holds one SiPM's truth copied into
all adc_per_mod x n_channels cells (verified bitwise against the paired
LARNDSIM light_dat). Module 0 and the single-dataset (2x2) path are
unaffected, as are the waveforms, which are remapped with the full
channel map in next().
Use adc0 = imod * adc_per_mod so each module slices its own rows.1 parent fcbf815 commit 570948f
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
218 | 218 | | |
219 | 219 | | |
220 | 220 | | |
221 | | - | |
| 221 | + | |
222 | 222 | | |
223 | 223 | | |
224 | 224 | | |
| |||
0 commit comments