Skip to content

Commit

Permalink
Merge pull request #216 from AndrewEdmonds11/v6_updates
Browse files Browse the repository at this point in the history
More v6 updates
  • Loading branch information
AndrewEdmonds11 authored Oct 14, 2024
2 parents 50a3217 + 000adea commit f174ed7
Show file tree
Hide file tree
Showing 67 changed files with 337 additions and 183 deletions.
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,9 @@
*~
*.art
*.root
*.log
*.so
*.d
*.pcm
*__pycache__
backing
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,13 @@ Both of these are currently undergoing rapid development. Feel free to use these
Validation scripts and instructions are [here](validation/README.md)

## Previous Versions
The version history of EventNtuple is [here](https://mu2ewiki.fnal.gov/wiki/TrkAna#Version_History_.2F_TrkAna_Musings).
* Special Note: there were major changes going from v5 to v6 and so we have provided a [list of v5 --> v6 changes](doc/v5-to-v6.md) for those with analysis scripts that ran on v5 ntuples
The version history of EventNtuple is [here](https://mu2ewiki.fnal.gov/wiki/EventNtuple).

### Upgrading from v5 to v6
* For analyzers: a list of branch/leaf/name changes is [here](doc/v5-to-v6.md)
* For developers: instructions to update your development area are [here](doc/v5-to-v6_developers.md)

## Other Useful Links

* [Mu2eWiki page](https://mu2ewiki.fnal.gov/wiki/TrkAna)
* [Mu2eWiki page](https://mu2ewiki.fnal.gov/wiki/EventNtuple)
* [tutorial](tutorial/README.md)
* [instructions for developers](https://mu2ewiki.fnal.gov/wiki/TrkAna#For_Developers)
4 changes: 2 additions & 2 deletions doc/ntuplehelper.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# How to get help -- ```ntuplehelper```

On this page, you will learn how to use the [```ntuplehelper```](../../utils/ntuplehelper.py) utility to get more information about what the different branches and leaves are. You will need to be in a TrkAna environment e.g.
On this page, you will learn how to use the [```ntuplehelper```](../../utils/ntuplehelper.py) utility to get more information about what the different branches and leaves are. You will need to be in a EventNtuple environment e.g.

```
mu2einit
muse setup TrkAna
muse setup EventNtuple
```

You can use this utility:
Expand Down
11 changes: 10 additions & 1 deletion doc/v5-to-v6.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Major Changes from v5 to v6

There was a major update when we moved from v5 to v6. Here are tables of changes for you to consult. Note that the same change may appear in multiple tables since it may be important in one area but defined in another. For example, the folder name is defined in fcl but is also important to know in the Tree / Branch / Leaf Changes
There was a major update when we moved from v5 to v6. Here are tables of changes for you to consult. Note that the same change may appear in multiple tables since it may be important in one area but defined in another. For example, the folder name is defined in fcl but is also important to know in the Tree / Branch / Leaf Changes.

Instructions for developers to upgrade their development areas are [here](v5-to-v6_developers.md)

## Tree / Branch / Leaf Changes
| | v5 | v6 | Notes |
Expand Down Expand Up @@ -32,6 +34,12 @@ Many fcl files were renamed, updated, or deleted. New fcl files introduced in v6
| TrkAnaExtracted.fcl | from_mcs-extracted.fcl | for running on mcs "extracted position" datasets, now #includes from_mcs-mockdata.fcl as a base |
| TrkAnaReco_ceSimReco.fcl | from_mcs-ceSimReco.fcl | for running on the output of ceSimReco.fcl |
| TrkAnaRecoEnsemble-Data.fcl | from_mcs-mockdata_noMC.fcl | for running on mock data with no MC information |
| TrkAnaDeM.fcl | only #includes updated | |
| TrkAnaDeMFromDigis.fcl | only #includes updated | |
| TrkAnaLineFromDigis.fcl | only #includes updated | |
| TrkAnaReflections.fcl | only #includes updated | |
| TrkAnaTrigger.fcl | only #includes updated | |
| TrkAnaTriggerFromDigis.fcl | only #includes updated | |
| TrkAnaRecoEnsemble-MC.fcl | deleted | use from_mcs-mockdata.fcl instead|
| TrkAnaReco_mergedKalSeeds.fcl | deleted | all track types in one branch is now the default |
| CrvExpert.fcl | deleted | |
Expand All @@ -40,6 +48,7 @@ Many fcl files were renamed, updated, or deleted. New fcl files introduced in v6
| TrkAnaReco_addStopTgtVDs.fcl | deleted | |
| TrkAnaReco_multipleBestCrv.fcl | deleted | |
| TrkAnaReco_multipleBestCrv_differentThresholds.fcl | deleted | |
| TrkAnaReco_MultipleTrkQual.fcl | deleted | |

## Fcl Parameter Changes
| | v5 | v6 | Notes |
Expand Down
18 changes: 18 additions & 0 deletions doc/v5-to-v6_developers.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Updating your TrkAna v5 area to an EventNtuple v6 area

Rename your own fork on GitHub. Go to settings and change the repository name under "General"

From your working directory before doing ```muse setup```:

```
mv TrkAna/ EventNtuple/
cd EventNtuple/
git remote set-url origin [email protected]:YourUsername/EventNtuple
git remote set-url mu2e https://github.com/Mu2e/EventNtuple
cd ../
rm -rf build/XXX/ # if you like
mu2einit
muse setup
muse build -j4 --mu2eCompactPrint
```

2 changes: 1 addition & 1 deletion fcl/TrkAnaDeM.fcl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Minimal job to run TrkAna on the 'best' downstream electrons. Runs on mcs files
#include "Offline/fcl/minimalMessageService.fcl"
#include "Offline/fcl/standardServices.fcl"
#include "TrkAna/fcl/prolog.fcl"
#include "EventNtuple/fcl/prolog.fcl"

process_name: TADeM
source : { module_type : RootInput }
Expand Down
4 changes: 2 additions & 2 deletions fcl/TrkAnaDeMFromDigis.fcl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Minimal job to reconstructed downstream electrons from digis and analyze the output with TrkAna
# #include this script in a subscript which specifies the database (ie
##include "TrkAna/fcl/TrkAnaDeMFromDigis.fcl"
##include "EventNtuple/fcl/TrkAnaDeMFromDigis.fcl"
#services.DbService.purpose: MDC2020_best
#services.DbService.version: v1_3
#services.DbService.verbose : 2
Expand All @@ -9,7 +9,7 @@
#include "Offline/fcl/standardServices.fcl"
#include "Production/JobConfig/reco/prolog.fcl"
#include "Offline/Mu2eKinKal/fcl/prolog.fcl"
#include "TrkAna/fcl/prolog.fcl"
#include "EventNtuple/fcl/prolog.fcl"

process_name: TADeMDigis
source : { module_type : RootInput }
Expand Down
2 changes: 1 addition & 1 deletion fcl/TrkAnaLineFromDigis.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#include "Offline/fcl/standardServices.fcl"
#include "Production/JobConfig/reco/prolog.fcl"
#include "Offline/Mu2eKinKal/fcl/prolog.fcl"
#include "TrkAna/fcl/prolog.fcl"
#include "EventNtuple/fcl/prolog.fcl"

process_name: TALineDigis
source : { module_type : RootInput }
Expand Down
6 changes: 0 additions & 6 deletions fcl/TrkAnaReco_MultipleTrkQual.fcl

This file was deleted.

2 changes: 1 addition & 1 deletion fcl/TrkAnaReflections.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include "Offline/fcl/minimalMessageService.fcl"
#include "Offline/fcl/standardServices.fcl"
#include "Offline/TrkReco/fcl/prolog.fcl"
#include "TrkAna/fcl/prolog.fcl"
#include "EventNtuple/fcl/prolog.fcl"
BEGIN_PROLOG
TAR : {
@table::EventNtupleMaker
Expand Down
2 changes: 1 addition & 1 deletion fcl/TrkAnaTriggerMC.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Run TrkAna on the output of the trigger, including MC truth matching
#
#include "Offline/fcl/standardServices.fcl"
#include "TrkAna/fcl/prolog_trigger.fcl"
#include "EventNtuple/fcl/prolog_trigger.fcl"
process_name : TrkAnaTriggerMC
services : @local::Services.Reco
source : {
Expand Down
2 changes: 1 addition & 1 deletion fcl/TrkAnaTriggerMCFromDigis.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

#include "Offline/CommonMC/fcl/prolog_trigger.fcl"
#include "Production/JobConfig/digitize/prolog.fcl"
#include "TrkAna/fcl/prolog_trigger.fcl"
#include "EventNtuple/fcl/prolog_trigger.fcl"
#include "mu2e_trig_config/test/triggerTest.fcl"
#
# Add MC truth matching for the highP_stopTarg triggers
Expand Down
2 changes: 1 addition & 1 deletion fcl/from_dig-mockdata.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include "Offline/fcl/standardProducers.fcl"
#include "Offline/fcl/standardServices.fcl"
#include "Production/JobConfig/reco/prolog.fcl"
#include "TrkAna/fcl/prolog.fcl"
#include "EventNtuple/fcl/prolog.fcl"

process_name : EventNtuple

Expand Down
2 changes: 1 addition & 1 deletion fcl/from_mcs-ceSimReco.fcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "TrkAna/fcl/from_mcs-mockdata.fcl"
#include "EventNtuple/fcl/from_mcs-mockdata.fcl"

physics.analyzers.EventNtuple.branches : [ @local::DeM ]
physics.analyzers.EventNtuple.FillTriggerInfo : false
Expand Down
3 changes: 1 addition & 2 deletions fcl/from_mcs-extracted.fcl
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
#include "TrkAna/fcl/from_mcs-mockdata.fcl"
#include "EventNtuple/fcl/from_mcs-mockdata.fcl"

physics.EventNtuplePath : [ @sequence::EventNtuple.PathExt ] # path for extracted position cosmics
physics.analyzers.EventNtuple.branches : [ @local::Ext ]
physics.analyzers.EventNtuple.FitType : KinematicLine

services.GeometryService.inputFile: "Production/JobConfig/cosmic/geom_cosmic_extracted.txt"
services.TFileService.fileName: "nts.owner.trkanaextracted-reco.version.sequencer.root"
2 changes: 1 addition & 1 deletion fcl/from_mcs-mixed.fcl
Original file line number Diff line number Diff line change
@@ -1 +1 @@
#include "TrkAna/fcl/from_mcs-primary.fcl"
#include "EventNtuple/fcl/from_mcs-primary.fcl"
2 changes: 1 addition & 1 deletion fcl/from_mcs-mockdata.fcl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "Offline/fcl/minimalMessageService.fcl"
#include "Offline/fcl/standardProducers.fcl"
#include "Offline/fcl/standardServices.fcl"
#include "TrkAna/fcl/prolog.fcl"
#include "EventNtuple/fcl/prolog.fcl"

process_name : EventNtuple

Expand Down
2 changes: 1 addition & 1 deletion fcl/from_mcs-mockdata_noMC.fcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "TrkAna/fcl/from_mcs-mockdata.fcl"
#include "EventNtuple/fcl/from_mcs-mockdata.fcl"

physics.analyzers.EventNtuple.FillMCInfo : false

Expand Down
2 changes: 1 addition & 1 deletion fcl/from_mcs-mockdata_selectorExample.fcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "TrkAna/fcl/from_mcs-mockdata.fcl"
#include "EventNtuple/fcl/from_mcs-mockdata.fcl"

# a simple selector is used here, but any selector implemented as a tool can be used
physics.producers.MergeKKAll.Selector : {
Expand Down
2 changes: 1 addition & 1 deletion fcl/from_mcs-mockdata_separateTrkBranches.fcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "TrkAna/fcl/from_mcs-mockdata.fcl"
#include "EventNtuple/fcl/from_mcs-mockdata.fcl"

physics.analyzers.EventNtuple.branches : [ @local::DeM, @local::DeP, @local::UeM, @local::UeP,
@local::DmuM, @local::DmuP, @local::UmuM, @local::UmuP ]
Expand Down
2 changes: 1 addition & 1 deletion fcl/from_mcs-primary.fcl
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
#include "TrkAna/fcl/from_mcs-mockdata.fcl"
#include "EventNtuple/fcl/from_mcs-mockdata.fcl"

physics.EventNtupleEndPath : [ @sequence::EventNtuple.EndPath ] # adds back genCountLogger
2 changes: 1 addition & 1 deletion fcl/prolog.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#include "Offline/CommonMC/fcl/prolog.fcl"
#include "Offline/fcl/TrkCaloDt.fcl"

#include "TrkAna/fcl/prolog_mc_reweighters.fcl"
#include "EventNtuple/fcl/prolog_mc_reweighters.fcl"

BEGIN_PROLOG
# Track quality module
Expand Down
2 changes: 1 addition & 1 deletion fcl/prolog_trigger.fcl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#
# Special configuration base for running TrkAna on trigger fits
#
#include "TrkAna/fcl/prolog.fcl"
#include "EventNtuple/fcl/prolog.fcl"
BEGIN_PROLOG
TrkAnaTrigger : {
TrkAnaTT : {
Expand Down
2 changes: 1 addition & 1 deletion inc/CentralHelixInfo.hh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//
#ifndef CentralHelixInfo_HH
#define CentralHelixInfo_HH
#include "TrkAna/inc/RootVectors.hh"
#include "EventNtuple/inc/RootVectors.hh"
#include "Offline/DataProducts/inc/SurfaceId.hh"
namespace mu2e
{
Expand Down
2 changes: 1 addition & 1 deletion inc/CrvHitInfoMC.hh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace CLHEP {class Hep3Vector; }
#include <vector>
#include "TrkAna/inc/RootVectors.hh"
#include "EventNtuple/inc/RootVectors.hh"

namespace mu2e
{
Expand Down
2 changes: 1 addition & 1 deletion inc/CrvHitInfoReco.hh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// CrvHitInfoReco: information about a cluster of CRV coincidence triplets

#include "TrkAna/inc/RootVectors.hh"
#include "EventNtuple/inc/RootVectors.hh"
#include "Offline/DataProducts/inc/CRVId.hh"
namespace CLHEP {class Hep3Vector; }
#include <vector>
Expand Down
14 changes: 7 additions & 7 deletions inc/CrvInfoHelper.hh
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
//
// Replacement for CRVAnalysis
//
#include "TrkAna/inc/CrvHitInfoReco.hh"
#include "TrkAna/inc/CrvHitInfoMC.hh"
#include "TrkAna/inc/CrvWaveformInfo.hh"
#include "TrkAna/inc/CrvSummaryReco.hh"
#include "TrkAna/inc/CrvSummaryMC.hh"
#include "TrkAna/inc/CrvPlaneInfoMC.hh"
#include "TrkAna/inc/CrvPulseInfoReco.hh"
#include "EventNtuple/inc/CrvHitInfoReco.hh"
#include "EventNtuple/inc/CrvHitInfoMC.hh"
#include "EventNtuple/inc/CrvWaveformInfo.hh"
#include "EventNtuple/inc/CrvSummaryReco.hh"
#include "EventNtuple/inc/CrvSummaryMC.hh"
#include "EventNtuple/inc/CrvPlaneInfoMC.hh"
#include "EventNtuple/inc/CrvPulseInfoReco.hh"
#include "Offline/DataProducts/inc/CRVId.hh"
#include "Offline/RecoDataProducts/inc/CrvCoincidenceCluster.hh"
#include "Offline/RecoDataProducts/inc/CrvRecoPulse.hh"
Expand Down
2 changes: 1 addition & 1 deletion inc/CrvPlaneInfoMC.hh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// CrvPlaneInfoMC: information about the point where the MC trajectory crosses the xz plane of CRV-T

#include "TrkAna/inc/RootVectors.hh"
#include "EventNtuple/inc/RootVectors.hh"
namespace CLHEP {class Hep3Vector; }
#include <vector>

Expand Down
2 changes: 1 addition & 1 deletion inc/CrvPulseInfoReco.hh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#ifndef CrvPulseInfoReco_hh
#define CrvPulseInfoReco_hh

#include "TrkAna/inc/RootVectors.hh"
#include "EventNtuple/inc/RootVectors.hh"
namespace CLHEP {class Hep3Vector; }
#include <vector>

Expand Down
2 changes: 1 addition & 1 deletion inc/CrvSummaryMC.hh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// CrvSummaryMC: branch that provides a summary of the CRV MC true information

#include "TrkAna/inc/RootVectors.hh"
#include "EventNtuple/inc/RootVectors.hh"
namespace CLHEP {class Hep3Vector; }
namespace mu2e
{
Expand Down
4 changes: 2 additions & 2 deletions inc/HelixInfo.hh
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
//
// HelixInfo: struct for HelixSeed info
//
#ifndef TrkAna_HelixInfo_hh
#define TrkAna_HelixInfo_hh
#ifndef EventNtuple_HelixInfo_hh
#define EventNtuple_HelixInfo_hh
namespace mu2e {
struct HelixInfo {
int nch = -1; // number of combo hits potentially used for this helix
Expand Down
20 changes: 10 additions & 10 deletions inc/InfoMCStructHelper.hh
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,23 @@
// Namespace for collecting tools used in MC truth evaluation
// Original author: Dave Brown (LBNL) 8/10/2016
//
#ifndef TrkAna_InfoMCStructHelper_hh
#define TrkAna_InfoMCStructHelper_hh
#ifndef EventNtuple_InfoMCStructHelper_hh
#define EventNtuple_InfoMCStructHelper_hh
#include "fhiclcpp/types/Atom.h"
#include "Offline/RecoDataProducts/inc/StrawHitIndex.hh"
#include "Offline/MCDataProducts/inc/StrawDigiMC.hh"
#include "Offline/MCDataProducts/inc/StepPointMC.hh"
#include "Offline/MCDataProducts/inc/CrvCoincidenceClusterMC.hh"

#include "Offline/RecoDataProducts/inc/KalSeed.hh"
#include "TrkAna/inc/TrkInfoMC.hh"
#include "TrkAna/inc/SimInfo.hh"
#include "TrkAna/inc/TrkStrawHitInfoMC.hh"
#include "TrkAna/inc/CaloClusterInfoMC.hh"
#include "TrkAna/inc/MCStepInfo.hh"
#include "TrkAna/inc/MCStepSummaryInfo.hh"
#include "TrkAna/inc/SurfaceStepInfo.hh"
#include "TrkAna/inc/CrvHitInfoMC.hh"
#include "EventNtuple/inc/TrkInfoMC.hh"
#include "EventNtuple/inc/SimInfo.hh"
#include "EventNtuple/inc/TrkStrawHitInfoMC.hh"
#include "EventNtuple/inc/CaloClusterInfoMC.hh"
#include "EventNtuple/inc/MCStepInfo.hh"
#include "EventNtuple/inc/MCStepSummaryInfo.hh"
#include "EventNtuple/inc/SurfaceStepInfo.hh"
#include "EventNtuple/inc/CrvHitInfoMC.hh"
#include "Offline/RecoDataProducts/inc/KalSeed.hh"
#include "Offline/MCDataProducts/inc/KalSeedMC.hh"
#include "BTrk/BbrGeom/HepPoint.h"
Expand Down
Loading

0 comments on commit f174ed7

Please sign in to comment.