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

write/read beam spot in a standalone setup #364

Merged
merged 4 commits into from
Oct 8, 2021

Conversation

slava77
Copy link
Collaborator

@slava77 slava77 commented Oct 8, 2021

The file version is updated to v6.
The read/write code should be backward compatible with the older versions 4 (before the masks) and 5.

I made a test file 11834.0_TTbar_14TeV+2021/AVE_50_BX01_25ns/memoryFile.fv6.default.211007-652f30c.bin
but I did not try to run the standalone validation on this yet.

@mmasciov
Copy link
Collaborator

mmasciov commented Oct 8, 2021

@slava77 will be testing it in the coming hours, and will post here a validation.

@mmasciov
Copy link
Collaborator

mmasciov commented Oct 8, 2021

I have done couple of tests, printing beamspot information in "quality_filter_layers" from standalone validation (using 11834.0_TTbar_14TeV+2021/AVE_50_BX01_25ns/memoryFile.fv6.default.211007-652f30c.bin, after PR #364) and from within CMSSW (after PR #364 and PR trackreco/cmssw#54), getting different answers:

[In mkFit/MkStdSeqs.cc:
void quality_filter_layers(TrackVec & tracks, const BeamSpot &bspot)
{
std::cout << std::endl << "Beamspot: " << bspot.x << " " << bspot.y << " " << bspot.z << " " << bspot.sigmaZ << " " << bspot.beamWidthX << " " << bspot.beamWidthY << " " << bspot.dxdz << " " << bspot.dydz <<std::endl << std::endl;]

  • Standalone setup:
    • Beamspot: 0.0107569 3.35973 0.000796955 0.000812358 0 0 0 0
  • CMSSW setup:
    • Beamspot: 0.0107569 0.0417208 -0.0316298 3.35973 0.000796955 0.000812358 -2.57008e-07 1.94795e-06

--> Beamspot information does not appear to be correctly written and/or read in standalone setup.

@slava77
Copy link
Collaborator Author

slava77 commented Oct 8, 2021

@mmasciov
please try with memoryFile.fv6.default.211008-a7daaeb.bin and an update in this PR.

@osschar
Copy link
Collaborator

osschar commented Oct 8, 2021

Strange ... sorry about this :(

@mmasciov
Copy link
Collaborator

mmasciov commented Oct 8, 2021

@mmasciov please try with memoryFile.fv6.default.211008-a7daaeb.bin and an update in this PR.

Just for history: this seems not sufficient to fix the issue in the standalone setup.

@slava77
Copy link
Collaborator Author

slava77 commented Oct 8, 2021

After looking closer on the writer side, there is one bug on the trackingNtuple side: bsp_z is buggy and contains bs.x.

This, however doesn't solve the problem with the bin file read/write.

.. not sure I want to dig deeper now, perhaps we can save this by hardcoding the Run3 MC default in the default construction of the BeamSpot?

@slava77
Copy link
Collaborator Author

slava77 commented Oct 8, 2021

Based on one event check, the writing part is correct.

There is apparently a shift of 2 words during reading in a setup where the CMSSW tracks are skipped.
@mmasciov please check one more time (either of the .bin files should be OK)

@mmasciov
Copy link
Collaborator

mmasciov commented Oct 8, 2021

@slava77 Thanks!
Now we can get the correct beamspot information in standalone:
Beamspot: 0.0107569 0.0417208 0.0107569 3.35973 0.000796955 0.000812358 0 0

I believe this is therefore ready to be merged.

@mmasciov mmasciov merged commit 1981417 into trackreco:devel Oct 8, 2021
@slava77
Copy link
Collaborator Author

slava77 commented Oct 8, 2021

to match this PR final commit, I made a limited update to the .bin files: memoryFile.fv6.default.211008-c6b7c67.bin

  • ttbar files have 1K events
  • µ/π gun event files have 10K events

These totals seemed to be good enough for all of the validation purposes and even most of the throughput benchmarks.
A PR to update the baseline inputs is coming soon.

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

Successfully merging this pull request may close these issues.

4 participants