-
Notifications
You must be signed in to change notification settings - Fork 18
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
Add support for reconstruction of "turbine" endcap ecal #88
Conversation
Hi @varnes, can you add link to the k4geo PR? |
Hi @kjvbrt , The corresponding k4geo PR is key4hep/k4geo#347. Best regards, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @varnes ,
thanks a lot for this PR!
Overall it looks good to me, but I think that now it is quite evident from the code that we don't need anymore the tool to have all the members of type dd4hep::DDSegmentation::Segmentation* and of type SegmentationType, because the only place where the segmentations are used is in the function that retrieves the phi and theta extremes of the readout in CaloTowerToolFCCee::retrievePhiThetaExtrema.
I think you can remove all those members, remove the code that retrieves the segmentation in initialize(), and modify retrievePhiThetaExtrema to accept the name of the readout rather than segmentation pointer + type. You can retrieve (temporarily) the segmentation in retrievePhiThetaExtrema.
And basically all code of towersNumbers except the last two lines could go into initialize() to calculate at the beginning of the alg the max theta and phi
If that is clear and you want to do it in this PR, that'd be great for me, otherwise we can postpone it to a separate PR.
Pinging also @BrieucF
Hi @giovannimarchiori , I'm happy in principle with removing the members that are no longer needed, and making the related changes you suggest. However between ICHEP and some vacation, I will not have many free cycles between now and 1 August. -- Erich |
Hi @giovannimarchiori , The segmentation members have been removed, and the other changes you suggested are now implemented. There does still need to be a check that the segmentations are read in correctly (and therefore that phimax and thetamax are set correctly), so I added a set of bool members to keep track of that. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
HI @varnes
thanks a lot for these updates.
There are 2-3 little things to be fixed (one indentation and passing directly a std::string to the CaloTowerToolFCCee::retrievePhiThetaExtrema method). We could also get rid of the booleans m_xxxSegmentationOK and return a StatusCode::Failure when the segmentation is not OK, but we can do it also in a separate PR if you don't have time. I also think I'll have a further shot at this code in a later PR to make it agnostic about the number of calorimeter sub-detectors, so the boolean removal could also go in there.
listPhiMax.reserve(7); | ||
listThetaMax.reserve(7); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note for myself: we might want to refactor this tool in a later PR so that it accepts a list of cell collections and a list of readout names, making it more agnostic of the number of calorimeter sub detectors...
Then this hardcoded 7 numbers would be the length of the list
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @varnes thanks a lot, the PR looks good to me now
Hi @varnes, we merged a PR to fix some tests that were failing due to the EventCounter, could you please rebase your branch (and fix conflicts in case)? Hopefully then all tests will pass and we can merge it. |
Fix conflicts with main branch
Fix conflicts with main branch
Fix conflicts with main branch
Fix conflicts with main branch
Hi @giovannimarchiori , I think it should be OK now... |
Hi @varnes , as you can see from the error messages above, the tests for the nightly builds are failing. If you click on Details you will see that there are 3 tests failing:
=> if you want topoclustering to be run in this test, can you please use the following files so that FCCBASEDIR is not needed?
=> there is a spurious space at the beginning of line 402 in this file, can you please fix it?
I think I had fixed this error in the code I sent you by mail. I have the impression that you put the file runEcalBarrel_ReconstructionTopoClusters_crosstalk.py in the wrong directory - you added it as a new test to RecFCCeeCalorimeter/tests/options/ while it should have been in RecCalorimeter/tests/options/ Please make these 3 changes and push, and check if the tests in the nightlies pass successfully as they should. @BrieucF : if there are still errors after the next attempt, it might be more efficient if we merge the PR and I fix the tests in a separate PR. |
Hi @giovannimarchiori , Would it be best for me to just update these scripts to the versions that are currently in the main branch, or should I take the ones from your email? Thanks, |
This PR is a first pass at including the "turbine" ecal endcap into reconstruction. At the moment only the sliding windows algorithm for creating clusters is supported. In addition to adding code to support this geometry, there was also a change in CaloTowerToolFCCee::CellsIntoTowers, where segmentation->theta(cell.getCellID()) was changed to cellTheta (which was already calculated from the cell position). This change means that the segmentation is no longer required by the CellsIntoTowers method, so it was removed from the list of passed parameters.
Further details about the turbine geometry and the segmentation used for its reconstruction can be found at https://indico.cern.ch/event/1298458/contributions/5977217/attachments/2875296/5035181/FCC_week_June_2024.pdf
This PR is intended to be in concert with a similar PR for k4geo.