Modular plotting - #11
Merged
Merged
Conversation
maadcoen
force-pushed
the
modulare_plotting
branch
from
June 21, 2024 14:38
cc61c3f to
d8113f8
Compare
Merged
JanvanderLinden
approved these changes
Jun 24, 2024
JanvanderLinden
left a comment
Collaborator
There was a problem hiding this comment.
Nice, looks good for me. Presumably you tested it?
From the modification of the original plot_2d function it also looks like there is no change needed for users when calling a default 2d plotting routine for now?
Author
|
so I tried running it and it works to make normal 2d plots. I cannot exclude problems if one tries to apply several command line options to customise the plot more, to be honest. |
JulesVandenbroeck
added a commit
that referenced
this pull request
Jul 9, 2024
* Draft for store parts modifiers. * Minor corrections. * Update upstream order. * Add draft for markdown linting. * Run docs linting and show errors, but don't fail ci. * Fix docs version. * Fix bug in CreateDatacards task when processing data datasets. * Hotfix grid proxy fallback location in htcondor jobs. * feat: Add error handling for invalid LHEPdfWeight values The code changes add error handling for cases where the number of LHEPdfWeights is not equal to 101 or 103. If all LHEPdfWeights are invalid, a warning is logged and a ones array is returned for the pdf weights. If some LHEPdfWeights are invalid, an exception is raised with the details of the invalid values. * bug fix: was trying to convert jagged arrays to numpy views * Update upstream law. * Hotfix lfn resolution from local resources. * Allow columns to be skipped in 'keep_columns' definitions. * Typos. * De-nest and cleanup pdf.py. * De-nest and cleanup scale.py. * Add MANIFEST file. * Simplify flat_np_view. * fix issue with MergeMlEvents * Fix tests. * add process to lookup table only if process has a cross section * fix inputs * expanded api docs for `PlotMLResults` * Fix typo in cms btag weight producer. * Fix merging of reduced events for single-file datasets. * final commit :) * Improve process settings handling. * Fix typehint. * Doc string. * Update upstream law. * docs: update README.md [skip ci] * docs: update .all-contributorsrc [skip ci] * Fix fill hist (#6) Co-authored-by: Marcel Rieger <riga@users.noreply.github.com> * Fix hist filling. * Fix axis check. * Draft for hist hooks and plot parts. * sort objects when passing wildcards * using ceil instead of int (latter creates problems for integer binning starting at 1 or above) * .copy not defined for awkward arrays. Use ak.copy instead * .copy not defined for awkward arrays. Use ak.copy instead (columnflow#474) * Update columnflow/tasks/cutflow.py Co-authored-by: Mathis Frahm <49306645+mafrahm@users.noreply.github.com> * Update columnflow/tasks/cutflow.py Co-authored-by: Mathis Frahm <49306645+mafrahm@users.noreply.github.com> * Update columnflow/tasks/cutflow.py Co-authored-by: Mathis Frahm <49306645+mafrahm@users.noreply.github.com> * Add setup banner. * Linting the docs :) (columnflow#476) * update markdownlint configuration to allow specific elements and punctuation used in the README files * linting the docs * linting the ml docs and changing the heading structure in order to not have multiple headers * removed unneded files (cms api was moved to a seperate folder, but old files were not removed) * added plotting toctree for the docs * fix sphinx warnings * remove redundent links * replaced link to old cf repo (uhh-cms) * Add code coverage for test_config_util, test_task_parameters and test_plotting * one-sentence-per-line * local docs scan * Enable docs linting in ci. * Fi CI warnings. * BUG: `tenacity` version 8.4.0 doesn't work (columnflow#475) * Update dependencies to fix tenacity to the version 8.3.0 * Update sandboxes/cf.txt Co-authored-by: Marcel Rieger <riga@users.noreply.github.com> --------- Co-authored-by: Marcel Rieger <riga@users.noreply.github.com> * Banner update. * Verbose output in create_analysis script. * Fix upper/lower case polyfills in create_analysis. * Modular plotting (#11) * make code more modular by allowing to use pre-existing figure and axes * modularize 2d plotting function * Cat per process plot (#12) plot function that plots different categories for single process * Migration matrix plot (#13) * code to plot migrations with also purity and reco efficiency * Safe selectionresult ghent (#10) add checks to ensure proper event and object masks * fixed mistakes in dz, dxy, ans etSC cuts (#17) --------- Co-authored-by: Marcel R. <github.riga@icloud.com> Co-authored-by: Marcel Rieger <riga@users.noreply.github.com> Co-authored-by: Maarten De Coen <52047931+maadcoen@users.noreply.github.com> Co-authored-by: Johanna Matthiesen <jomatthi@physnet.uni-hamburg.de> Co-authored-by: haddadanas <hhhaaanas@gmail.com> Co-authored-by: Anas <103462379+haddadanas@users.noreply.github.com> Co-authored-by: maadcoen <maarten.de.coen@cern.ch> Co-authored-by: Mathis Frahm <49306645+mafrahm@users.noreply.github.com> Co-authored-by: Nathan Prouvost <nathan.prouvost@gmail.com> Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com> Co-authored-by: Mathis Frahm <mathisfrahm@gmx.de>
This file contains hidden or 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
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.
Made some changes to enhance reusability of some plotting code.