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

Error in testDD4hepFilteredViewLevel and testDD4hepFilteredViewGoTo #31604

Closed
silviodonato opened this issue Sep 28, 2020 · 18 comments
Closed

Error in testDD4hepFilteredViewLevel and testDD4hepFilteredViewGoTo #31604

silviodonato opened this issue Sep 28, 2020 · 18 comments

Comments

@silviodonato
Copy link
Contributor

We are getting two errors in the unit test of DetectorDescription/DDCMS in testDD4hepFilteredViewLevel and testDD4hepFilteredViewGoTo since CMSSW_11_2_X_2020-09-27-0000, after having merged #31508.
It turned out that the error is related to the hard-coded level numbers in the unit test (eg. https://github.com/cms-sw/cmssw/blob/master/DetectorDescription/DDCMS/test/DDFilteredView.goto.cppunit.cc#L73).
More details in #31508.
@ianna could you have a look to this issue?

@silviodonato
Copy link
Contributor Author

assign geometry

@cmsbuild
Copy link
Contributor

New categories assigned: geometry

@Dr15Jones,@cvuosalo,@mdhildreth,@makortel,@ianna,@civanch you have been requested to review this Pull request/Issue and eventually sign? Thanks

@cmsbuild
Copy link
Contributor

A new Issue was created by @silviodonato Silvio Donato.

@Dr15Jones, @dpiparo, @silviodonato, @smuzaffar, @makortel, @qliphy can you please review it and eventually sign/assign? Thanks.

cms-bot commands are listed here

@ianna
Copy link
Contributor

ianna commented Sep 28, 2020

@silviodonato - I do not see errors in the PR IB linked here. I'll check in the local area.

@qliphy
Copy link
Contributor

qliphy commented Sep 28, 2020

@ianna You can find more info from #31574
#31574 (comment)

@ianna
Copy link
Contributor

ianna commented Sep 28, 2020

@qliphy - thanks! I've reproduced the error in a local area. The scenario has changed. I'm afraid, the construction order is not guaranteed, so the reference point has shifted.

@ianna
Copy link
Contributor

ianna commented Sep 28, 2020

please, take #31605 that fixes it.

@cvuosalo
Copy link
Contributor

@ianna Can this problem happen again? How can we prevent it?

@ianna
Copy link
Contributor

ianna commented Sep 29, 2020

+1

@cmsbuild
Copy link
Contributor

This issue is fully signed and ready to be closed.

@ianna
Copy link
Contributor

ianna commented Sep 29, 2020

@ianna Can this problem happen again? How can we prevent it?

Good question. Yes, it will definitely happen when the geometry changes: a geo history reflects a child number at a level, but if there is another child created before, the geo history of the first one will shift.

Will it happen if geometry does not change? Yes, when we will start using multiple processes. We cannot guarantee the order of parsing and creation.

@ianna
Copy link
Contributor

ianna commented Sep 29, 2020

Here is an explanation why the unit test failed: two copies of a ZDCtoFP4201 and a ZDCtoFP4202 volumes were added shifting the Tracker from the 4th to the 6th position.
Here is the snapshot of a 2021 geometry tree in the IB:
Screenshot 2020-09-29 at 13 16 24
where it used to be only two copies of a ZDCtoFP420 volume:
Screenshot 2020-09-29 at 13 19 34

@ianna
Copy link
Contributor

ianna commented Sep 30, 2020

@silviodonato - IMHO, this can be closed now. Thanks!

@silviodonato
Copy link
Contributor Author

@ianna I would keep this issue open to remind us that the tests are currently incompatible with geometry changes and multiple processes. If you prefer we can close this issue and open another one. Of course this issue is much less urgent than the DD4HEP migration, but I think it is good to keep a reminder.

@ianna
Copy link
Contributor

ianna commented Sep 30, 2020

@ianna I would keep this issue open to remind us that the tests are currently incompatible with geometry changes and multiple processes. If you prefer we can close this issue and open another one. Of course this issue is much less urgent than the DD4HEP migration, but I think it is good to keep a reminder.

@silviodonato - the unit test does exactly what it is suppose to do - it fails if the geometry changes ;-)

@cvuosalo
Copy link
Contributor

@smuzaffar Could the unit test described in this issue be added to the PR tests for any change to "Geometry" packages?

@silviodonato
Copy link
Contributor Author

Could the unit test described in this issue be added to the PR tests for any change to "Geometry" packages?

@cvuosalo you can include manually this unit test by adding DetectorDescription/DDCMS in the PR test (see http://cms-sw.github.io/cms-bot-cmssw-cmds.html)

test parameters:
addpkg = DetectorDescription/DDCMS

@silviodonato
Copy link
Contributor Author

@ianna I would keep this issue open to remind us that the tests are currently incompatible with geometry changes and multiple processes. If you prefer we can close this issue and open another one. Of course this issue is much less urgent than the DD4HEP migration, but I think it is good to keep a reminder.

@silviodonato - the unit test does exactly what it is suppose to do - it fails if the geometry changes ;-)

Ok, so I assume that you want to keep the test as it is. If somebody wants to change the geometry, s/he needs also to update the unit test. As @cvuosalo pointed out, it would be good to run this test anytime we change a Geometry package

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants