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

Feature/combine sd #133

Merged
merged 2 commits into from
Sep 4, 2024
Merged

Feature/combine sd #133

merged 2 commits into from
Sep 4, 2024

Conversation

mdolce8
Copy link
Member

@mdolce8 mdolce8 commented Aug 26, 2024

A new python script to take the output ROOT file from PR #130 (truth_signed_distance_mu_momentum_slices.py) and plot all of those distributions together on a single plot. That is, a single plot of all true signed distance distributions in different slices of muon KE. There are two plots: one for slices of KE of muon at birth (in LAr) and one of the slices of KE of muon entering TMS.

Note: this script uses uproot and matplotlib so user needs to install these via pip install --user <pkg> (and any other dependencies). I made a comment of this at the top of the script.

Here is an example of the plot.
plot_multiple_truth_signed_distances_tms_truth_muon_vs_amuon

… the signed distances for different KEs of the muon.
…ortant note that certain python packages need to be installed by the user to their user install location
@mdolce8 mdolce8 requested review from LiamOS and jdkio August 26, 2024 20:13
@mdolce8 mdolce8 added the enhancement New feature or request label Aug 26, 2024
@mdolce8
Copy link
Member Author

mdolce8 commented Aug 30, 2024

Here is some help on getting the script to work, because several python packages have to be installed. Here is what I needed. Using pip install --user :

matplotlib
packaging
pyparsing
dateutil
uproot 

--user means packages are installed to local area: /nashome/<principal-letter>/${USER}/.local/lib/python3.9/site-packages
In some cases I also needed to --force-reinstall bc python was getting confused (I think bc these packages may be in a global location somewhere).

@LiamOS
Copy link
Member

LiamOS commented Sep 1, 2024

I'll make a note (try) to add matplotlib and uproot to the spack installation so that this Just Works™ on the GPVMs.

Copy link
Member

@LiamOS LiamOS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code seems fine, plots look good 👍

@LiamOS LiamOS merged commit 78ad98a into main Sep 4, 2024
1 check passed
@mdolce8 mdolce8 deleted the feature/combine_SD branch September 25, 2024 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants