Browse Source

Updated README

master
rskuza 2 years ago
parent
commit
696e5503e2
  1. 12
      Code/Scripts/Python Scripts/README.md

12
Code/Scripts/Python Scripts/README.md

@ -24,4 +24,14 @@ You are done!
This script can be used to look inside a root file and see which branches and features it includes. To kick it off, give it a try with: This script can be used to look inside a root file and see which branches and features it includes. To kick it off, give it a try with:
1. `python root_file_inspect.py --file=ROOT_FILE_PATH --regex=.*` 1. `python root_file_inspect.py --file=ROOT_FILE_PATH --regex=.*`
You do not need to set the regex flag but it can be useful if you search for some particular feature.
You do not need to set the regex flag but it can be useful if you search for some particular feature. This script depends on the file `rootio.py`.
### diff_pair_tables_*.py
There are 3 scripts which are prefixed with `diff_pair_tables` and which are very similar but have different use-cases. You can use them as templates whenever you have generated tables by `prettytable` or another library/tool and use them in order to automatically extract the values out of these tables. Then you do not have to type them manually into your code.
## hep_analytics
### package: pathing
The module `aggregate.py` exposes the `PathAggregator` which is very simple and simply builds a path string. For only this reason the class is not very useful but when your directory path setup is more complex and you do not want to manually type out all relevant paths, this class can be easily extended and adapted.
### package: processing
Exposes three modules: `extract`, `transform`, `visualisation`. `extract` exposes the `FileManager` which can be used to extract the relevant features out of the branches of a `root` file. `transform` exposes useful functions like `select_feature` in order to make cuts and `reweight_feature`. Take note that `select_feature` is not the most efficient way of doing cuts, for more efficient usage use the functionality of `uproot3` directly. `visualisation` exposes `reweight_comparing_plot` in order to plot 3 diagrams, two original features and the reweighted feature.
Loading…
Cancel
Save