-
Notifications
You must be signed in to change notification settings - Fork 34
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 plot_vdfdiff to plot_vdf.py #227
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
It can plot differences of VDFs from the same cell of different files, or different cells of the same file.
alhom
reviewed
Mar 20, 2024
alhom
reviewed
Mar 20, 2024
alhom
reviewed
Mar 20, 2024
A useful tool but bloats plot_vdf horrendously. I would suggest either, preferably, adding the diff funcitonality to the existing script, or alternatively splitting this to a different file altogether. (And then pending a proper re-organization of analysator scripts to a more modular approach) |
Split to new plot_vdfdiff file. Useful tool that should be in, but also should be revamped later. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is mostly a copy-and-paste duplication of most of the plot_vdf code, except that it opens two files (or vlsvreader objects), can take two separate lists of cellids and then pairwise iterates through them, extracting the velocity spaces, histogrammizing them and then taking the diff of the extracted histograms.
This avoids all trouble with identifying missing blocks. Also, I suppose it has potential science applications to diff VDFs from different cells or times in their individual plasma frames.
The colour bar is linear instead of logarithmic, and centered around zero by default.
Here's an example plot from a pitch angle diffusion simulation, comparing timestep 0 and timestep 2:
