Skip to content

Beta version 1.3

Compare
Choose a tag to compare
@lcorcodilos lcorcodilos released this 06 Jan 22:53
· 233 commits to master since this release

Change log

Collection of changes made from mid-November through December 2020. Highlights are the weight column calculation fix and improved C++ argument matching.

Setup/install

None

Analyzer

  • Add ObjectFromCollection() method that creates a subcollection but for just one object in the originating collection.
  • Fix the correction/weight collection so that only parent nodes are considered in the weight calculation for a node tree. In other words, if the node/processing tree has split, weights calculated in branch A should not affect those in branch B but they should share any weights calculated before the branches diverged.
    --- If one has separate branches, each one needs to have the MakeWeightCols() method called. Default called on ActiveNode but can take other nodes as input. With this in mind, the method also now takes a name to name a group of weights so that duplicate nodes are not created on the separate branches.
    --- Changes for this happened in __checkCorrections() (traversing up the tree), Node class (add back parent attribute), MakeWeightCols() (the naming)
  • Improved C++ argument matching when building a correction.
    --- Will now check against active node columns and not just the base node.
    --- Correction.MakeCall() changed to take a dict as input instead of a list. Keys are the C++ method argument names (as written in the C++ file) and values are the names of the RDataFrame columns that you'd like to use as function arguments. If there are arguments in the C++ method that are not in the dict, TIMBER will automatically try to determine if it matches a column name and will use that when building the call to the C++ method.
  • Added Range() method to analyzer and Node classes to select a subset of data to analyzer. Docs include warning to not use this with ROOT.EnableImplicitMT()

Tools

  • Add s/sqrt(b) plotting to Tools/Plot.py
  • Add function GetStandardFlags() to return list of standard MET filter flags. Used as default flagList for GetFlagString().
  • Change cut and not option defaults in TrigTester.py.
  • Consolidated Cutflow* functions and added "initial" count to be included when producing the cutflow.

Modules

  • Staging JetSmearer.h, JetRecalib.h, fatJetUncertainties.cc, and JetMETinfo.h (includes commented-out bit in common.h)
  • Change Trigger_weight.cc default plateau to -1

Pythonic.h

  • Create Pythonic namespace.
  • Add header guards.
  • Add IsDir() and Execute() functions.
  • Updated naming so all functions are capitalized
  • Add EffLoader.cc module #24

Data

None

Testing

  • Fix tests so AddCorrections() changes work.
  • Fix test_Common.py so it works. Add in actual tests for Cutflow* functions.
  • Add test for Range()

More documentation

  • Changed error for multiple nodes of the same name to a warning.
  • Add transparent logo.
  • Example 1 (examples/ex1.py) now includes example of using Range() and explains to not use ROOT.EnableImplicitMT().

Issues that were addressed

  • Fix file reading from afs
  • Return ActiveNode with SubCollection method.
  • When providing a dict to Node.SetChildren(), the code was checking if the keys of the dict were of type Node. Fixed to check the dict values.
  • In C++ modules, switch int to size_t in for loops.
  • Fix "Library compiling doesn't play nice with periods in TIMBERPATH"
  • Fix TIMBER/data/README.md
  • Implement corr Correction type deduction
  • Fix CompareShapes() so that it works with empty bkgs, signals, and colors correctly.
  • Allow for default arguments when doing C++ clang parsing and automatic calls to correction methods.