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

matrix filling and scaling in data_convert.py #1

Open
czkaiweb opened this issue May 29, 2020 · 2 comments
Open

matrix filling and scaling in data_convert.py #1

czkaiweb opened this issue May 29, 2020 · 2 comments
Assignees

Comments

@czkaiweb
Copy link
Collaborator

Matrix element is got from recHits_energy branch scaled with largest recHits energy:
scale = max(event.recHits_energy)
matrix[dEta,dPhi,channel] = event.recHits_energy[iHit]/scale

Since the hits image is coarser than recHits,
matrix[dEta,dPhi,channel] += event.recHits_energy[iHit]

And the scale should be done after whole matrix have been filled and separated by channel . Maybe Luca could comment on details on scaling.

@lucalavezzo
Copy link
Collaborator

You are right,
matrix[dEta,dPhi,channel] += event.recHits_energy[iHit]
is the right way to do it, and I will divide each entry of the matrix by the max value calculated after it's been filled.
I will fix it and push the updated script. Thanks.

@czkaiweb
Copy link
Collaborator Author

Thanks, Luca.

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

No branches or pull requests

2 participants