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

Small fix for simulation of pixel bad components #44276

Conversation

ferencek
Copy link
Contributor

@ferencek ferencek commented Feb 29, 2024

PR description:

This PR fixes a bug in the simulation of transiently bad components in the pixel detector which is at the moment enabled in both the MixingModule (configured here and here), where signal SimHits are digitized, and the DataMixer (configured here) where signal and pileup Digis are mixed together (they both have the KillBadFEDChannels switch set toTrue in their SiPixelSimBlock). This PR sets this switch to False for the MixingModule in the premix_stage2 modifier.

PR validation:

No validation done. Impact on physics should be small in standard workflows. However, the impact should be more substantial for 2023 MC where there are sizable holes in pixel L3 and L4 in the second part of the year.

If this PR will be backported please specify to which release cycle the backport is meant for:

Backport to CMSSW_14_0_X needed to include this bugfix in Run 3 MC production

EDIT:

The severity of this PR luckily turns out to be a lot lower than it originally seemed. Since the premix_stage2 modifier already has AddPixelInefficiency set to False in this line, this switch also disables killing of transiently bad components in the MixingModule. In other words, there is no double killing of bad components (KillBadFEDChannels = True is a necessary but not sufficient condition to kill bad components. For this to happen, AddPixelInefficiency also needs to be set to True). Nevertheless, what the KillBadFEDChannels switch still controls is the creation of the PixelFEDChannelCollection in the SiPixelDigitizer. Since this collection is not consumed by anything else, there is no point in wasting memory and computing cycles by producing it. Consequently, this PR is not critical for the Run 3 MC production so backporting it to CMSSW_14_0_X is strictly speaking not needed. Small differences observed in wf 250202.181 likely originate from a modified random number sequence (producing the PixelFEDChannelCollection requires calling a random number generator) which then results in some small differences in the final output.

The commit message was also modified to better reflect the actual impact of the code change.

@cmsbuild
Copy link
Contributor

cmsbuild commented Feb 29, 2024

cms-bot internal usage

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-44276/39294

  • This PR adds an extra 16KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @ferencek for master.

It involves the following packages:

  • SimGeneral/MixingModule (simulation)

@cmsbuild, @mdhildreth, @civanch can you please review it and eventually sign? Thanks.
@fabiocos, @slomeo, @makortel this is something you requested to watch as well.
@sextonkennedy, @antoniovilela, @rappoccio you are the release manager for this.

cms-bot commands are listed here

@sroychow
Copy link
Contributor

please test

@sroychow
Copy link
Contributor

type bug-fix

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 1, 2024

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-e6a164/37835/summary.html
COMMIT: 92863e4
CMSSW: CMSSW_14_1_X_2024-02-29-1100/el8_amd64_gcc12
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/44276/37835/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

@ferencek ferencek changed the title Bugfix for simulation of pixel bad components Small fix for simulation of pixel bad components Mar 2, 2024
…mix stage2

The PixelFEDChannelCollection produced by the MixingModule in premix stage2
is not used at all so there is no point is creating it. Another
PixelFEDChannelCollection is produced later by the DataMixer and propagated
to tracking (after undergoing DigiToRaw and RawToDigi steps).
@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 2, 2024

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-44276/39310

  • This PR adds an extra 16KB to repository

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 2, 2024

Pull request #44276 was updated. @cmsbuild, @civanch, @mdhildreth can you please check and sign again.

@ferencek
Copy link
Contributor Author

ferencek commented Mar 2, 2024

The PR title and description have been updated after doing some additional investigation. The good news is that there is no real bug in the simulation of pixel bad components.

@sroychow
Copy link
Contributor

sroychow commented Mar 2, 2024

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 2, 2024

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-e6a164/37863/summary.html
COMMIT: 79272dc
CMSSW: CMSSW_14_1_X_2024-03-02-1100/el8_amd64_gcc12
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/44276/37863/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

@civanch
Copy link
Contributor

civanch commented Mar 5, 2024

@ferencek , what is a bit worrying to me that explanation of History change due to this fix does not work for Run3 WFs - 2023 should be somehow affected. Instead only Run2 WF is affected. I agree that the effect is small for Run2 but am not sure about Run3.

@ferencek
Copy link
Contributor Author

ferencek commented Mar 5, 2024

@civanch, do you maybe know right off the bat some 2023 WFs that should be affected so I could check in more detail. One thing that comes to my mind is that for Run 3 we don't yet have scenarios for transiently bad components included in any of the GTs (payloads are being prepared).

@civanch
Copy link
Contributor

civanch commented Mar 5, 2024

+1

in that case, we may said that the PR is a simple fix, the effect of that will be seen later.

@cmsbuild
Copy link
Contributor

cmsbuild commented Mar 5, 2024

This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @rappoccio, @sextonkennedy, @antoniovilela (and backports should be raised in the release meeting by the corresponding L2)

@antoniovilela
Copy link
Contributor

@ferencek @cms-sw/simulation-l2

A backport is not needed here.

@antoniovilela
Copy link
Contributor

+1

@cmsbuild cmsbuild merged commit 577ac03 into cms-sw:master Mar 5, 2024
11 checks passed
@mmusich
Copy link
Contributor

mmusich commented Mar 5, 2024

One thing that comes to my mind is that for Run 3 we don't yet have scenarios for transiently bad components included in any of the GTs

Is it?

'phase1_2023_realistic_postBPix' : '140X_mcRun3_2023_realistic_postBPix_v3',

this has the simulation of transiently bad components. I haven't checked if it is used in any test workflow. If it doesn't it probably should.

@antoniovilela
Copy link
Contributor

One thing that comes to my mind is that for Run 3 we don't yet have scenarios for transiently bad components included in any of the GTs

Is it?

'phase1_2023_realistic_postBPix' : '140X_mcRun3_2023_realistic_postBPix_v3',

this has the simulation of transiently bad components. I haven't checked if it is used in any test workflow. If it doesn't it probably should.

Is it worth it to open an issue?

@mmusich
Copy link
Contributor

mmusich commented Mar 5, 2024

Is it worth it to open an issue?

Somehow can be part of #41410

@ferencek
Copy link
Contributor Author

ferencek commented Mar 5, 2024

One thing that comes to my mind is that for Run 3 we don't yet have scenarios for transiently bad components included in any of the GTs

Is it?

'phase1_2023_realistic_postBPix' : '140X_mcRun3_2023_realistic_postBPix_v3',

this has the simulation of transiently bad components. I haven't checked if it is used in any test workflow. If it doesn't it probably should.

Indeed, this was queued back in August of last year https://cms-talk.web.cern.ch/t/new-pixel-status-scenarios-and-probabilities-for-2023-mc/28126/1 but I did not expect it to be used in any of the Run 3 wfs since there was no official campaign started yet that would use these payloads. In any case, the point of this PR was not to test status scenarios and probabilities but it unfortunately interferes with them by disabling one call to the random number generator which can then result in test differences which are nothing more than a red herring.

@mmusich
Copy link
Contributor

mmusich commented Mar 5, 2024

I did not expect it to be used in any of the Run 3 wfs since there was no official campaign started yet that would use these payloads.

On the contrary, development conditions should be tested as widely as possible before using them for large official campaigns to avoid surprises later on. I would urge the responsible groups to look into that.

@ferencek ferencek deleted the premix_stage2_KillBadFEDChannels_bugfix branch March 5, 2024 21:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants