diff --git a/Analyses/CMakeLists.txt b/Analyses/CMakeLists.txt index 2f32b55212..ac3be00e9b 100644 --- a/Analyses/CMakeLists.txt +++ b/Analyses/CMakeLists.txt @@ -599,32 +599,6 @@ cet_build_plugin(StoppedParticlesPrinter art::module Offline::MCDataProducts ) -cet_build_plugin(TrackSummaryDataAnalyzer art::module - REG_SOURCE src/TrackSummaryDataAnalyzer_module.cc - LIBRARIES REG - - - Offline::Mu2eUtilities - Offline::RecoDataProducts -) - -cet_build_plugin(TrackSummaryMCAnalyzer art::module - REG_SOURCE src/TrackSummaryMCAnalyzer_module.cc - LIBRARIES REG - - - Offline::MCDataProducts - Offline::Mu2eUtilities - Offline::RecoDataProducts -) - -cet_build_plugin(TrackSummaryTruthRFSelector art::module - REG_SOURCE src/TrackSummaryTruthRFSelector_module.cc - LIBRARIES REG - art_root_io::TFileService_service - Offline::MCDataProducts - Offline::RecoDataProducts -) cet_build_plugin(TSTrackAna art::module REG_SOURCE src/TSTrackAna_module.cc diff --git a/Analyses/src/TrackSummaryDataAnalyzer_module.cc b/Analyses/src/TrackSummaryDataAnalyzer_module.cc deleted file mode 100644 index 7b0e64bd49..0000000000 --- a/Analyses/src/TrackSummaryDataAnalyzer_module.cc +++ /dev/null @@ -1,66 +0,0 @@ -// TrackSummaryDataAnalyzer: no MC dependencies. -// -// Andrei Gaponenko, 2014 - -#include -#include -#include -#include -#include -#include - -#include "cetlib_except/exception.h" - -#include "CLHEP/Units/PhysicalConstants.h" -#include "CLHEP/Vector/ThreeVector.h" - -#include "messagefacility/MessageLogger/MessageLogger.h" - -#include "art/Framework/Core/EDAnalyzer.h" -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/SubRun.h" -#include "art/Framework/Principal/Handle.h" -#include "art_root_io/TFileService.h" -#include "art/Framework/Services/Registry/ServiceHandle.h" - -#include "Offline/RecoDataProducts/inc/TrackSummary.hh" -#include "Offline/Mu2eUtilities/inc/HistTrackSum.hh" -#include "Offline/Mu2eUtilities/inc/TrackCuts.hh" - -#include "TH1.h" - -namespace mu2e { - - class TrackSummaryDataAnalyzer : public art::EDAnalyzer { - public: - explicit TrackSummaryDataAnalyzer(fhicl::ParameterSet const& pset); - void analyze(const art::Event& evt) override; - private: - TrackCuts an_; - art::InputTag trackInput_; - }; - - //================================================================ - TrackSummaryDataAnalyzer::TrackSummaryDataAnalyzer(const fhicl::ParameterSet& pset) - : art::EDAnalyzer(pset) - , an_(pset.get("cuts"), *art::ServiceHandle(), "") - , trackInput_(pset.get("trackInput")) - {} - - //================================================================ - void TrackSummaryDataAnalyzer::analyze(const art::Event& event) { - auto ih = event.getValidHandle(trackInput_); - for(unsigned i=0; isize(); ++i) { - const auto& track = ih->at(i); - const double weight = 1.; // no weights for real data - if(an_.accepted(track, weight)) { - // Fill more histograms for selected tracks here... - } - } - } - - //================================================================ - -} // namespace mu2e - -DEFINE_ART_MODULE(mu2e::TrackSummaryDataAnalyzer) diff --git a/Analyses/src/TrackSummaryMCAnalyzer_module.cc b/Analyses/src/TrackSummaryMCAnalyzer_module.cc deleted file mode 100644 index 860f6ccbcc..0000000000 --- a/Analyses/src/TrackSummaryMCAnalyzer_module.cc +++ /dev/null @@ -1,120 +0,0 @@ -// TrackSummaryMCAnalyzer: start with tracks. -// Use MC weights and MC process info to evaluate -// backgrounds without double counting. -// -// Andrei Gaponenko, 2014 - -#include -#include -#include -#include -#include -#include - -#include "cetlib_except/exception.h" - -#include "CLHEP/Units/PhysicalConstants.h" -#include "CLHEP/Vector/ThreeVector.h" - -#include "messagefacility/MessageLogger/MessageLogger.h" - -#include "art/Framework/Core/EDAnalyzer.h" -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/SubRun.h" -#include "art/Framework/Principal/Handle.h" -#include "art_root_io/TFileService.h" -#include "art/Framework/Services/Registry/ServiceHandle.h" -#include "canvas/Persistency/Common/FindOneP.h" - -#include "Offline/RecoDataProducts/inc/TrackSummary.hh" -#include "Offline/MCDataProducts/inc/TrackSummaryTruthAssns.hh" -#include "Offline/MCDataProducts/inc/SimParticle.hh" -#include "Offline/MCDataProducts/inc/EventWeight.hh" - -#include "Offline/Mu2eUtilities/inc/HistTrackSum.hh" -#include "Offline/Mu2eUtilities/inc/TrackCuts.hh" - -#include "TH1.h" - -namespace mu2e { - - class TrackSummaryMCAnalyzer : public art::EDAnalyzer { - public: - explicit TrackSummaryMCAnalyzer(fhicl::ParameterSet const& pset); - void analyze(const art::Event& evt) override; - private: - TrackCuts signalAnalysis_; - TrackCuts otherAnalysis_; - TrackCuts fakeAnalysis_; - - art::InputTag trackInput_; - art::InputTag truthMapInput_; - art::InputTag signalSimParticleCollection_; - - std::vector eventWeights_; - }; - - //================================================================ - TrackSummaryMCAnalyzer::TrackSummaryMCAnalyzer(const fhicl::ParameterSet& pset) - : art::EDAnalyzer(pset) - , signalAnalysis_(pset.get("cuts"), *art::ServiceHandle(), "signal") - , otherAnalysis_(pset.get("cuts"), *art::ServiceHandle(), "other") - , fakeAnalysis_(pset.get("cuts"), *art::ServiceHandle(), "fake") - , trackInput_(pset.get("trackInput")) - , truthMapInput_(pset.get("truthMapInput")) - , signalSimParticleCollection_(pset.get("signalSimParticleCollection")) - , eventWeights_(pset.get >("eventWeights")) - {} - - //================================================================ - void TrackSummaryMCAnalyzer::analyze(const art::Event& event) { - // Can't use ValidHandle: redmine #6422 - // auto ih = event.getValidHandle(trackInput_); - art::Handle ih; - event.getByLabel(trackInput_, ih); - - art::Handle signalHandle; - event.getByLabel(signalSimParticleCollection_, signalHandle); - - for(unsigned i=0; isize(); ++i) { - const auto& track = ih->at(i); - - // To evaluate backgrounds without double counting we should - // accept only tracks corresponding to the simulated process of - // interest. - - art::FindOneP f1(ih, event, truthMapInput_); - if(f1.size() == 1) { - const art::Ptr& sim = f1.at(i); - - if(sim.id() == signalHandle.id()) { - - // Use the specified weights. - double weight = 1.; - for (const auto& iwt : eventWeights_ ) { - weight *= event.getValidHandle(iwt)->weight(); - } - - if(signalAnalysis_.accepted(track, weight)) { - // Fill more histograms for selected tracks... - } - - } - else { - // Known MC source, different than the current process of interest - otherAnalysis_.accepted(track, 1.); - } - } - else { - // Fake tracks. (Or no MC info.) - fakeAnalysis_.accepted(track, 1.); - } - - } // for(tracks) - } // analyze() - - //================================================================ - -} // namespace mu2e - -DEFINE_ART_MODULE(mu2e::TrackSummaryMCAnalyzer) diff --git a/Analyses/src/TrackSummaryTruthRFSelector_module.cc b/Analyses/src/TrackSummaryTruthRFSelector_module.cc deleted file mode 100644 index 9136b2cf6e..0000000000 --- a/Analyses/src/TrackSummaryTruthRFSelector_module.cc +++ /dev/null @@ -1,154 +0,0 @@ -// Selector modules picks the "best" match from the many-to-many map -// produced by TrackSummaryTruthMaker. The "RF" selector uses -// the fraction of (common/reco) hits as its FOM. -// -// Andrei Gaponenko, 2014 - -#include -#include -#include -#include -#include -#include - -#include "cetlib_except/exception.h" -#include "messagefacility/MessageLogger/MessageLogger.h" - -#include "art/Framework/Core/EDProducer.h" -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Handle.h" -#include "art_root_io/TFileService.h" -#include "art/Framework/Services/Registry/ServiceHandle.h" - -#include "Offline/RecoDataProducts/inc/TrackSummary.hh" -#include "Offline/MCDataProducts/inc/TrackSummaryTruthAssns.hh" -#include "Offline/MCDataProducts/inc/SimParticle.hh" - -#include "TH1.h" -#include "TH2.h" - -namespace mu2e { - // The "nice" declaration does not work. Similar to redmine #6420 - // double commonHitFraction(typename TrackSummaryTruthAssns::assn_t& p, const TrackSummaryMatchInfo& mi) { - // Spell things out by hand for now - double commonHitFraction(const std::pair, art::Ptr >& p, const TrackSummaryMatchInfo& mi) { - unsigned numRecoHits = p.second->nactive(); - return double(mi.nPrincipal())/double(numRecoHits); - } - - class TrackSummaryTruthRFSelector : public art::EDProducer { - public: - explicit TrackSummaryTruthRFSelector(fhicl::ParameterSet const& pset); - void produce(art::Event& evt) override; - private: - art::InputTag input_; - double cutMinCommonFraction_; - - TH1 *hInputMapSize_; - TH1 *hFinalMapSize_; - - TH2 *hSelection_; - - TH1 *hRFBeforeCut_; - TH1 *hRFFinal_; - - TH1 *hWrongPrincipal_; - TH1 *hNonContrib_; - }; - - //================================================================ - TrackSummaryTruthRFSelector::TrackSummaryTruthRFSelector(const fhicl::ParameterSet& pset) - : art::EDProducer{pset} - , input_(pset.get("TrackTruthInput")) - , cutMinCommonFraction_(pset.get("cutMinCommonFraction")) - { - produces(); - art::ServiceHandle tfs; - - hInputMapSize_ = tfs->make("inputMapSize", "input map size", 50, -0.5, 49.5); - hFinalMapSize_ = tfs->make("finalMapSize", "final map size", 50, -0.5, 49.5); - - hSelection_ = tfs->make("selection", "other vs better", 100, 0., 1.+1.e-6, 100, 0., 1.+1.e-6); - hSelection_->SetOption("colz"); - - hRFBeforeCut_ = tfs->make("matchFracBefore", "(nCommon princ)/nActive, before cut", 100, 0., 1.+1.e-6); - hRFFinal_ = tfs->make("matchFracFinal", "(nCommon princ)/nActive, final", 100, 0., 1.+1.e-6); - - hWrongPrincipal_ = tfs->make("numWrongPrincipal", "nActive - nCommon principal, final", 50, -0.5, 49.5); - hNonContrib_ = tfs->make("nonContrib", "nActive - nCommon any, final", 50, -0.5, 49.5); - } - - //================================================================ - void TrackSummaryTruthRFSelector::produce(art::Event& event) { - std::unique_ptr out(new TrackSummaryTruthAssns()); - auto ih = event.getValidHandle(input_); - - hInputMapSize_->Fill(ih->size()); - - // Select the best match per sim particle. - // Map value is an index into the original Assns - typedef std::map, unsigned> SimBestMatches; - SimBestMatches sm; - for(unsigned i=0; isize(); ++i) { - const art::Ptr part = ih->at(i).first; - const auto iter = sm.find(part); - if(iter == sm.end()) { - sm.insert(std::make_pair(part, i)); - } - else { - const double rfOld = commonHitFraction(ih->at(iter->second), ih->data(iter->second)); - const double rfNew = commonHitFraction(ih->at(i), ih->data(i)); - hSelection_->Fill(std::max(rfOld,rfNew), std::min(rfOld, rfNew)); - if(rfOld < rfNew) { - sm[part] = i; - } - } - } - - // Out of one-per-particle matches, select the best match per - // track to get a one-to-one correspondence. Map value is an - // index into the original Assns - typedef std::map, unsigned> RecoBestMatches; - RecoBestMatches sr; - for(const auto& entry : sm) { - const art::Ptr trk = ih->at(entry.second).second; - const auto iter = sr.find(trk); - if(iter == sr.end()) { - sr.insert(std::make_pair(trk, entry.second)); - } - else { - const double rfOld = commonHitFraction(ih->at(iter->second), ih->data(iter->second)); - const double rfNew = commonHitFraction(ih->at(entry.second), ih->data(entry.second)); - hSelection_->Fill(std::max(rfOld,rfNew), std::min(rfOld, rfNew)); - if(rfOld < rfNew) { - sr[trk] = entry.second; - } - } - } - - // Discard remaining bad matches and fill the output collection - for(const auto& entry: sr) { - const double rf = commonHitFraction(ih->at(entry.second), ih->data(entry.second)); - hRFBeforeCut_->Fill(rf); - if(rf > cutMinCommonFraction_) { - - const art::Ptr& part = ih->at(entry.second).first; - const art::Ptr& trk = ih->at(entry.second).second; - const TrackSummaryMatchInfo& mi = ih->data(entry.second); - - out->addSingle(part, trk, mi); - - hRFFinal_->Fill(rf); - hWrongPrincipal_->Fill(trk->nactive() - mi.nPrincipal()); - hNonContrib_->Fill(trk->nactive() - mi.nAll()); - } - } - - hFinalMapSize_->Fill(out->size()); - - event.put(std::move(out)); - } - -} // namespace mu2e - -DEFINE_ART_MODULE(mu2e::TrackSummaryTruthRFSelector) diff --git a/CMakeLists.txt b/CMakeLists.txt index b30a9665ed..aeecf9d069 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -207,7 +207,6 @@ add_subdirectory(STMMC) add_subdirectory(STMReco) add_subdirectory(StoppingTargetGeom) add_subdirectory(TestTools) -add_subdirectory(TEveEventDisplay) add_subdirectory(TrackerConditions) add_subdirectory(TrackerConfig) add_subdirectory(TrackerGeom) diff --git a/Filters/CMakeLists.txt b/Filters/CMakeLists.txt index 6f76542e44..71feef6ff8 100644 --- a/Filters/CMakeLists.txt +++ b/Filters/CMakeLists.txt @@ -23,7 +23,7 @@ cet_build_plugin(CompressPhysicalVolumes art::module cet_build_plugin(CompressStepPointMCs art::module REG_SOURCE src/CompressStepPointMCs_module.cc - LIBRARIES REG + LIBRARIES REG Offline::MCDataProducts Offline::Mu2eUtilities ) @@ -237,12 +237,6 @@ cet_build_plugin(TrackerStepPointFilter art::module Offline::MCDataProducts ) -cet_build_plugin(TrackSummaryTruthUpdater art::module - REG_SOURCE src/TrackSummaryTruthUpdater_module.cc - LIBRARIES REG - Offline::MCDataProducts -) - cet_build_plugin(TriggerResultsFilter art::module REG_SOURCE src/TriggerResultsFilter_module.cc LIBRARIES REG diff --git a/Filters/src/TrackSummaryTruthUpdater_module.cc b/Filters/src/TrackSummaryTruthUpdater_module.cc deleted file mode 100644 index b0d87a0399..0000000000 --- a/Filters/src/TrackSummaryTruthUpdater_module.cc +++ /dev/null @@ -1,63 +0,0 @@ -// Update TrackSummaryTruthAssns to point to a filtered SimParticle collection -// -// Andrei Gaponenko, 2014 - -#include -#include -#include -#include - -#include "cetlib_except/exception.h" -#include "messagefacility/MessageLogger/MessageLogger.h" - -#include "art/Framework/Core/EDProducer.h" -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Handle.h" - -#include "Offline/MCDataProducts/inc/TrackSummaryTruthAssns.hh" -#include "Offline/MCDataProducts/inc/SimParticleRemapping.hh" - -namespace mu2e { - - class TrackSummaryTruthUpdater : public art::EDProducer { - public: - explicit TrackSummaryTruthUpdater(fhicl::ParameterSet const& pset); - void produce(art::Event& evt) override; - private: - art::InputTag inputTST_; - art::InputTag remapping_; - }; - - //================================================================ - TrackSummaryTruthUpdater::TrackSummaryTruthUpdater(const fhicl::ParameterSet& pset) - : art::EDProducer{pset} - , inputTST_(pset.get("inputTST")) - , remapping_(pset.get("remapping")) - { - produces(); - } - - //================================================================ - void TrackSummaryTruthUpdater::produce(art::Event& event) { - - std::unique_ptr out(new TrackSummaryTruthAssns()); - - auto ih = event.getValidHandle(inputTST_); - auto remap = event.getValidHandle(remapping_); - - // redmine #6420: - // for(typename TrackSummaryTruthAssns::size_type i=0; isize(); ++i) { - // use "unsigned" for now - for(unsigned i=0; isize(); ++i) { - const auto iter = remap->find(ih->at(i).first); - if(iter != remap->end()) { - out->addSingle(iter->second , ih->at(i).second, ih->data(i)); - } - } - - event.put(std::move(out)); - } - -} // namespace mu2e - -DEFINE_ART_MODULE(mu2e::TrackSummaryTruthUpdater) diff --git a/TEveEventDisplay/CMakeLists.txt b/TEveEventDisplay/CMakeLists.txt deleted file mode 100644 index 9e3486a899..0000000000 --- a/TEveEventDisplay/CMakeLists.txt +++ /dev/null @@ -1,64 +0,0 @@ -cet_make_library( - SOURCE - src/Collection_Filler.cc - src/Geom_Interface.cc - src/TEveMu2eCalorimeter.cc - src/TEveMu2eCluster.cc - src/TEveMu2eCRV.cc - src/TEveMu2eCRVEvent.cc - src/TEveMu2eDataInterface.cc - src/TEveMu2eHit.cc - src/TEveMu2eMainWindow.cc - src/TEveMu2eMCInterface.cc - src/TEveMu2eMCTraj.cc - src/TEveMu2eProjectionInterface.cc - src/TEveMu2eStraightTrack.cc - src/TEveMu2eTracker.cc - src/TEveMu2eCustomHelix.cc - LIBRARIES PUBLIC - Offline::ConfigTools - Offline::GeometryService - Offline::GlobalConstantsService - Offline::RecoDataProducts - ROOT::Eve - ROOT::Cling -) - -cet_build_plugin(TEveEventDisplay art::module - REG_SOURCE src/TEveEventDisplay_module.cc - LIBRARIES REG - art_root_io::TFileService_service - Offline::TEveEventDisplay - Offline::TEveEventDisplay_dict - -) - -cet_build_plugin(TEveGDMLTest art::module - REG_SOURCE src/TEveGDMLTest_module.cc - LIBRARIES REG - art_root_io::TFileService_service - Offline::TEveEventDisplay - Offline::TEveEventDisplay_dict - -) - -cet_build_plugin(TEveNonGDMLTest art::module - REG_SOURCE src/TEveNonGDMLTest_module.cc - LIBRARIES REG - art_root_io::TFileService_service - Offline::TEveEventDisplay - Offline::TEveEventDisplay_dict - -) - -art_dictionary( NO_CHECK_CLASS_VERSION # For some reason this segfaults - CLASSES_DEF_XML ${CMAKE_CURRENT_SOURCE_DIR}/src/classes_def.xml - CLASSES_H ${CMAKE_CURRENT_SOURCE_DIR}/src/classes.h - DICTIONARY_LIBRARIES - Offline::TEveEventDisplay -) - -configure_file(${CMAKE_CURRENT_SOURCE_DIR}/fcl/prolog.fcl ${CURRENT_BINARY_DIR} fcl/prolog.fcl COPYONLY) - -install_source(SUBDIRS src) -install_fhicl(SUBDIRS fcl SUBDIRNAME Offline/TEveEventDisplay/fcl) diff --git a/TEveEventDisplay/CallerFclExamples/MultipleHelix.fcl b/TEveEventDisplay/CallerFclExamples/MultipleHelix.fcl deleted file mode 100644 index 93ef1a97ac..0000000000 --- a/TEveEventDisplay/CallerFclExamples/MultipleHelix.fcl +++ /dev/null @@ -1,31 +0,0 @@ -# Sophie Middleton -#include "Offline/fcl/minimalMessageService.fcl" -#include "Offline/fcl/standardProducers.fcl" -#include "Offline/fcl/standardServices.fcl" -#include "Offline/TrkDiag/fcl/prolog.fcl" -#include "Offline/TrkPatRec/fcl/prolog.fcl" -#include "Offline/TrackerConditions/fcl/prolog.fcl" -#include "Offline/TrkHitReco/fcl/prolog.fcl" -#include "Offline/TEveEventDisplay/fcl/prolog.fcl" - -source : { module_type : RootInput -} - -services : @local::Services.Reco - -process_name : MultipleHelixED - -source : { module_type : RootInput } - -physics : -{ - - producers : { @table::TrkHitReco.producers} - analyzers : { @table::TEveDis.analyzers} - filters : { @table::TEveDis.filters} -} - -physics.RecoPath : [ EventFilter, @sequence::TrkHitReco.PrepareHits] -physics.EndPath : [ @sequence::TEveDis.seqHelix] - - diff --git a/TEveEventDisplay/CallerFclExamples/TestGDML.fcl b/TEveEventDisplay/CallerFclExamples/TestGDML.fcl deleted file mode 100644 index cda9409ad8..0000000000 --- a/TEveEventDisplay/CallerFclExamples/TestGDML.fcl +++ /dev/null @@ -1,20 +0,0 @@ -# Sophie Middleton -#include "Offline/fcl/minimalMessageService.fcl" -#include "Offline/fcl/standardProducers.fcl" -#include "Offline/fcl/standardServices.fcl" -#include "Offline/TEveEventDisplay/fcl/prolog.fcl" - -source : { module_type : EmptyEvent} - -services : @local::Services.Reco - -process_name : TestDisplay - -physics : -{ - analyzers : { @table::TEveDis.analyzers} -} - -physics.EndPath : [ @sequence::TEveDis.seqTest] - - diff --git a/TEveEventDisplay/CallerFclExamples/TestGeom.fcl b/TEveEventDisplay/CallerFclExamples/TestGeom.fcl deleted file mode 100644 index 2b7c02d5a9..0000000000 --- a/TEveEventDisplay/CallerFclExamples/TestGeom.fcl +++ /dev/null @@ -1,20 +0,0 @@ -# Sophie Middleton -#include "Offline/fcl/minimalMessageService.fcl" -#include "Offline/fcl/standardProducers.fcl" -#include "Offline/fcl/standardServices.fcl" -#include "Offline/TEveEventDisplay/fcl/prolog.fcl" - -source : { module_type : EmptyEvent} - -services : @local::Services.Reco - -process_name : TestDisplay - -physics : -{ - analyzers : { @table::TEveDis.analyzers} -} - -physics.EndPath : [ @sequence::TEveDis.seqGeomTest] - - diff --git a/TEveEventDisplay/CallerFclExamples/cosmictracks.fcl b/TEveEventDisplay/CallerFclExamples/cosmictracks.fcl deleted file mode 100644 index 63538bb6b5..0000000000 --- a/TEveEventDisplay/CallerFclExamples/cosmictracks.fcl +++ /dev/null @@ -1,30 +0,0 @@ -# author : Sophie Middleton -# purpose : Basic fcl for straight cosmic display -#include "Offline/fcl/minimalMessageService.fcl" -#include "Offline/fcl/standardProducers.fcl" -#include "Offline/fcl/standardServices.fcl" -#include "Offline/TEveEventDisplay/fcl/prolog.fcl" - -source : { module_type : RootInput} - -services : @local::Services.Reco - -process_name : CosmicStraightFitED - -physics : -{ - analyzers : { - @table::TEveDis.analyzers - } -} - -# edit the below options for different products: -physics.analyzers.TEveEventDisplayCosmics.filler.addHits : true -physics.analyzers.TEveEventDisplayCosmics.filler.addTracks : false -physics.analyzers.TEveEventDisplayCosmics.filler.addCrvHits : true -physics.analyzers.TEveEventDisplayCosmics.filler.addCosmicSeedFit : true -physics.analyzers.TEveEventDisplayCosmics.filler.addClusters : false -physics.analyzers.TEveEventDisplayCosmics.filler.addMCTraj : true - -physics.EndPath : [ @sequence::TEveDis.seqCosmics] - diff --git a/TEveEventDisplay/CallerFclExamples/helix_example.fcl b/TEveEventDisplay/CallerFclExamples/helix_example.fcl deleted file mode 100644 index aa8dae0b62..0000000000 --- a/TEveEventDisplay/CallerFclExamples/helix_example.fcl +++ /dev/null @@ -1,32 +0,0 @@ -# author : Sophie Middleton -# purpose : Basic example fcl for use with the helix instance - -#include "Offline/fcl/minimalMessageService.fcl" -#include "Offline/fcl/standardProducers.fcl" -#include "Offline/fcl/standardServices.fcl" -#include "Offline/TEveEventDisplay/fcl/prolog.fcl" - -services : @local::Services.Reco - -process_name : HelixED - -source : { module_type : RootInput } - -physics : -{ - analyzers : { @table::TEveDis.analyzers} -} - -# edit the below options for different products: -physics.analyzers.TEveEventDisplayHelix.filler.addHits : true -physics.analyzers.TEveEventDisplayHelix.filler.addTrkHits : false -physics.analyzers.TEveEventDisplayHelix.filler.addTimeClusters : false -physics.analyzers.TEveEventDisplayHelix.filler.addTracks : true -physics.analyzers.TEveEventDisplayHelix.filler.addCrvHits : false -physics.analyzers.TEveEventDisplayHelix.filler.addCosmicSeedFit : false -physics.analyzers.TEveEventDisplayHelix.filler.addClusters : true -physics.analyzers.TEveEventDisplayHelix.filler.addMCTraj : true -physics.analyzers.TEveEventDisplayHelix.show.showCRV : false -physics.EndPath : [ @sequence::TEveDis.seqHelix] - - diff --git a/TEveEventDisplay/CallerFclExamples/upstream.fcl b/TEveEventDisplay/CallerFclExamples/upstream.fcl deleted file mode 100644 index 4d6a763100..0000000000 --- a/TEveEventDisplay/CallerFclExamples/upstream.fcl +++ /dev/null @@ -1,20 +0,0 @@ -# Sophie Middleton -#include "Offline/fcl/minimalMessageService.fcl" -#include "Offline/fcl/standardProducers.fcl" -#include "Offline/fcl/standardServices.fcl" -#include "Offline/TEveEventDisplay/fcl/prolog.fcl" - -services : @local::Services.Reco - -process_name : POT - -source : { module_type : RootInput } - -physics : -{ - analyzers : { @table::TEveDis.analyzers} -} - -physics.EndPath : [ @sequence::TEveDis.seqPOT] - - diff --git a/TEveEventDisplay/README.md b/TEveEventDisplay/README.md deleted file mode 100644 index 58687a9171..0000000000 --- a/TEveEventDisplay/README.md +++ /dev/null @@ -1,100 +0,0 @@ -# Mu2e TEve Event Display Development Branch -The directory contains all the code for the TEve based mu2e Event display. This code allows 2D and 3D rendering of several of the Mu2e Data Products. It is still being developed so if we are missing some thing you need contact us (see below for details). - -## The GDML - -Our 3D geometry comes from the GDML stored in the src directory. - -## The Module -TEveEventDisplay/src/TEveEventDisplay_module.cc is the Analyzer mdoule which currently controls the TEveEventDisplay. This is your main function. The BeginJob function sets up your Frame (a TEveMu2eMainwindow Object) and it opens an Application. This is needed for the browser to appear. -The BeginRun function calls the Frame's (TEveMu2eMainWindow Object) SetRunGeometry. This is where the GDML is accessed and the Geom_Interface used to descend nodes and desiplay the DS. -The Analyze function fills the DataCollections (a list of Mu2e Data Products are called Collections). The Filler is a Collection_Filler object where the DataCollection is filled. -The Analyze function calls the the Frame's SetEvent function. In that function the various AddProduct (e.g. AdComboHit) are called. These Add functions reside in the Data or MC Interfaces. - -## Event Filter Module - -The EventFilter module allows the user to call a specific starting event. This can also be done using the text boxes on the GUI. - -## The fcl file -The prolog.fcl file resides in TEveEventDisplay/fcl and contains module instances for the TEveEventDisplay. - -## Command Line uses -We are in the process of making this code more sophisicated. Currently you can use the ```binTEveMu2e.sh``` script for command line input (to by-pass the need to continuously change the prolog): - -```TEveMu2e [fcl] [art] [number of evts] - [options]``` - -* ```[fcl``` the Caller fcl file which calls upon the TEveMu2e module -* ```art``` the data you would like to see represented int he display -* ```number of evts``` the nominal number of event loops that the module could reach (it works like any other). You can select a "starting" event using the EventFilter module. - -```options``` are: - -* Changing the Geometry: -2DOnly, -2Dand3D, -DSOnly, -CRVOnly, -DSandCRV. Note that there are default settings of 2Dand3D, DSOnly - this is displayed unless altered. -* Adding Data Products: -hits, -clusters, -tracks, -crvhits, -cosmictracks, -mctraj -* Accumulate Products i.e. collect multiple events for calibration assessments (turned off by default as only for specialist runs): -accumulate - -## The Standard way to run the code -We include some example CallerFcl files in: TEveEventDisplay/CallerFcls -to run like any other ART module: ```$ mu2e -c PATH_TO_CALLER_FCL/File.fcl PATH_TO_ART/art.art --nevts 100 (for 100 events)``` -The TEve Browser will appear. The first event takes a little longer as the GUI must be created. - -The TEve code can be used like any other Analyzer and added to your Reco/End path as such. There is no need to use the Callers they are just guides and examples. - -## The TEve Event Display Infrastructure -Current notable features of the code: - -### gdml -The GDML file used here can be regenerated using: ```mu2e -c mu2eG4/fcl/gdmldump.fcl```. It contains the entire Mu2e World. We use fix.gdml as a bug in the mu2e_common.gdml was found in the early stages of this development. - -### Geom Interface -Contains callers for access to Tracker and Calo geometry. This class also contains functions to set visability of different elements based on their names within the gdml. - -### GeomUtils - -Contains geometry transforms. The GDML was in cm so we convert all our coordinates to cm here. - -### TEveMu2e basis -Contains base classes which inherit from TEve objects. This is the interface between TEve objects and mu2e products. - -### Collection Filler and Data Collections -The DataCollection class has a list all the possible Mu2e data collections we might want to access. The full list is found in ```Offline/RecoDataProduct/inc```. The collections in DataCollections are set to 0 unless they are filled. The filling is done by a function ```FillRecoCollections``` in the Collection_Filler class. This is called in the module Analyze function. - -### classes.h and class_def - -Any src directory in mu2e which wants to use classes needs to list them in a classes.h and class_def.xml file. If you make a new class you must add it here. To make a new class use an existing class as a template. That way you wont run into errors. - -### Main Window - -This class sets up the GUI and imports the geometry. - -## Data and MC Interfaces - -These contain ```Add``` functions which add the specific data product to the event display. There is some templating but if you wish to add a new product you must do so explicitly by following the instructions in the following section (or contacting the developers). - -## Adding Data Products - -In order to add Data Products to the Event Display you may need to add an additional plotting function to the code. Here are the steps you should take to add the function. - -1. Check if the data product you want to add is in the Collection Filler and Data Collections classes. If not then add it to these classes. - -2. Create a function to add your data product in the TEveMu2eDataInterface or TEveMu2eMCInterface based on whether it is a Reco or MC Data Product. Add two lists in the header file. - -3. In your function call the DataLists template function. This will take care of handling your lists so that they work with the other features in the Event Display. - -4. Now add a condition to make sure your Data Product Collection is not empty. - -5. If you would like to add energies call the energies template. This currently works for hit and cluster i.e. point like type data products. - -6. Then loop through your Data Product Collection and call the draw function to the corresponding data type. For example, DrawHit3D/2D, DrawCluster3D/2D - -7. To utilize the 3D only feature, create a condition and pass the show2D parameter and control the 2D drawing functions with that parameter. - -8. Call the function in TEveMu2eMainWindow - -9. Modify the Collection Filler in TEveMu2eModule to get your data product from the art file. Add the product to the fcl file and change the prolog.fcl as needed. - -## Authors - -This code is built upon the Mu2e Offline code however TEveEventDisplay is package developed within Mu2e Offline by Sophie Middleton (Caltech) with help from: Aditi Venkatesh (Caltech) and Namitha Chithirasee from (Pisa). - -If you have any questions/comments about TEveEventDisplay please contact: smidd@caltech.edu. diff --git a/TEveEventDisplay/fcl/prolog.fcl b/TEveEventDisplay/fcl/prolog.fcl deleted file mode 100644 index 6a915606e6..0000000000 --- a/TEveEventDisplay/fcl/prolog.fcl +++ /dev/null @@ -1,122 +0,0 @@ -BEGIN_PROLOG - -TEveGDMLTest : { - module_type : TEveGDMLTest -} - -TEveNonGDMLTest : { - module_type : TEveNonGDMLTest -} - -TEveEventDisplayBase : { - module_type : TEveEventDisplay - accumulate : false - - isMCOnly : false - filler : { - ComboHitCollection : "makePH" - TimeClusterCollection : "MHDeM" - CrvRecoPulseCollection : "SelectRecoMC" - CosmicTrackSeedCollection : NULL - CaloClusterCollection : "CaloClusterMaker" - CaloHitCollection : NULL - HelixSeedCollection : "HelixFinderDe:Negative" - KalSeedCollection : ["KFFDeM"] - MCTrajectoryCollection : "compressRecoMCs" - addHits : true - addTrkHits : true - addTimeClusters : true - addTracks : true - addCrvHits : true - addCosmicSeedFit : false - addClusters : true - addMCTraj : true - addKKTracks : false - } - gdmlname : "Offline/TEveEventDisplay/src/mu2e.gdml" - particles : [11,13,2212,2112,211,22,212] - show : { - showCRV : false - showBuilding : false - showDSOnly : true - showInsidePS : false - } - } - -TEveEventDisplayHelix : { - @table::TEveEventDisplayBase - } - -TEveEventDisplayUpstream : { - @table::TEveEventDisplayBase - - isMCOnly : true - filler : { - ComboHitCollection : NULL - TimeClusterCollection : NULL - CosmicTrackSeedCollection : NULL - CrvRecoPulseCollection : NULL - CaloClusterCollection : NULL - CaloHitCollection : NULL - MCTrajectoryCollection : "g4run" - HelixSeedCollection : NULL - KalSeedCollection : [NULL] - addHits : false - addTrkHits : false - addTimeClusters : false - addTracks : false - addCrvHits : false - addCosmicSeedFit : false - addMCTraj : true - } - show : { - showDSOnly : false - showInsidePS : true - } - } - - -TEveEventDisplayCosmics : { # for stright cosmic for alignment (ordinary cosmics can use the base) - @table::TEveEventDisplayBase - filler : { - ComboHitCollection : NULL - TimeClusterCollection : "MHDeM" - CrvRecoPulseCollection : "SelectRecoMC" - CosmicTrackSeedCollection : NULL #"LineFit" - CaloClusterCollection : NULL - CaloHitCollection : NULL - HelixSeedCollection : NULL - KalSeedCollection : [] - MCTrajectoryCollection : NULL #"compressDigiMCs" - addHits : false - addTrkHits : false - addTimeClusters : true - addTracks : false - addCrvHits : true - addCosmicSeedFit : false - addClusters : false - addMCTraj : false - } - show :{ - showCRV : true - } - } - - -TEveDis : { - analyzers : { - TEveEventDisplayBase : @local::TEveEventDisplayBase - TEveEventDisplayCosmics : @local::TEveEventDisplayCosmics - TEveEventDisplayHelix : @local::TEveEventDisplayHelix - TEveGDMLTest : @local::TEveGDMLTest - TEveNonGDMLTest : @local::TEveNonGDMLTest - TEveEventDisplayUpstream : @local::TEveEventDisplayUpstream - } - - seqCosmics : [TEveEventDisplayCosmics] - seqHelix : [TEveEventDisplayHelix] - seqTest : [TEveGDMLTest] - seqGeomTest : [TEveNonGDMLTest] - seqPOT : [TEveEventDisplayUpstream] -} -END_PROLOG diff --git a/TEveEventDisplay/src/Collection_Filler.cc b/TEveEventDisplay/src/Collection_Filler.cc deleted file mode 100644 index a4dfd66d71..0000000000 --- a/TEveEventDisplay/src/Collection_Filler.cc +++ /dev/null @@ -1,100 +0,0 @@ -#include "Offline/TEveEventDisplay/src/dict_classes/Collection_Filler.h" -using namespace mu2e; -namespace mu2e{ - -#ifndef __ROOTCLING__ - Collection_Filler::Collection_Filler(const Config& conf) : - chTag_(conf.chTag()), - tcTag_(conf.tcTag()), - crvcoinTag_(conf.crvdigiTag()), - cluTag_(conf.cluTag()), - cryHitTag_(conf.cryHitTag()), - hseedTag_(conf.hseedTag()), - kalseedTag_(conf.kalseedTag()), - mctrajTag_(conf.mctrajTag()), - addHits_(conf.addHits()), - addTimeClusters_(conf.addTimeClusters()), - addTrkHits_(conf.addTrkHits()), - addTracks_(conf.addTracks()), - addClusters_(conf.addClusters()), - addCrvHits_(conf.addCrvHits()), - addCosmicSeedFit_(conf.addCosmicSeedFit()), - RecoOnly_(conf.RecoOnly()), - FillAll_(conf.FillAll()), - addMCTraj_(conf.addMCTraj()), - addKKTracks_(conf.addKKTracks()), - MCOnly_(conf.MCOnly()) - {} -#endif - - /*------------Function to turn InputTag to string for track labels:-------------*/ - template - std::string TurnNameToString( const T& value ) - { - std::ostringstream ss; - ss << value; - return ss.str(); - } - - - /*------------Function to fill RecoDataProduct lists:-------------*/ - void Collection_Filler::FillRecoCollections(const art::Event& evt, Data_Collections &data, RecoDataProductName CollectionName){ - if(FillAll_ or RecoOnly_ or (addHits_ and CollectionName == ComboHits)){ - auto chH = evt.getValidHandle(chTag_); - data.chcol = chH.product(); - } - if(FillAll_ or RecoOnly_ or (addTimeClusters_ and CollectionName == TimeClusters)){ - auto chH = evt.getValidHandle(tcTag_); - data.tccol = chH.product(); - } - if(FillAll_ or RecoOnly_ or (addTrkHits_ and CollectionName == ComboHits)){ - auto chH = evt.getValidHandle(chTag_); - data.chcol = chH.product(); - } - if(FillAll_ or RecoOnly_ or CollectionName == CaloCrystalHits){ - auto chH = evt.getValidHandle(cryHitTag_); - data.cryHitcol = chH.product(); - } - if(FillAll_ or RecoOnly_ or (addClusters_ and CollectionName==CaloClusters)){ - auto chH = evt.getValidHandle(cluTag_); - data.clustercol = chH.product(); - } - if(FillAll_ or RecoOnly_ or (addCosmicSeedFit_ and CollectionName==CosmicTracks)){ - auto chH = evt.getValidHandle("CosmicTrackFinderTimeFit"); - data.cosmiccol = chH.product(); - } - if(FillAll_ or RecoOnly_ or (addTracks_ and CollectionName==HelixSeeds)){ - auto chH = evt.getValidHandle(hseedTag_); - data.hseedcol = chH.product(); - } - if(FillAll_ or RecoOnly_ or (addTracks_ and CollectionName==KalSeeds)){ - - for(const auto &tag : kalseedTag_){ - auto chH = evt.getValidHandle(tag); - data.kalseedcol = chH.product(); - data.track_list.push_back(data.kalseedcol); - - std::string name = TurnNameToString(tag); - std::cout<<"Plotting KalSeed Instance: "<(crvcoinTag_); - data.crvcoincol = chH.product(); - } - } - - /*------------Function to fill MCDataProduct lists:-------------*/ - void Collection_Filler::FillMCCollections(const art::Event& evt, Data_Collections &data, MCDataProductName CollectionName){ - if(FillAll_ or MCOnly_ or (addMCTraj_ and CollectionName == MCTrajectories)){ - auto chH = evt.getValidHandle(mctrajTag_); - std::string name = TurnNameToString(mctrajTag_); - std::cout<<"Plotting MCtraj Instance: "< showbuilding{Name("showBuilding"), Comment("set false to remove building"),false}; - fhicl::Atom showCRV{Name("showCRV"), Comment("set false if you just want to see DS"),false}; - fhicl::Atom showDSOnly{Name("showDSOnly"), Comment(""),true}; - fhicl::Atom showInsidePS{Name("showInsidePS"), Comment(""),false}; - }; - - // Function to populate the Show struct from the validated config. - inline TEveMu2eMainWindow::GeomOptions convert( ShowConfig const& c ){ - return TEveMu2eMainWindow::GeomOptions(c.showbuilding(), - c.showCRV(), - c.showDSOnly(), - c.showInsidePS() ); - } - - } - -} - -#endif diff --git a/TEveEventDisplay/src/Geom_Interface.cc b/TEveEventDisplay/src/Geom_Interface.cc deleted file mode 100644 index 67262b2b0a..0000000000 --- a/TEveEventDisplay/src/Geom_Interface.cc +++ /dev/null @@ -1,178 +0,0 @@ - -#include "Offline/TEveEventDisplay/src/dict_classes/Geom_Interface.h" - -using namespace mu2e; -namespace mu2e{ - - Geom_Interface::Geom_Interface(){} - - // Function to descend and remove nodes above the DS - run after HideBuilding - void Geom_Interface::InsideDS( TGeoNode * node, bool inDSVac ){ - std::string _name = (node->GetVolume()->GetName()); - if ( node->GetMotherVolume() ) { - std::string motherName(node->GetMotherVolume()->GetName()); - if ( motherName == "DS2Vacuum" || motherName == "DS3Vacuum" ){ - inDSVac = true; - } - } - if ( inDSVac && _name.find("VirtualDetector_TT_Mid") != 0 ) { - node->SetVisibility(kTRUE); - } else{ - node->SetVisibility(kFALSE); - } - int ndau = node->GetNdaughters(); - for ( int i=0; iGetDaughter(i); - InsideDS( dau, inDSVac ); - } - } - - // Function to descend and remove nodes above the PS - run after HideBuilding - void Geom_Interface::InsidePS( TGeoNode * node, bool inPSVac ){ - std::string _name = (node->GetVolume()->GetName()); - if ( node->GetMotherVolume() ) { - std::string motherName(node->GetMotherVolume()->GetName()); - if ( motherName == "PSVacuum" ){ - inPSVac = true; - } - } - if ( inPSVac && _name.find("ProductionTargetTungstenLa2") != 0 ) { - node->SetVisibility(kTRUE); - } else{ - node->SetVisibility(kFALSE); - } - int ndau = node->GetNdaughters(); - for ( int i=0; iGetDaughter(i); - InsidePS( dau, inPSVac ); - } - } - - //Function allows user to specifically hide a node by its GDML mateiral name. See Fix.gdml for the name. - void Geom_Interface::hideNodesByMaterial(TGeoNode* node, const std::string& mat, bool onOff) { - std::string material(node->GetVolume()->GetMaterial()->GetName()); - if ( material.find(mat) != std::string::npos ) node->SetVisibility(onOff); - int ndau = node->GetNdaughters(); - for ( int i=0; iGetDaughter(i); - hideNodesByMaterial( dau, mat, onOff); - } - } - - //Function to hide element by its name - void Geom_Interface::hideNodesByName(TGeoNode* node, const std::string& str, bool onOff, int _diagLevel) { - std::string name(node->GetName()); - if ( name.find(str) != std::string::npos ){ - node->SetVisibility(onOff); - if(_diagLevel > 0) std::cout <<"hiding "<< name << std::endl; - } - int ndau = node->GetNdaughters(); - for ( int i=0; iGetDaughter(i); - hideNodesByName( dau, str, onOff, _diagLevel); - } - } - - void Geom_Interface::showNodesByName(TGeoNode* node, const std::string& str, bool onOff){ - std::string name(node->GetName()); - if ( name.find(str) != std::string::npos ){ - node->SetVisibility(onOff); - } - int ndau = node->GetNdaughters(); - for (int i=0; iGetDaughter(i); - showNodesByName(dau, str, onOff); - } - } - - //Function to show CRV. Run after InsideDS - void Geom_Interface::InsideCRV( TGeoNode * node, bool inCRVVac ){ - static std::vector substrings {"CRSAluminum", "CRV", "CRS"}; - for(auto& i: substrings) showNodesByName(node, i, kTRUE); - } - - //Function to hide all elements which are not PS,TS, DS: - void Geom_Interface::SolenoidsOnly(TGeoNode* node) { - static std::vector substrings { "Ceiling", - "backfill", "dirt", "concrete", "VirtualDetector", - "pipeType","ExtShield", "PSShield"}; - for(auto& i: substrings) hideNodesByName(node,i,kFALSE, 0); - static std::vector materials { "MBOverburden", "CONCRETE"}; - for(auto& i: materials) hideNodesByMaterial(node,i,kFALSE); - } - - //Funciton to hide building top - void Geom_Interface::hideTop(TGeoNode* node, int _diagLevel) { - TString name = node->GetName(); - if(_diagLevel > 0 and name.Index("Shield")>0) { - std::cout << name << " " << name.Index("mBox_") << std::endl; - } - bool test = false; - - if(name.Index("mBox_45_")>=0) test = true; - if(name.Index("mBox_46_")>=0) test = true; - if(name.Index("mBox_47_")>=0) test = true; - if(name.Index("mBox_48_")>=0) test = true; - if(name.Index("mBox_49_")>=0) test = true; - if(name.Index("mBox_74_")>=0) test = true; - - if(test) { - std::cout << "turning off " << name << std::endl; - node->SetVisibility(false); - } - - // Descend recursively into each daughter TGeoNode. - int ndau = node->GetNdaughters(); - for ( int i=0; iGetDaughter(i); - hideTop( dau, _diagLevel ); - } - } - - //Useful function to extract heirarchy of tracker (not used anywhere) - void Geom_Interface::TrackerVolumeHeirarchy( TGeoNode * node, std::vector &TransformList ){ - std::string _name = (node->GetVolume()->GetName()); - if( _name == "HallAir") { - std::cout<<"HallAir Origin IS "<GetMotherVolume()->GetName(); - TGeoVolume *vol = node->GetVolume(); - TGeoBBox *shape = (TGeoBBox*)vol->GetShape(); - Double_t master[3]; - const Double_t *local = shape->GetOrigin(); - if(shape!=NULL){ - gGeoManager->LocalToMaster(local,master); - CLHEP::Hep3Vector hallToworld(master[0], master[1], master[2]); - TransformList.push_back(hallToworld); - } - } - if( _name == "DS3Vacuum") { - std::cout<<"DS3 Origin IS "<GetMotherVolume()->GetName(); - TGeoVolume *vol = node->GetVolume(); - TGeoBBox *shape = (TGeoBBox*)vol->GetShape(); - Double_t master[3]; - const Double_t *local = shape->GetOrigin(); - if(shape!=NULL){ - gGeoManager->LocalToMaster(local,master); - CLHEP::Hep3Vector DSTohall(master[0], master[1], master[2]); - TransformList.push_back(DSTohall); - } - } - if( _name == "TrackerMother") { - std::cout<<"Tracker Origin IS "<GetMotherVolume()->GetName(); - TGeoVolume *vol = node->GetVolume(); - TGeoBBox *shape = (TGeoBBox*)vol->GetShape(); - Double_t master[3]; - const Double_t *local = shape->GetOrigin(); - if(shape!=NULL){ - gGeoManager->LocalToMaster(local,master); - CLHEP::Hep3Vector TrackerToDS(master[0], master[1], master[2]); - TransformList.push_back(TrackerToDS); - } - } - // Descend into each daughter TGeoNode. - int ndau = node->GetNdaughters(); - for ( int i=0; iGetDaughter(i); - TrackerVolumeHeirarchy(dau, TransformList); - } - } -} diff --git a/TEveEventDisplay/src/Icons/Next.png b/TEveEventDisplay/src/Icons/Next.png deleted file mode 100644 index 56b6ed08ab..0000000000 Binary files a/TEveEventDisplay/src/Icons/Next.png and /dev/null differ diff --git a/TEveEventDisplay/src/Icons/Previous.png b/TEveEventDisplay/src/Icons/Previous.png deleted file mode 100644 index 3d549a5f6d..0000000000 Binary files a/TEveEventDisplay/src/Icons/Previous.png and /dev/null differ diff --git a/TEveEventDisplay/src/Icons/back.png b/TEveEventDisplay/src/Icons/back.png deleted file mode 100644 index 3f55c73f84..0000000000 Binary files a/TEveEventDisplay/src/Icons/back.png and /dev/null differ diff --git a/TEveEventDisplay/src/Icons/forward.png b/TEveEventDisplay/src/Icons/forward.png deleted file mode 100644 index c712576f47..0000000000 Binary files a/TEveEventDisplay/src/Icons/forward.png and /dev/null differ diff --git a/TEveEventDisplay/src/Icons/greengradient.png b/TEveEventDisplay/src/Icons/greengradient.png deleted file mode 100644 index 49bb7aae51..0000000000 Binary files a/TEveEventDisplay/src/Icons/greengradient.png and /dev/null differ diff --git a/TEveEventDisplay/src/Icons/mu2e_logo_oval.png b/TEveEventDisplay/src/Icons/mu2e_logo_oval.png deleted file mode 100644 index 8f4dccc181..0000000000 Binary files a/TEveEventDisplay/src/Icons/mu2e_logo_oval.png and /dev/null differ diff --git a/TEveEventDisplay/src/Icons/purplegradient.png b/TEveEventDisplay/src/Icons/purplegradient.png deleted file mode 100644 index 1d5961cbde..0000000000 Binary files a/TEveEventDisplay/src/Icons/purplegradient.png and /dev/null differ diff --git a/TEveEventDisplay/src/SConscript b/TEveEventDisplay/src/SConscript deleted file mode 100644 index b177f9aaf3..0000000000 --- a/TEveEventDisplay/src/SConscript +++ /dev/null @@ -1,73 +0,0 @@ -#!/usr/bin/env python -# -# Original author Rob Kutschke. -# -#!/usr/bin/env python -# -# Original author Rob Kutschke. -# - -import os, re -Import('env') -Import('mu2e_helper') - -helper=mu2e_helper(env) - -rootlibs = env['ROOTLIBS'] -extrarootlibs = [ 'Geom', 'Geom', 'GeomPainter', 'Ged', 'Graf3d', 'Eve','EG', 'RGL','Gui', "Gdml" , "Core", "Rint"] - -userlibs = [ rootlibs, - extrarootlibs, - 'mu2e_DataProducts', - 'mu2e_TrkReco', - 'mu2e_Mu2eUtilities', - 'mu2e_MCDataProducts', - 'mu2e_RecoDataProducts', - 'mu2e_GlobalConstantsService', - 'mu2e_GeometryService', - 'mu2e_CalorimeterGeom', - 'mu2e_TrackerGeom', - 'mu2e_CosmicRayShieldGeom', - 'mu2e_GeomPrimitives', - 'mu2e_ConfigTools', - 'mu2e_GeneralUtilities', - 'art_Framework_Core', - 'art_Framework_Principal', - 'art_Framework_Services_Registry', - 'art_root_io_tfile_support', - 'art_root_io_TFileService', - 'art_Framework_Services_Optional_RandomNumberGenerator', - 'art_Persistency_Common', - 'art_Persistency_Provenance', - 'art_Utilities', - 'canvas', - 'MF_MessageLogger', - 'fhiclcpp', - 'fhiclcpp_types', - 'tbb', - 'cetlib', - 'cetlib_except', - 'KinKal_Trajectory', - 'KinKal_General', - 'CLHEP', - 'Core', - 'boost_filesystem', - 'boost_system' - ] - -# when using ClassDef, tell the build to include the -# dictionary in the mainlib -helper.classDef(True) - -helper.make_dict_and_map() - -mainlib = helper.make_mainlib([userlibs]) - -helper.make_plugins( [ 'mu2e_TEveEventDisplay',userlibs ] ) - - - -# This tells emacs to view this file in python mode. -# Local Variables: -# mode:python -# End: diff --git a/TEveEventDisplay/src/TEveEventDisplay_module.cc b/TEveEventDisplay/src/TEveEventDisplay_module.cc deleted file mode 100644 index 9d39797150..0000000000 --- a/TEveEventDisplay/src/TEveEventDisplay_module.cc +++ /dev/null @@ -1,157 +0,0 @@ -//... libCore -#include -#include -#include -#include -#include - -// ... libRIO -#include - -//TEveEventDisplay Headers: -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMainWindow.h" -#include "Offline/TEveEventDisplay/src/dict_classes/Collection_Filler.h" -#include "Offline/TEveEventDisplay/src/dict_classes/Data_Collections.h" -#include "Offline/TEveEventDisplay/src/DisplayUtilsConfig.hh" - -// Framework includes. -#include "art/Framework/Core/EDAnalyzer.h" -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Handle.h" -#include "art_root_io/TFileService.h" - -//fcl -#include "fhiclcpp/types/Atom.h" -#include "fhiclcpp/types/TableAs.h" - -using namespace std; -using namespace mu2e; - -namespace mu2e -{ - class TEveEventDisplay : public art::EDAnalyzer { - public: - - struct Config{ - using Name=fhicl::Name; - using Comment=fhicl::Comment; - fhicl::Atom diagLevel{Name("diagLevel"), Comment("for info"),0}; - fhicl::Atom isMCOnly{Name("isMCOnly"), Comment(""),false}; - fhicl::Atom accumulate{Name("accumulate"), Comment(""),false}; - fhicl::Table filler{Name("filler"),Comment("fill collections")}; - fhicl::Atomgdmlname{Name("gdmlname"),Comment("gdmlname")}; - fhicl::Sequenceparticles{Name("particles"),Comment("PDGcodes to plot")}; - fhicl::TableAs show {Name("show"), Comment("Control which view to show")}; - }; - - typedef art::EDAnalyzer::Table Parameters; - explicit TEveEventDisplay(const Parameters& conf); - virtual ~TEveEventDisplay(); - virtual void beginJob() override; - virtual void beginRun(const art::Run& run) override; - virtual void analyze(const art::Event& e); - virtual void endJob() override; - - private: - Config _conf; - int _diagLevel; - bool _isMCOnly; - bool _accumulate; - TApplication* application_; - TDirectory* directory_ = nullptr; - Collection_Filler _filler; - std::string _gdmlname; - std::vector _particles; - const TEveMu2eMainWindow::GeomOptions _show; - TEveMu2eMainWindow *_frame; - fhicl::ParameterSet _pset; - bool foundEvent = false; - void MakeTEveMu2eMainWindow(); - bool _firstLoop = true; - int runn = 0; - int subrunn= 0; - int eventn = 0; - bool eventSelected = false; - }; - - TEveEventDisplay::TEveEventDisplay(const Parameters& conf) : - art::EDAnalyzer(conf), - _diagLevel(conf().diagLevel()), - _isMCOnly(conf().isMCOnly()), - _accumulate(conf().accumulate()), - _filler(conf().filler()), - _gdmlname(conf().gdmlname()), - _particles(conf().particles()), - _show(conf().show()) - {} - - - TEveEventDisplay::~TEveEventDisplay(){} - - void TEveEventDisplay::beginJob(){ - - directory_ = gDirectory; - if ( !gApplication ){ - int tmp_argc(0); - char** tmp_argv(0); - application_ = new TApplication( "noapplication", &tmp_argc, tmp_argv ); - } - //construct GUI: - const DrawOptions DrawOpts(_filler.addCrvHits_, _filler.addCosmicSeedFit_, _filler.addTracks_, _filler.addClusters_, _filler.addHits_, _filler.addTrkHits_, _filler.addTimeClusters_, false, _filler.addMCTraj_, _filler.addKKTracks_); - - _frame = new TEveMu2eMainWindow(gClient->GetRoot(), 1000,600, _pset, DrawOpts, _show); - - //build 2D geometries (now optional): - if(DrawOpts.addCRVInfo)_frame->CreateCRVProjection(); - if(DrawOpts.addClusters or DrawOpts.addCryHits) _frame->CreateCaloProjection(); - _frame->CreateTrackerProjection(); - //send list of particles to viewer: - _frame->SetParticleOpts(_particles); - - } - - void TEveEventDisplay::beginRun(const art::Run& run){ - //import 3D GDML geom: - _frame->SetRunGeometry(run, _gdmlname, _diagLevel); - //make 2D tracker and calo: - if(_filler.addClusters_) _frame->PrepareCaloProjectionTab(run); - _frame->PrepareTrackerProjectionTab(run); - } - - void TEveEventDisplay::analyze(const art::Event& event){ - std::cout<<"[In TEveEventDisplay::analyze()]"<isClosed()) _frame->setEvent(event, _firstLoop, data, -1, _accumulate, runn, eventn, eventSelected, _isMCOnly); - _firstLoop = false; - - } - } - - - void TEveEventDisplay::endJob(){ - if(!foundEvent){ - char msg[300]; - sprintf(msg, "Reached end of file but #%i has not been found", true); - new TGMsgBox(gClient->GetRoot(), gClient->GetRoot(), "Event Not Found", msg, kMBIconExclamation,kMBOk); - } - } - -} -using mu2e::TEveEventDisplay; -DEFINE_ART_MODULE(TEveEventDisplay) - diff --git a/TEveEventDisplay/src/TEveGDMLTest_module.cc b/TEveEventDisplay/src/TEveGDMLTest_module.cc deleted file mode 100644 index c26155e8c5..0000000000 --- a/TEveEventDisplay/src/TEveGDMLTest_module.cc +++ /dev/null @@ -1,203 +0,0 @@ -// ... libCore -#include -#include -#include -#include -#include -#include -// ... libRIO -#include -// ... libGui -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -// ... libGeom -#include -#include -#include -#include -#include -#include -// ... libRGL -#include -// ... libEve -#include -#include -#include -#include -#include -#include - -// Framework includes. -#include "art/Framework/Core/EDAnalyzer.h" -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Handle.h" -#include "art_root_io/TFileService.h" - -void setRecursiveColorTransp(TGeoVolume *vol, Int_t color, Int_t transp) - { - if(color>=0)vol->SetLineColor(color); - if(transp>=0)vol->SetTransparency(transp); - Int_t nd = vol->GetNdaughters(); - for (Int_t i=0; iGetNode(i)->GetVolume(), color, transp); - } - } - - -namespace mu2e -{ - class TEveGDMLTest : public art::EDAnalyzer { - public: - - struct Config{ - using Name=fhicl::Name; - using Comment=fhicl::Comment; - fhicl::Atom diagLevel{Name("diagLevel"), Comment("for info"),0}; - }; - - typedef art::EDAnalyzer::Table Parameters; - explicit TEveGDMLTest(const Parameters& conf); - virtual ~TEveGDMLTest(); - virtual void beginJob() override; - virtual void beginRun(const art::Run& run) override; - virtual void analyze(const art::Event& e); - virtual void endJob() override; - private: - Config _conf; - int _diagLevel; - bool isFirstEvent = true; - TApplication* application_; - TDirectory* directory_ = nullptr; - TGeoManager *geom; - fhicl::ParameterSet _pset; - void MakeTEveMu2eMainWindow(); - }; - - TEveGDMLTest::TEveGDMLTest(const Parameters& conf) : - art::EDAnalyzer(conf), - _diagLevel(conf().diagLevel()) - - {} - - TEveGDMLTest::~TEveGDMLTest(){} - - void TEveGDMLTest::MakeTEveMu2eMainWindow() - { - TEveBrowser* browser = gEve->GetBrowser(); - browser->StartEmbedding(TRootBrowser::kLeft); - TGMainFrame* frmMain = new TGMainFrame(gClient->GetRoot(), 1000, 600); - frmMain->SetWindowName("EVT NAV"); - frmMain->SetCleanup(kDeepCleanup); - TGHorizontalFrame* navFrame = new TGHorizontalFrame(frmMain); - { - TString icondir(TString::Format("%s/icons/", gSystem->Getenv("ROOTSYS")) ); - TGPictureButton* b = 0; - b = new TGPictureButton(navFrame, gClient->GetPicture(icondir + "GoBack.gif")); - navFrame->AddFrame(b); - - TGPictureButton* f = 0; - f = new TGPictureButton(navFrame, gClient->GetPicture(icondir + "GoForward.gif")); - navFrame->AddFrame(f); - - std::string logoFile = "TEveEventDisplay/src/Icons/mu2e_logo_oval.png"; - const TGPicture *logo = gClient->GetPicture(logoFile.c_str()); - TGIcon *icon = new TGIcon(navFrame,logo,50,50); - navFrame->AddFrame(icon,new TGLayoutHints(kLHintsLeft,20,0,0,0)); - - frmMain->AddFrame(navFrame); - TGHorizontal3DLine *separator = new TGHorizontal3DLine(frmMain); - frmMain->AddFrame(separator, new TGLayoutHints(kLHintsExpandX)); - frmMain->MapSubwindows(); - frmMain->Resize(); - frmMain->MapWindow(); - browser->StopEmbedding(); - browser->SetTabTitle("Event Nav", 0); - } - } - - void TEveGDMLTest::beginJob(){ - std::cout<<"[Starting TEveGDMLTest::beginJob()]"<AddEvent(new TEveEventManager("Event", "Empty Event")); - TGLViewer *glv = gEve->GetDefaultGLViewer(); - glv->SetGuideState(TGLUtil::kAxesEdge, kTRUE, kFALSE, 0); - std::cout<<"[Ending TEveGDMLTest::beginJob()]"<GetListOfNodes()->Delete(); - gGeoManager->GetListOfVolumes()->Delete(); - gGeoManager->GetListOfShapes()->Delete(); - } - gEve->GetGlobalScene()->DestroyElements(); - - // Import the GDML of entire Mu2e Geometry - geom = geom->TGeoManager::Import("TEveEventDisplay/src/fix.gdml"); - - //Get Top Volume - TGeoVolume* topvol = geom->GetTopVolume(); - - //Set Top Volume for gGeoManager: - gGeoManager->SetTopVolume(topvol); - //Set visibility: - gGeoManager->SetTopVisible(kTRUE);//HERE--> the issue!! - - //Get Top Node: - TGeoNode* topnode = gGeoManager->GetTopNode(); - TEveGeoTopNode* etopnode = new TEveGeoTopNode(gGeoManager, topnode); - etopnode->SetVisLevel(4); - etopnode->GetNode()->GetVolume()->SetVisibility(kFALSE); - setRecursiveColorTransp(etopnode->GetNode()->GetVolume(), kWhite-10,70); - std::cout<<"Point 5"<AddGlobalElement(etopnode); - geom->Draw("ogl"); - std::cout<<"[Ending TEveGDMLTest::beginRun()]"<GetViewers()->DeleteAnnotations(); - gEve->GetCurrentEvent()->DestroyElements(); - } - // Import event into ortho views and apply projections - //TEveElement* currevt = gEve->GetCurrentEvent(); - - geom->Draw("ogl"); - gPad->WaitPrimitive(); - isFirstEvent = false; - std::cout<<"[Ending TEveGDMLTest::analyze()]"< halflen; - CLHEP::Hep3Vector position; - CosmicRayShield const &CRS = *(GeomHandle()); - const std::string TopSectorNames[] = {"T1", "T2", "T3", "T4"}; - for (unsigned int i=0; i<4; i++){ - Double_t panelpos[3]; - halflen = CRS.getSectorHalfLengths(TopSectorNames[i]); - position = CRS.getSectorPosition(TopSectorNames[i]); - - panelpos [0] = position.x(); - panelpos [1] = position.y(); - panelpos [2] = position.z(); - - TEveGeoShape *sectorshape = new TEveGeoShape(); - sectorshape->SetShape(new TGeoBBox("sectorshape",pointmmTocm(2*halflen[0]), pointmmTocm(2*halflen[2]), pointmmTocm(2*halflen[1]),panelpos)); - sectorshape->SetMainTransparency(100); - TGeoShape *g = new TGeoBBox("CRV Sector",pointmmTocm(2*halflen[0]), pointmmTocm(2*halflen[2]), pointmmTocm(2*halflen[1])); - TGeoVolume *crv0= new TGeoVolume("CRV Sector",g, Si); - crv0->SetVisLeaves(kFALSE); - crv0->SetInvisible(); - std::string filename("Mu2eG4/geom/crv_counters_v07.txt"); - SimpleConfig Config(filename); - std::vector Center; - if(i==0) Config.getVectorDouble("crs.firstCounterT1", Center); - if(i==1) Config.getVectorDouble ("crs.firstCounterT2",Center); - if(i==2) Config.getVectorDouble("crs.firstCounterT3", Center); - if(i==3) Config.getVectorDouble("crs.firstCounterT4", Center) ; - orthodetT1->AddElement(sectorshape); - topvol->AddNode(crv0, 1, new TGeoTranslation(pointmmTocm(Center[0]),pointmmTocm(Center[1]),pointmmTocm(Center[2]))); - } - } -} - diff --git a/TEveEventDisplay/src/TEveMu2eCRVEvent.cc b/TEveEventDisplay/src/TEveMu2eCRVEvent.cc deleted file mode 100644 index 07e03eca6a..0000000000 --- a/TEveEventDisplay/src/TEveMu2eCRVEvent.cc +++ /dev/null @@ -1,93 +0,0 @@ -#include "Offline/GeometryService/inc/GeomHandle.hh" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCRVEvent.h" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -using namespace mu2e; -namespace mu2e{ - - TEveMu2eCRVEvent::TEveMu2eCRVEvent(){} - - /*------------Function to build title:-------------*/ - std::string TEveMu2eCRVEvent::DataTitle(const std::string &pstr, int n){ - std::string dstr=" hit#" + std::to_string(n) + "\nLayer: "; - std::string strlab=pstr+dstr; - return (strlab); - } - - /*------------Function to display straws which are hit-------*/ - std::tupleTEveMu2eCRVEvent::DrawSciBar(){ - GeomHandle CRS; - const CRSScintillatorBarIndex &crvBarIndexn = fCrvRecoPulse_.GetScintillatorBarIndex(); - const CRSScintillatorBar &crvCounter = CRS->getBar(crvBarIndexn); - CLHEP::Hep3Vector crvCounterPos = crvCounter.getPosition(); - hep3vectormmTocm(crvCounterPos); - const CRSScintillatorBarDetail &barDetail = crvCounter.getBarDetail(); - CLHEP::Hep3Vector sibardetails(pointmmTocm(barDetail.getHalfLengths()[0]),pointmmTocm(barDetail.getHalfLengths()[1]),pointmmTocm(barDetail.getHalfLengths()[2])); - return {sibardetails, crvCounterPos}; - } - - /*------------Function to 3D draw hits:-------------*/ - void TEveMu2eCRVEvent::DrawHit3D(const std::string &pstr, Int_t n, CLHEP::Hep3Vector pointInMu2e, TEveElementList *CrvList3D) - { - auto [sibardetails, crvCounterPos] = DrawSciBar(); - Double_t sibarposition[3]; - sibarposition[0] = (crvCounterPos.x()); - sibarposition[1] = (crvCounterPos.y()); - sibarposition[2] = (crvCounterPos.z()); - TEveGeoShape *sibar = new TEveGeoShape(); - sibar->SetShape(new TGeoBBox("sibar",sibardetails.x(),sibardetails.y(),sibardetails.z(), sibarposition)); - CrvList3D->AddElement(sibar); - - this->SetTitle((DataTitle(pstr, n)).c_str()); - this->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - this->SetMarkerColor(mColor_); - this->SetMarkerSize(mSize_); - this->SetPickable(kTRUE); - CrvList3D->AddElement(this); - } - - /*------------Function to 2D draw hits:-------------*/ - void TEveMu2eCRVEvent::DrawHit2DXY(const std::string &pstr, Int_t n, CLHEP::Hep3Vector pointInMu2e, TEveElementList *CrvList2DXY) - { - auto [sibardetails, crvCounterPos] = DrawSciBar(); - Double_t sibarposition[3]; - sibarposition[0] = pointmmTocm(crvCounterPos.x()); - sibarposition[1] = pointmmTocm(crvCounterPos.y()); - sibarposition[2] = pointmmTocm(crvCounterPos.z()); - - TEveGeoShape *sibar = new TEveGeoShape(); - sibar->SetShape(new TGeoBBox("sibar",pointmmTocm(sibardetails.x()),pointmmTocm(sibardetails.y()),pointmmTocm(sibardetails.z()), sibarposition)); - sibar->SetMainTransparency(100); - CrvList2DXY->AddElement(sibar); - - this->SetTitle((DataTitle(pstr, n)).c_str()); - hep3vectormmTocm(pointInMu2e); - this->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - this->SetMarkerColor(mColor_); - this->SetMarkerSize(mSize_); - this->SetPickable(kTRUE); - CrvList2DXY->AddElement(this); - } - - void TEveMu2eCRVEvent::DrawHit2DYZ(const std::string &pstr, Int_t n, CLHEP::Hep3Vector pointInMu2e, TEveElementList *CrvList2DYZ) - { - auto [sibardetails, crvCounterPos] = DrawSciBar(); - Double_t sibarposition[3]; - sibarposition[0] = 0.0; - sibarposition[1] = pointmmTocm(crvCounterPos.y()); - sibarposition[2] = pointmmTocm(crvCounterPos.z()); - - TEveGeoShape *sibar = new TEveGeoShape(); - sibar->SetShape(new TGeoBBox("sibar",0.0,pointmmTocm(sibardetails.y()),pointmmTocm(sibardetails.z()), sibarposition)); - sibar->SetMainTransparency(100); - CrvList2DYZ->AddElement(sibar); - - this->SetTitle((DataTitle(pstr, n)).c_str()); - hep3vectormmTocm(pointInMu2e); - this->SetNextPoint(0.0, pointInMu2e.y(), pointInMu2e.z()); - this->SetMarkerColor(mColor_); - this->SetMarkerSize(mSize_); - this->SetPickable(kTRUE); - CrvList2DYZ->AddElement(this); - - } -} diff --git a/TEveEventDisplay/src/TEveMu2eCalorimeter.cc b/TEveEventDisplay/src/TEveMu2eCalorimeter.cc deleted file mode 100644 index 66fdfded48..0000000000 --- a/TEveEventDisplay/src/TEveMu2eCalorimeter.cc +++ /dev/null @@ -1,54 +0,0 @@ -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h" -#include "Offline/GeometryService/inc/GeomHandle.hh" -#include "art/Framework/Principal/Run.h" - -using namespace mu2e; -namespace mu2e{ - - TEveMu2eCalorimeter::TEveMu2eCalorimeter(){} - - /*------------Function to construct calorimeter (for 2D only):-------------*/ - void TEveMu2eCalorimeter::DrawCaloDetector(art::Run const& run, TGeoVolume* topvol, TEveElementList *orthodet0, TEveElementList *orthodet1){ - TGeoMaterial *mat = new TGeoMaterial("CsI", 28.085,14,2.33); - TGeoMedium *CsI = new TGeoMedium("CsI",2, mat); - - Calorimeter const &cal = *(GeomHandle()); - unsigned int CrystalsperDisk = cal.disk(0).nCrystals(); - for(unsigned int i = 0; i < CrystalsperDisk * 2 ; i++){ - Crystal const &crystal = cal.crystal(i); - double crystalXLen = pointmmTocm(crystal.size().x()); - double crystalYLen = pointmmTocm(crystal.size().y()); - double crystalZLen = pointmmTocm(crystal.size().z()); - - CLHEP::Hep3Vector crystalPos = cal.geomUtil().mu2eToDiskFF(0,crystal.position()); - Double_t origin[3]; - GeomHandle det; - crystalPos = det->toMu2e(crystalPos); - - hep3vectormmTocm(crystalPos); - origin [0] = crystalPos.x(); - origin [1] = crystalPos.y(); - origin [2] = crystalPos.z(); - TEveGeoShape *crystalShape = new TEveGeoShape(); - crystalShape->SetMainTransparency(100); - crystalShape->SetShape(new TGeoBBox("crystalD0", (crystalXLen/2), (crystalYLen/2), (crystalZLen/2)/10, origin)); - if(i < CrystalsperDisk){ - orthodet0->AddElement(crystalShape); - TGeoShape *c = new TGeoBBox("crystalD0", (crystalXLen/2), (crystalYLen/2), (crystalZLen/2)); - TGeoVolume *cry= new TGeoVolume("cryD0",c, CsI); - cry->SetVisLeaves(kFALSE); - cry->SetInvisible(); - topvol->AddNode(cry, 1, new TGeoTranslation(crystalPos.x(),crystalPos.y(),crystalPos.z())); - } else { - crystalShape->SetShape(new TGeoBBox("crystalD1", (crystalXLen/2), (crystalYLen/2), (crystalZLen/2), origin)); - orthodet1->AddElement(crystalShape); - TGeoShape *c = new TGeoBBox("crystalD1", (crystalXLen/2), (crystalYLen/2), (crystalZLen/2)); - TGeoVolume *cry= new TGeoVolume("cryD1",c, CsI); - cry->SetVisLeaves(kFALSE); - cry->SetInvisible(); - topvol->AddNode(cry, 1, new TGeoTranslation(crystalPos.x(),crystalPos.y(),crystalPos.z())); - } - } - } - -} diff --git a/TEveEventDisplay/src/TEveMu2eCluster.cc b/TEveEventDisplay/src/TEveMu2eCluster.cc deleted file mode 100644 index 2b34b214cf..0000000000 --- a/TEveEventDisplay/src/TEveMu2eCluster.cc +++ /dev/null @@ -1,52 +0,0 @@ -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCluster.h" - -using namespace mu2e; -namespace mu2e{ - - TEveMu2eCluster::TEveMu2eCluster(){} - - /*------------Function to make object title:-------------*/ - std::string TEveMu2eCluster::DataTitle(const std::string &pstr, double edep){ - std::string dstr= "\nLayer: "; - std::string strlst=pstr+dstr+std::to_string(edep); - return(strlst); - } - - /*------------Function to draw cluster and optional hits:-------------*/ - void TEveMu2eCluster::DrawCluster(const std::string &pstr, CLHEP::Hep3Vector cog, int energylevel, TEveElementList *ClusterList, std::vector hits, bool addHits) - { - double edep = fCaloCluster_.energyDep(); - this->SetTitle((DataTitle(pstr, edep)).c_str()); - Int_t mSize = 3; - int colors[] = {+10, +5, +7, +8, -3, +1, -5, 0, -2, -4, +6, -9}; - this->SetMarkerColor(kViolet + colors[energylevel]); - this->SetNextPoint(cog.x(), cog.y(), cog.z()); - this->SetMarkerStyle(9); - this->SetMarkerSize(mSize); - this->SetPickable(kTRUE); - - if(addHits){ - TEvePointSet *teve_hit2D = new TEvePointSet(); - for(unsigned int h =0 ; h < hits.size();h++) { - teve_hit2D->SetNextPoint(hits[h].x(), hits[h].y(), hits[h].z()); - teve_hit2D->SetMarkerSize(2); - teve_hit2D->SetMarkerStyle(47); - teve_hit2D->SetMarkerColor(kViolet + colors[energylevel]); - ClusterList->AddElement(teve_hit2D); - } - } - ClusterList->AddElement(this); - } - - /*------------Function to draw hits:-------------*/ - void TEveMu2eCluster::DrawCrystalHits(const std::string &pstr, CLHEP::Hep3Vector cog, TEveElementList *ClusterList){ - Int_t mSize = 2; - this->SetMarkerColor(kGreen); - this->SetNextPoint(cog.x(), cog.y(), cog.z()); - this->SetMarkerStyle(31); - this->SetMarkerSize(mSize); - this->SetPickable(kTRUE); - ClusterList->AddElement(this); - } -} - diff --git a/TEveEventDisplay/src/TEveMu2eCustomHelix.cc b/TEveEventDisplay/src/TEveMu2eCustomHelix.cc deleted file mode 100644 index 5bc71b9c63..0000000000 --- a/TEveEventDisplay/src/TEveMu2eCustomHelix.cc +++ /dev/null @@ -1,23 +0,0 @@ -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h" -#include "Offline/GlobalConstantsService/inc/GlobalConstantsHandle.hh" -#include "Offline/GlobalConstantsService/inc/ParticleDataList.hh" - -using namespace mu2e; -namespace mu2e{ - - TEveMu2eCustomHelix::TEveMu2eCustomHelix(){} - - /*------------Function to build Infor after contruction:-------------*/ - void TEveMu2eCustomHelix::SetSeedInfo(KalSeed seed) { - fKalSeed_ = seed; - auto const& fseg = fKalSeed_.segments().front(); - this->Momentum_ = fseg.mom(); - this->PDGcode_ = fKalSeed_.particle(); - auto const& ptable = mu2e::GlobalConstantsHandle(); - this->Charge_ = ptable->particle(fKalSeed_.particle()).charge(); - this->Mass_ = ptable->particle(fKalSeed_.particle()).mass(); - this->Radius_ = fabs(1.0/fseg.helix().omega()); - this->Time_ = fKalSeed_.t0().t0(); - } - -} diff --git a/TEveEventDisplay/src/TEveMu2eDataInterface.cc b/TEveEventDisplay/src/TEveMu2eDataInterface.cc deleted file mode 100644 index 6f75c03259..0000000000 --- a/TEveEventDisplay/src/TEveMu2eDataInterface.cc +++ /dev/null @@ -1,759 +0,0 @@ -#include "Offline/GeometryService/inc/GeomHandle.hh" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eDataInterface.h" - -#include - -using namespace mu2e; -using namespace std; -namespace mu2e{ - - /*------------Function delete previous event from display:-------------*/ - template void DataLists(T data, bool Redraw, bool accumulate, std::string title, TEveElementList **List3D, TEveElementList **List2DXY = 0, TEveElementList **List2DXZ = 0 , U projection = 0){ - if(data == 0 && Redraw){ - if (*List3D != 0){ - (*List3D)->DestroyElements(); - } - - if (*List2DXY != 0){ - (*List2DXY)->DestroyElements(); - - projection->fXYMgr->ImportElements(*List2DXY, projection->fDetXYScene); - - }if (*List2DXZ != 0){ - (*List2DXZ)->DestroyElements(); - - projection->fRZMgr->ImportElements(*List2DXZ, projection->fDetRZScene); - } - gEve->AddElement(*List3D); - gEve->Redraw3D(kTRUE); - } - if(data!=0){ - if (*List3D== 0) { - *List3D = new TEveElementList((title + "3D").c_str()); - if(!accumulate){(*List3D)->DestroyElements();} if(!accumulate){(*List3D)->DestroyElements();} - } - else { - (*List3D)->DestroyElements(); - } - if (*List2DXY== 0) { - *List2DXY = new TEveElementList((title + "2D").c_str()); - (*List2DXY)->IncDenyDestroy(); - } - else { - if (!accumulate){(*List2DXY)->DestroyElements();} - } - } - if (*List2DXZ== 0) { - *List2DXZ = new TEveElementList((title + "2D").c_str()); - (*List2DXZ)->IncDenyDestroy(); - } - else { - if (!accumulate){(*List2DXZ)->DestroyElements();} - } - } - - /*------------Function to get max and min energy in an event from the colour scheme:-------------*/ - template void maxminE(L data, double &max, double &min){ - - auto order = std::minmax_element(data->begin(), data->end(), - [] (auto const& lhs, auto const& rhs) { return lhs.energyDep() < rhs.energyDep(); }); - - int min_pos = order.first - data->begin(); - int max_pos = order.second - data->begin(); - min = data->at(min_pos).energyDep(); - max = data->at(max_pos).energyDep(); - } - /*------------Function to get max and min time for time selection:-------------*/ - template void maxminT(L data, double &max, double &min){ - - auto order = std::minmax_element(data->begin(), data->end(), - [] (auto const& lhs, auto const& rhs) { return lhs.time() < rhs.time(); }); - - int min_pos = order.first - data->begin(); - int max_pos = order.second - data->begin(); - - min = data->at(min_pos).time(); - max = data->at(max_pos).time(); - - } - /*------------Function to get CRV information since the words are different:-------------*/ - template void maxminCRV(L data, double &max, double &min){ - auto order = std::minmax_element(data->begin(), data->end(), - [] (auto const& lhs, auto const& rhs) { return lhs.GetPulseTime() < rhs.GetPulseTime(); }); - int min_pos = order.first - data->begin(); - int max_pos = order.second - data->begin(); - min = data->at(min_pos).GetPulseTime(); - max = data->at(max_pos).GetPulseTime(); - } - - /*------------Function to build energy list:-------------*/ - template std::vector Energies(L data, int *energylevels[]){ - std::vector energies = {0, 0}; - double Max_Energy = 0; - double Min_Energy = 1000; - maxminE(data, Max_Energy, Min_Energy); - - double interval = (Max_Energy - Min_Energy)/(9); - - for(unsigned int i=0; isize();i++){ - for(unsigned int n=0; n<9;n++){ - if(((*data)[i]).energyDep() >= Min_Energy + n * interval && ((*data)[i]).energyDep() <=Min_Energy + (n+1)*interval){ - (*energylevels)[i] = n;} - } - } - energies.at(0) = Min_Energy; - energies.at(1) = Max_Energy; - - return energies; - } - - /*------------Function to build time ordering:-------------*/ - std::vector TEveMu2eDataInterface::getTimeRange(bool firstloop, const ComboHitCollection *chcol, const CrvRecoPulseCollection *crvcoincol, const CaloClusterCollection *clustercol, const CaloHitCollection *cryHitcol, bool addCRVInfo, bool addHits, bool addCalo){ - std::vector time = {-1, -1}; - double max, min; - std::vector alltime; - - if(addCRVInfo){ - if(crvcoincol->size() !=0){ - maxminCRV(crvcoincol, max, min); - alltime.push_back(max); - alltime.push_back(min); - } - } - - if(addHits){ - if (chcol->size() != 0){ - maxminT(chcol, max, min); - alltime.push_back(max); - alltime.push_back(min); - } - } - - if (addCalo){ - if(clustercol->size() !=0){ - maxminT(clustercol, max, min); - alltime.push_back(max); - alltime.push_back(min); - } - } - - if(alltime.size() !=0){ - auto order = std::minmax_element(alltime.begin(), alltime.end(), - [] (auto const& lhs, auto const& rhs) { return lhs < rhs; }); - int min_pos = order.first - alltime.begin(); - int max_pos = order.second - alltime.begin(); - time.at(0) = alltime.at(min_pos); - time.at(1) = alltime.at(max_pos); - } - - if (time.at(0) == -1){time.at(0) = 0;} - if (time.at(1) == -1){time.at(1) = 100;} - return time; - } - - /*------------Function to add CRV information to the display:-------------*/ - void TEveMu2eDataInterface::AddCRVInfo(bool firstloop, const CrvRecoPulseCollection *crvcoincol, double min_time, double max_time, TEveMu2e2DProjection *CRV2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - - DataLists(crvcoincol, Redraw, accumulate, "CRVRecoPulse", &fCrvList3D, &fCrvList2DXY,&fCrvList2DYZ, CRV2Dproj); - - if(crvcoincol->size() !=0){ - - TEveElementList *CrvList2DXY = new TEveElementList("CrvData2DXY"); - TEveElementList *CrvList2DYZ = new TEveElementList("CrvData2DYZ"); - TEveElementList *CrvList3D = new TEveElementList("CrvData3D"); - GeomHandle CRS; - for(unsigned int i=0; i size(); i++) - { - const CrvRecoPulse &crvRecoPulse = crvcoincol->at(i); - TEveMu2eCRVEvent *teve_crv3D = new TEveMu2eCRVEvent(crvRecoPulse); - TEveMu2eCRVEvent *teve_crv2DXY = new TEveMu2eCRVEvent(crvRecoPulse); - TEveMu2eCRVEvent *teve_crv2DYZ = new TEveMu2eCRVEvent(crvRecoPulse); - const CRSScintillatorBarIndex &crvBarIndex = crvRecoPulse.GetScintillatorBarIndex(); - const CRSScintillatorBar &crvCounter = CRS->getBar(crvBarIndex); - CLHEP::Hep3Vector crvCounterPos = crvCounter.getPosition(); - //GeomHandle det; - //CLHEP::Hep3Vector pointInMu2e = (det->toMu2e(crvCounterPos)); - hep3vectormmTocm(crvCounterPos ); - CLHEP::Hep3Vector pointInMu2e =crvCounterPos; - string pos3D = "(" + to_string((double)crvCounterPos.x()) + ", " + to_string((double)crvCounterPos.y()) + ", " + to_string((double)crvCounterPos.z()) + ")"; - if((min_time == -1 && max_time == -1) or (crvRecoPulse.GetPulseTime() > min_time and crvRecoPulse.GetPulseTime() < max_time)){ - teve_crv3D->DrawHit3D("CRVHits3D, Position = " + pos3D + ", Pulse Time = " + to_string(crvRecoPulse.GetPulseTime()) + ", Pulse Height = "+ - to_string(crvRecoPulse.GetPulseHeight()) + "Pulse Width = " + to_string(crvRecoPulse.GetPulseTime()), i + 1, pointInMu2e, CrvList3D); - - teve_crv2DXY->DrawHit2DXY("CRVHits2D, Position = " + pos3D + ", Pulse Time = " + to_string(crvRecoPulse.GetPulseTime()) + ", Pulse Height = "+ to_string(crvRecoPulse.GetPulseHeight()) + "Pulse Width = " + - to_string(crvRecoPulse.GetPulseTime()), i + 1, crvCounterPos, CrvList2DXY); - teve_crv2DYZ->DrawHit2DYZ("CRVHits2D, Position = " + pos3D + ", Pulse Time = " + to_string(crvRecoPulse.GetPulseTime()) + ", Pulse Height = "+ to_string(crvRecoPulse.GetPulseHeight()) + "Pulse Width = " + - to_string(crvRecoPulse.GetPulseTime()), i + 1, crvCounterPos, CrvList2DYZ); - fCrvList3D->AddElement(CrvList3D); - fCrvList2DXY->AddElement(CrvList2DXY); - fCrvList2DYZ->AddElement(CrvList2DYZ); - } - } - - CRV2Dproj->fXYMgr->ImportElements(fCrvList2DXY, CRV2Dproj->fEvtXYScene); - CRV2Dproj->fRZMgr->ImportElements(fCrvList2DYZ, CRV2Dproj->fEvtRZScene); - - gEve->AddElement(fCrvList3D); - gEve->Redraw3D(kTRUE); - } - } - - - - /*------------Function to add ComboHits to Tracker in 3D and 2D displays:-------------*/ - std::vector TEveMu2eDataInterface::AddComboHits(bool firstloop, const ComboHitCollection *chcol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, double min_energy, double max_energy, double min_time, double max_time, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - - std::vector energies = {0,0}; - DataLists(chcol, Redraw, accumulate, "ComboHit", &fHitsList3D, &fHitsList2DXY, &fHitsList2DXZ, tracker2Dproj); - /* - TXYMgr->ImportElements(fHitsList2D, scene1); - TRZMgr->ImportElements(fHitsList2D, scene2); */ - if(chcol!=0){ - TEveElementList *HitList2DXY = new TEveElementList("ComboHits2DXY"); - TEveElementList *HitList2DXZ = new TEveElementList("ComboHits2DXZ"); - TEveElementList *HitList3D = new TEveElementList("ComboHits3D"); - - int *energylevels = new int[chcol->size()]; - energies = Energies(chcol, &energylevels); - - for(size_t i=0; isize();i++){ - ComboHit hit = (*chcol)[i]; - TEveMu2eHit *teve_hit2DXY = new TEveMu2eHit(hit); - TEveMu2eHit *teve_hit2DXZ = new TEveMu2eHit(hit); - TEveMu2eHit *teve_hit3D = new TEveMu2eHit(hit); - - CLHEP::Hep3Vector HitPos(hit.pos().x(), hit.pos().y(), hit.pos().z()); - GeomHandle det; - CLHEP::Hep3Vector pointInMu2e0 = (det->toMu2e(HitPos)); - hep3vectormmTocm(HitPos); - CLHEP::Hep3Vector pointInMu2e(pointmmTocm(pointInMu2e0.x()), pointmmTocm(pointInMu2e0.y()), pointmmTocm(pointInMu2e0.z())); - string energy = to_string(teve_hit3D->GetEnergy()); - string pos3D = "(" + to_string((double)pointInMu2e.x()) + ", " + to_string((double)pointInMu2e.y()) + ", " + to_string((double)pointInMu2e.z()) + ")"; - string pos2D = "(" + to_string((double)hit.pos().x()) + ", " + to_string((double)hit.pos().y()) + ", " + to_string((double)hit.pos().z()) + ")"; - if (((min_time == -1 && max_time== -1) || (hit.time() > min_time && hit.time() < max_time)) && ((hit.energyDep() >= min_energy && hit.energyDep() <= max_energy) || (min_energy == -1 && max_energy == -1))){ - teve_hit3D->DrawHit3D("ComboHits3D, Position = " + pos3D + ", Energy = " + energy + ", Time = " + to_string(hit.time()) + ", ", i + 1, pointInMu2e, energylevels[i], HitList3D); - teve_hit2DXY->DrawHit2DXY("ComboHits2D, Position = " + pos2D + ", Energy = " + energy + ", Time = " + to_string(hit.time()) + ", ", i + 1, HitPos,energylevels[i], HitList2DXY); - teve_hit2DXZ->DrawHit2DXZ("ComboHits2D, Position = " + pos2D + ", Energy = " + energy + ", Time = " + to_string(hit.time()) + ", ", i + 1, HitPos,energylevels[i], HitList2DXZ); - - fHitsList2DXY->AddElement(HitList2DXY); - fHitsList2DXZ->AddElement(HitList2DXZ); - fHitsList3D->AddElement(HitList3D); - } - } - tracker2Dproj->fXYMgr->ImportElements(fHitsList2DXY, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fHitsList2DXZ, tracker2Dproj->fEvtRZScene); - /*TXYMgr->ImportElements(fHitsList2D, scene1); - TRZMgr->ImportElements(fHitsList2D, scene2);*/ - gEve->AddElement(HitList3D); - gEve->Redraw3D(kTRUE); - } - return energies; - } - - /*------------Function to add TimeCluster Collection in 3D and 2D displays:-------------*/ - void TEveMu2eDataInterface::AddTimeClusters(bool firstloop, const TimeClusterCollection *tccol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - - DataLists(tccol, Redraw, accumulate, "TCHit", &fTCHitsList3D, &fTCHitsList2DXY, &fTCHitsList2DXZ, tracker2Dproj); - GeomHandle det; - if(tccol!=0){ - for(size_t i=0; isize();i++){ - TimeCluster const &tclust= (*tccol)[i]; - CLHEP::Hep3Vector HitPos(tclust._pos.x(), tclust._pos.y(), tclust._pos.z()); - CLHEP::Hep3Vector pointInMu2e = det->toMu2e(HitPos); - TEvePointSet *trkhit = new TEvePointSet(); - trkhit ->SetMarkerStyle(9); - trkhit ->SetMarkerSize(2); - trkhit ->SetMarkerColor(kCyan); - trkhit ->SetNextPoint(pointmmTocm(HitPos.x()),pointmmTocm(HitPos.y()),pointmmTocm(HitPos.z())); - trkhit ->SetPickable(kTRUE); - - TEvePointSet *trkhityz = new TEvePointSet(); - trkhityz ->SetMarkerStyle(9); - trkhityz ->SetMarkerSize(2); - trkhityz ->SetMarkerColor(kCyan); - trkhityz ->SetNextPoint(pointmmTocm(HitPos.x()),pointmmTocm(HitPos.y()),pointmmTocm(HitPos.z())); - trkhityz ->SetPickable(kTRUE); - - TEvePointSet *trkhit3d = new TEvePointSet(); - trkhit3d ->SetMarkerStyle(9); - trkhit3d ->SetMarkerSize(2); - trkhit3d ->SetMarkerColor(kCyan); - trkhit3d ->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - trkhit3d ->SetPickable(kTRUE); - fTCHitsList2DXY->AddElement(trkhit); - fTCHitsList2DXZ->AddElement(trkhityz); - fTCHitsList3D->AddElement(trkhit3d); - - } - tracker2Dproj->fXYMgr->ImportElements(fTCHitsList2DXY, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fTCHitsList2DXZ, tracker2Dproj->fEvtRZScene); - gEve->AddElement(fTCHitsList3D); - gEve->Redraw3D(kTRUE); - } - } - - -using LHPT = KalSeed::LHPT; -using CHPT = KalSeed::CHPT; -using KLPT = KalSeed::KLPT; -template void TEveMu2eDataInterface::AddKinKalTrajectory( std::unique_ptr const& trajectory, TEveMu2eCustomHelix *line, TEveMu2eCustomHelix *line_twoDXY, TEveMu2eCustomHelix *line_twoDXZ){ - double t1=trajectory->range().begin(); - double t2=trajectory->range().end(); - - double x1=trajectory->position3(t1).x(); - double y1=trajectory->position3(t1).y(); - double z1=trajectory->position3(t1).z(); - GeomHandle det; - XYZVectorF pos(x1,y1,z1); - CLHEP::Hep3Vector p = GenVector::Hep3Vec(pos); - CLHEP::Hep3Vector InMu2e = det->toMu2e(p); - line->SetPoint(0,pointmmTocm(InMu2e.x()), pointmmTocm(InMu2e.y()) , pointmmTocm(InMu2e.z())); - line_twoDXY->SetPoint(0,pointmmTocm(x1), pointmmTocm(y1) , pointmmTocm(z1)); - line_twoDXZ->SetPoint(0,pointmmTocm(x1), pointmmTocm(y1) , pointmmTocm(z1)); - for(double t=t1; t<=t2; t+=0.01) - { - const auto &p = trajectory->position3(t); - double xt=p.x(); - double yt=p.y(); - double zt=p.z(); - XYZVectorF pos(x1,y1,z1); - CLHEP::Hep3Vector pmu2e = GenVector::Hep3Vec(pos); - CLHEP::Hep3Vector InMu2e = det->toMu2e(pmu2e); - line->SetNextPoint(pointmmTocm(InMu2e.x()), pointmmTocm(InMu2e.y()) , pointmmTocm(InMu2e.z())); - line_twoDXY->SetNextPoint(pointmmTocm(xt), pointmmTocm(yt), pointmmTocm(zt)); - line_twoDXZ->SetNextPoint(pointmmTocm(xt), pointmmTocm(yt), pointmmTocm(zt)); - } -} - -void TEveMu2eDataInterface::FillKinKalTrajectory(bool firstloop, std::tuple, std::vector> track_tuple, TEveMu2e2DProjection *tracker2Dproj, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - std::cout<<"[REveMu2eDataInterface] AddKinKalTracks "< track_list = std::get<1>(track_tuple); - std::vector names = std::get<0>(track_tuple); - std::vector colour; - - for(unsigned int j=0; j< track_list.size(); j++){ - const KalSeedCollection* seedcol = track_list[j]; - colour.push_back(j+3); - if(seedcol!=0){ - for(unsigned int k = 0; k < seedcol->size(); k++){ - mu2e::KalSeed kseed = (*seedcol)[k]; - TEveMu2eCustomHelix *line = new TEveMu2eCustomHelix(); - TEveMu2eCustomHelix *line_twoDXY = new TEveMu2eCustomHelix(); - TEveMu2eCustomHelix *line_twoDXZ = new TEveMu2eCustomHelix(); - line->fKalSeed_ = kseed; - line->SetSeedInfo(kseed); - - if(kseed.loopHelixFit()) - { - auto trajectory=kseed.loopHelixFitTrajectory(); - AddKinKalTrajectory(trajectory, line, line_twoDXY,line_twoDXZ); - } - else if(kseed.centralHelixFit()) - { - auto trajectory=kseed.centralHelixFitTrajectory(); - AddKinKalTrajectory(trajectory,line,line_twoDXY,line_twoDXZ); - } - else if(kseed.kinematicLineFit()) - { - auto trajectory=kseed.kinematicLineFitTrajectory(); - AddKinKalTrajectory(trajectory,line,line_twoDXY,line_twoDXZ); - } - - line_twoDXY->SetLineColor(kOrange); - line_twoDXY->SetLineWidth(3); - fTrackList2DXY->AddElement(line_twoDXY); - - line_twoDXZ->SetLineColor(kOrange); - line_twoDXZ->SetLineWidth(3); - fTrackList2DXZ->AddElement(line_twoDXZ); - - line->SetPickable(kTRUE); - line->SetLineColor(kOrange); - line->SetLineWidth(3); - fTrackList3D->AddElement(line); - } - tracker2Dproj->fXYMgr->ImportElements(fTrackList2DXY, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fTrackList2DXZ, tracker2Dproj->fEvtRZScene); - gEve->AddElement(fTrackList3D); - gEve->Redraw3D(kTRUE); - } - } - } - - - - /*------------Function to color code the Tracker hits in 3D and 2D displays:-------------*/ - void TEveMu2eDataInterface::AddTrkHits(bool firstloop, const ComboHitCollection *chcol,std::tuple, std::vector> track_tuple, TEveMu2e2DProjection *tracker2Dproj,bool Redraw, double min_energy, double max_energy, double min_time, double max_time, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - std::vector track_list = std::get<1>(track_tuple); - std::vector names = std::get<0>(track_tuple); - GeomHandle det; - StrawId trksid[70]; - unsigned int trkhitsize=0; - //Save the hit straw IDs of the KalSeed hits - for(unsigned int j=0; j< track_list.size(); j++){ - const KalSeedCollection* seedcol = track_list[j]; - DataLists(seedcol, Redraw, accumulate, "HelixTrack", &fTrackList3D, &fTrackList2DXY,&fTrackList2DXZ, tracker2Dproj); - if(seedcol!=0){ - for(unsigned int k = 0; k < seedcol->size(); k++){ - KalSeed kseed = (*seedcol)[k]; - const std::vector &hits = kseed.hits(); - trkhitsize = hits.size(); - for(unsigned int i=0; i usedtrksid(trkhitsize); - vector usedid(trkhitsize); - DataLists(chcol, Redraw, accumulate, "ComboHit", &fTrkHitsList3D, &fTrkHitsList2DXY, &fTrkHitsList2DXZ, tracker2Dproj); - //Compare the straw IDs of the Kal seed hits with the hits in the ComboHit Collection - if(chcol!=0){ - for(unsigned int i=0; isize();i++){ - ComboHit hit = (*chcol)[i]; - for(unsigned int q=0; qtoMu2e(HitPos); - TEvePointSet *trkhit = new TEvePointSet(); - trkhit ->SetMarkerStyle(9); - trkhit ->SetMarkerSize(1); - trkhit ->SetMarkerColor(kGreen-4); - trkhit ->SetNextPoint(pointmmTocm(HitPos.x()),pointmmTocm(HitPos.y()),pointmmTocm(HitPos.z())); - trkhit ->SetPickable(kTRUE); - - TEvePointSet *trkhityz = new TEvePointSet(); - trkhityz ->SetMarkerStyle(9); - trkhityz ->SetMarkerSize(1); - trkhityz ->SetMarkerColor(kGreen-4); - trkhityz ->SetNextPoint(pointmmTocm(HitPos.x()),pointmmTocm(HitPos.y()),pointmmTocm(HitPos.z())); - trkhityz ->SetPickable(kTRUE); - - TEvePointSet *trkhit3d = new TEvePointSet(); - trkhit3d ->SetMarkerStyle(9); - trkhit3d ->SetMarkerSize(1); - trkhit3d ->SetMarkerColor(kGreen-4); - trkhit3d ->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - trkhit3d ->SetPickable(kTRUE); - fTrkHitsList2DXY->AddElement(trkhit); - fTrkHitsList2DXZ->AddElement(trkhityz); - fTrkHitsList3D->AddElement(trkhit3d); - } - } - } - //Hits which are not in the ComboHit Collection of the helix - for(unsigned int i = 0;i < trkhitsize;i++){ - if(i != usedid[i] && isize()){ - ComboHit chhit = (*chcol)[i]; - CLHEP::Hep3Vector HitPos(chhit.pos().x(), chhit.pos().y(), chhit.pos().z()); - CLHEP::Hep3Vector pointInMu2e = det->toMu2e(HitPos); - TEvePointSet *notusedtrkhit = new TEvePointSet(); - notusedtrkhit ->SetMarkerStyle(9); - notusedtrkhit ->SetMarkerSize(1); - notusedtrkhit ->SetNextPoint(pointmmTocm(HitPos.x()),pointmmTocm(HitPos.y()),pointmmTocm(HitPos.z())); - notusedtrkhit ->SetMarkerColor(kRed-4); - notusedtrkhit ->SetPickable(kTRUE); - - TEvePointSet *notusedtrkhityz = new TEvePointSet(); - notusedtrkhityz ->SetMarkerStyle(9); - notusedtrkhityz ->SetMarkerSize(1); - notusedtrkhityz ->SetMarkerColor(kRed-4); - notusedtrkhityz ->SetNextPoint(pointmmTocm(HitPos.x()),pointmmTocm(HitPos.y()),pointmmTocm(HitPos.z())); - notusedtrkhityz ->SetPickable(kTRUE); - - TEvePointSet *notusedtrkhit3d = new TEvePointSet(); - notusedtrkhit3d ->SetMarkerStyle(9); - notusedtrkhit3d ->SetMarkerSize(1); - notusedtrkhit3d ->SetMarkerColor(kRed-4); - notusedtrkhit3d ->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - notusedtrkhit3d ->SetPickable(kTRUE); - fTrkHitsList3D->AddElement(notusedtrkhit3d); - fTrkHitsList2DXY->AddElement(notusedtrkhit); - fTrkHitsList2DXZ->AddElement(notusedtrkhityz); - } - } - tracker2Dproj->fXYMgr->ImportElements(fTrkHitsList2DXY, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fTrkHitsList2DXZ, tracker2Dproj->fEvtRZScene); - gEve->AddElement(fTrkHitsList3D); - gEve->Redraw3D(kTRUE); - } - } - - - - /*------------Function to add Calo Clusters to 3D and 2D display:-------------*/ - std::vector TEveMu2eDataInterface::AddCaloClusters(bool firstloop, const CaloClusterCollection *clustercol, TEveMu2e2DProjection *calo2Dproj, bool Redraw, double min_energy, double max_energy, double min_time, double max_time, bool accumulate, TEveProjectionManager *CfXYMgr, TEveProjectionManager *CfRZMgr, TEveScene *scene1, TEveScene *scene2) { - vector energies = {0, 0}; - - DataLists(clustercol, Redraw, accumulate, "CaloCluster", &fClusterList3D, &fClusterList2D_disk0, &fClusterList2D_disk0,calo2Dproj); - DataLists(clustercol, Redraw, accumulate, "CaloCluster", &fClusterList3D, &fClusterList2D_disk1, &fClusterList2D_disk1,calo2Dproj); - //CfXYMgr->ImportElements(fClusterList2D_disk0, scene1); - //CfRZMgr->ImportElements(fClusterList2D_disk1, scene2); - - if(clustercol->size()!=0){ - TEveElementList *ClusterList3D = new TEveElementList("CaloClusters3D"); - TEveElementList *ClusterList2D_disk0 = new TEveElementList("CaloClusters2D_Disk0"); - TEveElementList *ClusterList2D_disk1 = new TEveElementList("CaloClusters2D_Disk1"); - int *energylevels = new int[clustercol->size()]; - energies = Energies(clustercol, &energylevels); - Calorimeter const &cal = *(GeomHandle()); - std::vector hits; - bool addHits = false; //To add crystal hits - bool addCrystals = true; // To highlight the crystals included in a give cluster - for(unsigned int i=0; isize();i++){ - CaloCluster const &cluster= (*clustercol)[i]; - TEveMu2eCluster *teve_cluster3D = new TEveMu2eCluster(cluster); - TEveMu2eCluster *teve_cluster2D = new TEveMu2eCluster(cluster); - - if(addCrystals){ - for(unsigned h =0 ; h < cluster.caloHitsPtrVector().size();h++) { - TEvePointSet *crystals2D = new TEvePointSet(); - art::Ptr crystalhit = cluster.caloHitsPtrVector()[h]; - int cryID = crystalhit->crystalID(); - - int diskID = cal.crystal(crystalhit->crystalID()).diskID(); - Crystal const &crystal = cal.crystal(cryID); - double crystalXLen = pointmmTocm(crystal.size().x()); - double crystalYLen = pointmmTocm(crystal.size().y()); - double crystalZLen = pointmmTocm(crystal.size().z()); - - Double_t origin[3]; - crystals2D ->SetMarkerStyle(9); - crystals2D ->SetMarkerSize(1); - crystals2D ->SetMarkerColor(kRed); - GeomHandle det; - CLHEP::Hep3Vector crystalPos = det->toMu2e(cal.geomUtil().mu2eToDiskFF(0,crystal.position())); - hep3vectormmTocm(crystalPos); - origin [0] = crystalPos.x(); - origin [1] = crystalPos.y(); - origin [2] = crystalPos.z(); - TEveGeoShape *crystalShape = new TEveGeoShape(); - crystalShape->SetFillColor(kRed); - crystalShape->SetShape(new TGeoBBox("cryHit", (crystalXLen/2), (crystalYLen/2), pointmmTocm((crystalZLen/2)), origin)); - crystals2D->SetNextPoint(origin [0],origin [1],origin [2]); - - if(diskID == 0){ - fClusterList2D_disk0->AddElement(crystals2D); - crystals2D->SetPickable(kTRUE); - std::string info = "Crystal Id: "+to_string(cryID)+" Disk Id: "+to_string(diskID)+" Energy Dep: "+to_string(crystalhit->energyDep()) + "+/-"+to_string(crystalhit->energyDepErr())+" time: "+to_string(crystalhit->time())+" +/- "+to_string(crystalhit->timeErr())+" pos "+to_string(origin[0])+" "+to_string(origin[1]); - crystals2D->SetTitle((info).c_str()); - } - if(diskID == 1){ - fClusterList2D_disk1->AddElement(crystals2D); - crystals2D->SetPickable(kTRUE); - std::string info = "Crystal Id: "+to_string(cryID)+" Disk Id: "+to_string(diskID)+" Energy Dep: "+to_string(crystalhit->energyDep()) + "+/-"+to_string(crystalhit->energyDepErr())+" time: "+to_string(crystalhit->time())+" +/- "+to_string(crystalhit->timeErr())+" pos "+to_string(origin[0])+" "+to_string(origin[1]); - crystals2D->SetTitle((info).c_str()); - } - } - } - - CLHEP::Hep3Vector COG(cluster.cog3Vector().x(),cluster.cog3Vector().y(), cluster.cog3Vector().z()); - CLHEP::Hep3Vector pointInMu2e3D(cal.geomUtil().diskToMu2e(cluster.diskID(),COG)); - hep3vectormmTocm(pointInMu2e3D); - GeomHandle det; - CLHEP::Hep3Vector pointInMu2e2D = det->toMu2e(COG); - hep3vectormmTocm(pointInMu2e2D); - - string pos3D = "(" + to_string(pointmmTocm((double)pointInMu2e3D.x())) + ", " + to_string(pointmmTocm((double)pointInMu2e3D.y())) + ", " + to_string(pointmmTocm((double)pointInMu2e3D.z())) + ")"; - string pos2D = "(" + to_string((double)pointInMu2e2D.x()) + ", " + to_string((double)pointInMu2e2D.y()) + ", " + to_string((double)pointInMu2e2D.z()) + ")"; - - if (((min_time == -1 && max_time == -1) || (cluster.time() > min_time && cluster.time() < max_time )) && ((cluster.energyDep() >= min_energy && cluster.energyDep() <= max_energy) || (min_energy == -1 && max_energy == -1))){ - teve_cluster3D->DrawCluster("CaloCluster3D, Cluster #" + to_string(i + 1) + ", Position =" + pos3D + ", Energy = " + to_string(cluster.energyDep()) + "+/- " + to_string(cluster.energyDepErr()) + ", Time = " + to_string(cluster.time()) + " +/- " + to_string(cluster.timeErr()),pointInMu2e3D, energylevels[i], ClusterList3D, hits, addHits); - fClusterList3D->AddElement(ClusterList3D); - - if(cluster.diskID()==0){ - teve_cluster2D->DrawCluster("CaloCluster3D, Cluster #" + to_string(i + 1) + ", Position =" + pos2D + ", Energy = " + to_string(cluster.energyDep()) + "+/- " + to_string(cluster.energyDepErr()) + ", Time = " + to_string(cluster.time()) + " +/- " + to_string(cluster.timeErr()), pointInMu2e2D, energylevels[i], ClusterList2D_disk0, hits, addHits); - fClusterList2D_disk0->AddElement(ClusterList2D_disk0); - calo2Dproj->fXYMgr->ImportElements(fClusterList2D_disk0, calo2Dproj->fDetXYScene); - //CfXYMgr->ImportElements(fClusterList2D_disk0, scene1); For Multiview - - } - if(cluster.diskID()==1){ - teve_cluster2D->DrawCluster("CaloCluster3D, Cluster #" + to_string(i + 1) + ", Position =" + pos2D + ", Energy = " + to_string(cluster.energyDep()) + "+/- " + to_string(cluster.energyDepErr()) + ", Time = " + to_string(cluster.time())+ " +/- " + to_string(cluster.timeErr()), pointInMu2e2D,energylevels[i], ClusterList2D_disk1, hits, addHits); - fClusterList2D_disk1->AddElement(ClusterList2D_disk1); - calo2Dproj->fRZMgr->ImportElements(fClusterList2D_disk1, calo2Dproj->fDetRZScene); - //CfRZMgr->ImportElements(fClusterList2D_disk1, scene2); For MultiView - } - } - } - gEve->AddElement(fClusterList3D); - gEve->Redraw3D(kTRUE); - } - return energies; - } - - /*------------Function to add Crystal hits to 2D and 3D Calo displays:-------------*/ - void TEveMu2eDataInterface::AddCrystalHits(bool firstloop, const CaloHitCollection *cryHitcol, TEveMu2e2DProjection *calo2Dproj, double min_time, double max_time, bool Redraw, bool accumulate, TEveProjectionManager *CfXYMgr, TEveProjectionManager *CfRZMgr, TEveScene *scene1, TEveScene *scene2){ - vector energies = {0, 0}; - Calorimeter const &cal = *(GeomHandle()); - - DataLists(cryHitcol, Redraw, accumulate, "CrystalHit", &fHitsList3D, &fHitsList2DXY,&fHitsList2DXZ, calo2Dproj); - /*CfXYMgr->ImportElements(fClusterList2D_disk0, scene1); - CfRZMgr->ImportElements(fClusterList2D_disk1, scene2); */ - if(cryHitcol!=0){ - - TEveElementList *HitList = new TEveElementList("CrystalHits"); - int *energylevels = new int[cryHitcol->size()]; - - energies = Energies(cryHitcol, &energylevels); - - for(unsigned int i=0; isize();i++){ - TEveMu2eHit *teve_hit = new TEveMu2eHit(); - CaloHit const &hit = (*cryHitcol)[i]; - int diskID = cal.crystal(hit.crystalID()).diskID(); - CLHEP::Hep3Vector HitPos(cal.geomUtil().mu2eToDiskFF(diskID, cal.crystal(hit.crystalID()).position())); - CLHEP::Hep3Vector pointInMu2e(cal.geomUtil().diskToMu2e(diskID,HitPos)); - hep3vectormmTocm(pointInMu2e); - if (((min_time == -1 && max_time == -1) || (hit.time() > min_time && hit.time() < max_time ))){ - teve_hit->DrawHit3D("CrystalHits", 1, pointInMu2e, energylevels[i], HitList); - fCrystalHitList->AddElement(HitList); - } - } - /*CfXYMgr->ImportElements(fClusterList2D_disk0, scene1); - CfRZMgr->ImportElements(fClusterList2D_disk1, scene2); */ - gEve->AddElement(fCrystalHitList); - gEve->Redraw3D(kTRUE); - } - } - - /*------------Function to add Kalman Reco Helix to the display:-------------*/ - void TEveMu2eDataInterface::AddHelixPieceWise3D(bool firstloop, std::tuple, std::vector> track_tuple, TEveMu2e2DProjection *tracker2Dproj, double min_time, double max_time, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - - std::vector track_list = std::get<1>(track_tuple); - std::vector names = std::get<0>(track_tuple); - std::vector colour; - for(unsigned int j=0; j< track_list.size(); j++){ - const KalSeedCollection* seedcol = track_list[j]; - colour.push_back(j+3); - DataLists(seedcol, Redraw, accumulate, "HelixTrack", &fTrackList3D, &fTrackList2DXY,&fTrackList2DXZ, tracker2Dproj); - - /*TXYMgr->ImportElements(fTrackList2D, scene1); - TRZMgr->ImportElements(fTrackList2D, scene2); */ - if(seedcol!=0){ - for(unsigned int k = 0; k < seedcol->size(); k = k + 20){ - KalSeed kseed = (*seedcol)[k]; - const std::vector &segments = kseed.segments(); - size_t nSegments=segments.size(); - if(nSegments==0) continue; - const mu2e::KalSegment &segmentFirst = kseed.segments().front(); - const mu2e::KalSegment &segmentLast = kseed.segments().back(); - double fltLMin=segmentFirst.fmin(); - double fltLMax=segmentLast.fmax(); - TEveMu2eCustomHelix *line = new TEveMu2eCustomHelix(); - TEveMu2eCustomHelix *line_twoDXY = new TEveMu2eCustomHelix(); - TEveMu2eCustomHelix *line_twoDXZ = new TEveMu2eCustomHelix(); - line->fKalSeed_ = kseed; - line->SetSeedInfo(kseed); - - for(size_t m=0; m0){ - double fltLMaxPrev=segments.at(m-1).fmax(); - fltLMin=(fltLMin+fltLMaxPrev)/2.0; - } - if(m+1 det; - XYZVectorF pos; - segment.helix().position(fltL,pos); - CLHEP::Hep3Vector p = GenVector::Hep3Vec(pos); - CLHEP::Hep3Vector InMu2e = det->toMu2e(p); - line->SetNextPoint(pointmmTocm(InMu2e.x()), pointmmTocm(InMu2e.y()), pointmmTocm(InMu2e.z())); - line_twoDXY->SetNextPoint(pointmmTocm(p.x()), pointmmTocm(p.y()), pointmmTocm(p.z())); - line_twoDXZ->SetNextPoint(pointmmTocm(p.x()), pointmmTocm(p.y()), pointmmTocm(p.z())); - } - } - - line_twoDXY->SetLineColor(colour[j]); - line_twoDXY->SetLineWidth(3); - fTrackList2DXY->AddElement(line_twoDXY); - - line_twoDXZ->SetLineColor(colour[j]); - line_twoDXZ->SetLineWidth(3); - fTrackList2DXZ->AddElement(line_twoDXZ); - - line->SetPickable(kTRUE); - const std::string title = "Helix: " + names[j] + "PDG Code = " + to_string(line->PDGcode_) +", Momentum = " + to_string(line->Momentum_)+ ", Time = " + to_string(line->Time_); - line->SetTitle(Form(title.c_str())); - line->SetLineColor(colour[j]); - line->SetLineWidth(3); - fTrackList3D->AddElement(line); - } - - /*TXYMgr->ImportElements(fTrackList2D, scene1); - TRZMgr->ImportElements(fTrackList2D, scene2);*/ - tracker2Dproj->fXYMgr->ImportElements(fTrackList2DXY, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fTrackList2DXZ, tracker2Dproj->fEvtRZScene); - gEve->AddElement(fTrackList3D); - gEve->Redraw3D(kTRUE); - } - - } - } - - /*------------Function to add No Field cosmic track fit to 2D and 3D display:-------------*/ - void TEveMu2eDataInterface::AddCosmicTrack(bool firstloop, const CosmicTrackSeedCollection *cosmiccol, TEveMu2e2DProjection *tracker2Dproj, double min_time, double max_time, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - if(cosmiccol !=0){ - DataLists(cosmiccol, Redraw, accumulate,"CosmicTrack", &fTrackList3D, &fTrackList2DXY,&fTrackList2DXZ, tracker2Dproj); - /*TXYMgr->ImportElements(fTrackList2D, scene1); - TRZMgr->ImportElements(fTrackList2D, scene2);*/ - TEveMu2eStraightTrack *line = new TEveMu2eStraightTrack(); - TEveMu2eStraightTrack *line2DXY = new TEveMu2eStraightTrack(); - TEveMu2eStraightTrack *line2DXZ = new TEveMu2eStraightTrack(); - for(unsigned int ist = 0; ist < cosmiccol->size(); ++ist){ - - CosmicTrackSeed sts =(*cosmiccol)[ist]; - CosmicTrack st = sts._track; - - line->SetLineColor(kGreen); - - double endY = 0; - double startY = 0; - - endY = sts._straw_chits[sts._straw_chits.size()-1].pos().y(); - startY = sts._straw_chits[0].pos().y(); - - Float_t ty1 = startY; - Float_t ty2 = endY; - Float_t tx1 = st.MinuitParams.A0 - st.MinuitParams.A1*ty1; - Float_t tx2 = st.MinuitParams.A0 - st.MinuitParams.A1*ty2; - Float_t tz1 = st.MinuitParams.B0 - st.MinuitParams.B1*ty1; - Float_t tz2 = st.MinuitParams.B0 - st.MinuitParams.B1*ty2; - line->AddLine((tx1-3904), (ty1), (tz1+10171), (tx2-3904), (ty2), (tz2+10171)); - const std::string title = "CosmicTrack #" + to_string(ist + 1) + ", Parameters: A0:" + to_string(st.MinuitParams.A0) + ", A1:" + to_string(st.MinuitParams.A1) + ", B0:" + to_string(st.MinuitParams.B0) + ", B1:" + to_string(st.MinuitParams.B1); - line->SetTitle(Form(title.c_str())); - - line2DXY->AddLine(tx1, ty1, tz1, tx2, ty2, tz2); - line2DXY->SetPickable(kTRUE); - line2DXY->SetLineColor(kGreen); - line2DXY->SetLineWidth(3); - fTrackList2DXY->AddElement(line2DXY); - - line2DXZ->AddLine(tx1, ty1, tz1, tx2, ty2, tz2); - line2DXZ->SetPickable(kTRUE); - line2DXZ->SetLineColor(kGreen); - line2DXZ->SetLineWidth(3); - fTrackList2DXZ->AddElement(line2DXZ); - - line->SetPickable(kTRUE); - line->SetLineColor(kGreen); - line->SetLineWidth(3); - fTrackList3D->AddElement(line); - } - tracker2Dproj->fXYMgr->ImportElements(fTrackList2DXY, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fTrackList2DXZ, tracker2Dproj->fEvtRZScene); - /*TXYMgr->ImportElements(fTrackList2D, scene1); - TRZMgr->ImportElements(fTrackList2D, scene2);*/ - gEve->AddElement(fTrackList3D); - gEve->Redraw3D(kTRUE); - } - } -} diff --git a/TEveEventDisplay/src/TEveMu2eHit.cc b/TEveEventDisplay/src/TEveMu2eHit.cc deleted file mode 100644 index 8d50dad025..0000000000 --- a/TEveEventDisplay/src/TEveMu2eHit.cc +++ /dev/null @@ -1,174 +0,0 @@ -#include "Offline/GeometryService/inc/DetectorSystem.hh" -#include "Offline/GeometryService/inc/GeomHandle.hh" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h" - -using namespace mu2e; -namespace mu2e{ - - TEveMu2eHit::TEveMu2eHit(){} - - /*------------Function to build title:-------------*/ - std::string TEveMu2eHit::DataTitle(const std::string &pstr, int n){ - std::string dstr=" hit#" + std::to_string(n) + "\nLayer: "; - std::string strlab=pstr+dstr; - return (strlab); - } - - /*------------Function to display straws which are hit-------*/ - std::tuple TEveMu2eHit::DrawStraw(){ - mu2e::GeomHandle tracker; - const auto& allStraws = tracker->getStraws(); - CLHEP::Hep3Vector sposi(0.0,0.0,0.0), sposf(0.0,0.0,0.0); - std::string strawtitle; - int colorid = 0; - for (size_t i = 0; inStraws(); i++){ - const mu2e::Straw& s = allStraws[i]; - if(s.id().asUint16()==fComboHit_._sid.asUint16()) - { - const CLHEP::Hep3Vector& p = s.getMidPoint(); - const CLHEP::Hep3Vector& d = s.getDirection(); - int idStraw = s.id().getStraw(); - int idPanel = s.id().getPanel(); - int idPlane = s.id().getPlane(); - colorid = idPlane + idPanel; - strawtitle =Form("Straw %i Panel %i Plane %i",idStraw,idPanel,idPlane); - //std::cout< det; - CLHEP::Hep3Vector sposin = det->toMu2e(sposi); - CLHEP::Hep3Vector sposfn = det->toMu2e(sposf); - TEveMu2eCustomHelix *line = new TEveMu2eCustomHelix(); - line->SetLineWidth(1); - line->SetPoint(0,pointmmTocm(sposin.x()),pointmmTocm(sposin.y()),pointmmTocm(sposin.z())); - line->SetNextPoint(pointmmTocm(sposfn.x()),pointmmTocm(sposfn.y()),pointmmTocm(sposfn.z())); - line->SetLineColor(colorid); - line->SetTitle(Form(title.c_str())); - HitList->AddElement(line); - } - - this->SetTitle((DataTitle(pstr, n)).c_str()); - //hep3vectormmTocm(pointInMu2e); - this->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - int colors[] = {-7, 3, -6, -1, 9, 0, -4, 10, 1}; - this->SetMarkerColor(kSpring + colors[energylevel]); - this->SetPickable(kTRUE); - if(AddErrorBar_){ - TEveLine *error = new TEveLine(); - auto const& p = fComboHit_.pos(); - auto w = fComboHit_.uDir(); - auto const& s = fComboHit_.wireRes(); - double x1 = (p.x()+s*w.x()); - double x2 = (p.x()-s*w.x()); - double z1 = (p.z()+s*w.z()); - double z2 = (p.z()-s*w.z()); - double y1 = (p.y()+s*w.y()); - double y2 = (p.y()-s*w.y()); - std::string errorbar = "ErrorBar Length: %d, %d, %d"; - error->SetTitle(Form(errorbar.c_str(), (x1 - x2), (y1 - y2), (z1 - z2))); - GeomHandle det; - Hep3Vector vec1(x1, y1, z1); - Hep3Vector vec2(x2, y2, z2); - Hep3Vector inDet1 = det->toMu2e(vec1); - Hep3Vector inDet2 = det->toMu2e(vec2); - error->SetPoint(0, pointmmTocm(inDet1.x()),pointmmTocm(inDet1.y()),pointmmTocm(inDet1.z())); - error->SetNextPoint(pointmmTocm(inDet2.x()), pointmmTocm(inDet2.y()),pointmmTocm(inDet2.z())); - error->SetLineColor(kSpring); - error->SetPickable(kTRUE); - HitList->AddElement(error); - } - HitList->AddElement(this); - } - - /*------------Function to 2D draw hits:-------------*/ - void TEveMu2eHit::DrawHit2DXY(const std::string &pstr, Int_t n, CLHEP::Hep3Vector pointInMu2e, int energylevel, TEveElementList *HitList2DXY) - { - auto [sposi, sposf, title, colorid] = DrawStraw(); - if(sposi.x()!=0){ - TEveMu2eCustomHelix *line_twoDstrawXY = new TEveMu2eCustomHelix(); - line_twoDstrawXY->SetLineWidth(1); - line_twoDstrawXY->SetPoint(0,pointmmTocm(sposi.x()),pointmmTocm(sposi.y()),pointmmTocm(sposi.z())); - line_twoDstrawXY->SetNextPoint(pointmmTocm(sposf.x()),pointmmTocm(sposf.y()),pointmmTocm(sposf.z())); - line_twoDstrawXY->SetLineColor(colorid); - line_twoDstrawXY->SetTitle(Form(title.c_str())); - HitList2DXY->AddElement(line_twoDstrawXY); - - } - this->SetTitle((DataTitle(pstr, n)).c_str()); - hep3vectormmTocm(pointInMu2e); - this->SetNextPoint(pointmmTocm(pointInMu2e.x()), pointmmTocm(pointInMu2e.y()), pointmmTocm(pointInMu2e.z())); - int colors[] = {-7, 3, -6, -1, 9, 0, -4, 10, 1}; - this->SetMarkerColor(kSpring + colors[energylevel]); - this->SetPickable(kTRUE); - - if(AddErrorBar_){ - TEveLine *error = new TEveLine(); - auto const& p = fComboHit_.pos(); - auto w = fComboHit_.uDir(); - auto const& s = fComboHit_.wireRes(); - double x1 = (p.x()+s*w.x()); - double x2 = (p.x()-s*w.x()); - double z1 = (p.z()+s*w.z()); - double z2 = (p.z()-s*w.z()); - double y1 = (p.y()+s*w.y()); - double y2 = (p.y()-s*w.y()); - - std::string errorbar = "ErrorBar Length: %d, %d, %d"; - error->SetTitle(Form(errorbar.c_str(), (x1 - x2), (y1 - y2), (z1 - z2))); - error->SetPoint(0, pointmmTocm(x1),pointmmTocm(y1),pointmmTocm(z1)); - error->SetNextPoint(pointmmTocm(x2),pointmmTocm(y2),pointmmTocm(z2)); - error->SetLineColor(kRed); - error->SetPickable(kTRUE); - HitList2DXY->AddElement(error); - } - HitList2DXY->AddElement(this); - } - - void TEveMu2eHit::DrawHit2DXZ(const std::string &pstr, Int_t n, CLHEP::Hep3Vector pointInMu2e, int energylevel, TEveElementList *HitList2DXZ) - { - auto [sposi, sposf, title, colorid] = DrawStraw(); - if(sposi.x()!=0){ - TEveMu2eCustomHelix *line_twoDstrawXZ = new TEveMu2eCustomHelix(); - line_twoDstrawXZ->SetLineWidth(1); - line_twoDstrawXZ->SetPoint(0,pointmmTocm(sposi.x()),pointmmTocm(sposi.y()),pointmmTocm(sposi.z())); - line_twoDstrawXZ->SetNextPoint(pointmmTocm(sposf.x()),pointmmTocm(sposf.y()),pointmmTocm(sposf.z())); - line_twoDstrawXZ->SetLineColor(colorid); - line_twoDstrawXZ->SetTitle(Form(title.c_str())); - HitList2DXZ->AddElement(line_twoDstrawXZ); - } - this->SetTitle((DataTitle(pstr, n)).c_str()); - hep3vectormmTocm(pointInMu2e); - this->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - int colors[] = {-7, 3, -6, -1, 9, 0, -4, 10, 1}; - this->SetMarkerColor(kSpring + colors[energylevel]); - this->SetPickable(kTRUE); - HitList2DXZ->AddElement(this); - } -} - diff --git a/TEveEventDisplay/src/TEveMu2eMCInterface.cc b/TEveEventDisplay/src/TEveMu2eMCInterface.cc deleted file mode 100644 index 067a77dc5b..0000000000 --- a/TEveEventDisplay/src/TEveMu2eMCInterface.cc +++ /dev/null @@ -1,231 +0,0 @@ -#include "Offline/GeometryService/inc/DetectorSystem.hh" -#include "Offline/GeometryService/inc/GeomHandle.hh" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCInterface.h" - -using namespace mu2e; -using namespace std; -namespace mu2e{ - - /*------------Function to clear lists for new events:-------------*/ - template void DataLists(T data, bool Redraw, bool accumulate, string title, TEveElementList **List3D, TEveElementList **List2DXY = 0, TEveElementList **List2DXZ = 0, U projection = 0){ - if(data == 0 && Redraw){ - if (*List3D != 0){ - (*List3D)->DestroyElements(); - } - - if (*List2DXY != 0){ - (*List2DXY)->DestroyElements(); - - projection->fXYMgr->ImportElements(*List2DXY, projection->fDetXYScene); - - }if (*List2DXZ != 0){ - (*List2DXZ)->DestroyElements(); - - projection->fRZMgr->ImportElements(*List2DXZ, projection->fDetRZScene); - } - gEve->AddElement(*List3D); - gEve->Redraw3D(kTRUE); - } - if(data!=0){ - if (*List3D== 0) { - *List3D = new TEveElementList((title + "3D").c_str()); - if(!accumulate){(*List3D)->DestroyElements();} if(!accumulate){(*List3D)->DestroyElements();} - } - else { - (*List3D)->DestroyElements(); - } - if (*List2DXY== 0) { - *List2DXY = new TEveElementList((title + "2D").c_str()); - (*List2DXY)->IncDenyDestroy(); - } - else { - if (!accumulate){(*List2DXY)->DestroyElements();} - } - } - if (*List2DXZ== 0) { - *List2DXZ = new TEveElementList((title + "2D").c_str()); - (*List2DXZ)->IncDenyDestroy(); - } - else { - if (!accumulate){(*List2DXZ)->DestroyElements();} - } - - } - - - /*------------Function to add straight line MC Trajectory i.e. for Comsics in No field:-------------*/ - void TEveMu2eMCInterface::AddSimpleMCTrajectory(bool firstloop, const MCTrajectoryCollection *trajcol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2){ - DataLists(trajcol, Redraw, accumulate, "MC Trajectory", &fTrackList3D, &fTrackList2DXY,&fTrackList2DXZ, tracker2Dproj); - if(trajcol!=0){ - TEveElementList *HitList3D = new TEveElementList("MCtraj3D"); - TEveElementList *HitList2D = new TEveElementList("MCtraj2D"); - std::map,mu2e::MCTrajectory>::const_iterator trajectoryIter; - for(trajectoryIter=trajcol->begin(); trajectoryIter!=trajcol->end(); trajectoryIter++) - { - const std::vector &points = trajectoryIter->second.points(); - string pdgId= to_string(trajectoryIter->first->pdgId()); - CLHEP::Hep3Vector StartHitPos(points[0].x(), points[0].y(), points[0].z()); - CLHEP::Hep3Vector EndHitPos(points[points.size()-1].x(), points[points.size()-1].y(), points[points.size()-1].z()); - TEveMu2eMCTraj *teve_hit3D = new TEveMu2eMCTraj(); - string energy = to_string(points[0].kineticEnergy()); - teve_hit3D->DrawSimpleLine("MCTraj PDG " + pdgId + "Energy = " + energy + ", ", StartHitPos, EndHitPos, HitList3D); - - fTrackList3D->AddElement(HitList3D); - - GeomHandle det; - StartHitPos = det->toMu2e(StartHitPos); - EndHitPos = det->toMu2e(EndHitPos); - TEveMu2eMCTraj *teve_hit2D = new TEveMu2eMCTraj(); - teve_hit2D->DrawSimpleLine("MCTraj PDG " + pdgId + "Energy = " + energy + ", ", StartHitPos, EndHitPos, HitList2D); - fTrackList2DXZ->AddElement(HitList2D); - - } - - tracker2Dproj->fXYMgr->ImportElements(fTrackList2DXZ, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fTrackList2DXZ, tracker2Dproj->fEvtRZScene); - - gEve->AddElement(fTrackList3D); - gEve->Redraw3D(kTRUE); - } - - } - - /*------------Function to help user select a list of PDG codes to display:-------------*/ - int TEveMu2eMCInterface::Contains(const std::vector& v, int x) - { - return std::count(v.begin(), v.end(), std::abs(x)); - } - - - /*------------Function to make label :-------------*/ - TEveText *TEveMu2eMCInterface::GetLabel(int PDGCode, TEveMu2eCustomHelix *line, TEveMu2eCustomHelix *line_twoDXY, TEveMu2eCustomHelix *line_twoDXZ){ - const char* pid = "pid"; - auto t = new TEveText(pid); - Color_t color; - double posy = 0; - double posz = text_z_pos; - t->SetFontSize(fontsize); - switch(PDGCode) { - case PDGCode::e_minus: - color = kRed; - pid = "electron -"; - posy = 140.0; - break; - case PDGCode::e_plus: - color = kYellow; - pid = "positron +"; - posy = 150.0; - break; - case PDGCode::mu_minus: - color = kOrange-7; //used to help distinguish from other lines only - pid = "muon - "; - posy = 160.0; - break; - case PDGCode::mu_plus: - color = kRed-9; - pid = "muon + "; - posy = 170.0; - break; - case PDGCode::pi_minus: - color = kMagenta; - pid = "pion -"; - posy = 180.0; - break; - case PDGCode::pi_plus: - color = kViolet; - pid = "pion +"; - posy = 190.0; - break; - case PDGCode::proton: - color = kBlue; - pid = "proton"; - posy = 2000.0; - break; - case PDGCode::gamma: - color = kOrange; - pid = "gamma"; - posy = 2100.0; - break; - default: - color = kCyan; - pid = "other"; - posy = 2200.0; - break; - } - t->SetText(pid); - t->SetMainColor(color); - line->SetLineColor(color); - line_twoDXZ->SetLineColor(color); - line_twoDXY->SetLineColor(color); - t->RefMainTrans().SetPos(0.0,posy,posz); - - return t; - } - - /*------------ - Function to display MCTracjories of any shape, these are made up of a series of TEveLines, in the same way as Reco Helices: - -------------*/ - void TEveMu2eMCInterface::AddFullMCTrajectory(bool firstloop, const MCTrajectoryCollection *trajcol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2, std::vector particleIds){ - - if(trajcol!=0){ - DataLists(trajcol, Redraw, accumulate, "MC Trajectory", &fTrackList3D, &fTrackList2DXZ, &fTrackList2DXY, tracker2Dproj); - std::map,mu2e::MCTrajectory>::const_iterator trajectoryIter; - for(trajectoryIter=trajcol->begin(); trajectoryIter!=trajcol->end(); trajectoryIter++) - { - TEveMu2eCustomHelix *line = new TEveMu2eCustomHelix(); - TEveMu2eCustomHelix *line_twoDXZ = new TEveMu2eCustomHelix(); - TEveMu2eCustomHelix *line_twoDXY = new TEveMu2eCustomHelix(); - //check user defined list of particles to plot: - int x = Contains(particleIds,trajectoryIter->first->pdgId()); - - if(x == 1){ - - const std::vector &points = trajectoryIter->second.points(); - - for(unsigned int i=0; i det; - CLHEP::Hep3Vector HitPos2D = det->toDetector(Pos); - - if(i==0) { - line->SetPoint(i,pointmmTocm(Pos.x()), pointmmTocm(Pos.y()),pointmmTocm(Pos.z())); - line_twoDXZ->SetPoint(i,pointmmTocm(HitPos2D.x()), pointmmTocm(HitPos2D.y()),pointmmTocm(HitPos2D.z())); - line_twoDXY->SetPoint(i,pointmmTocm(HitPos2D.x()), pointmmTocm(HitPos2D.y()),pointmmTocm(HitPos2D.z())); - - } else { - line->SetNextPoint(pointmmTocm(Pos.x()), pointmmTocm(Pos.y()),pointmmTocm(Pos.z())); - line_twoDXZ->SetNextPoint(pointmmTocm(HitPos2D.x()), pointmmTocm(HitPos2D.y()),pointmmTocm(HitPos2D.z())); - line_twoDXY->SetNextPoint(pointmmTocm(HitPos2D.x()), pointmmTocm(HitPos2D.y()),pointmmTocm(HitPos2D.z())); - } - } - - string energy = to_string(points[0].kineticEnergy()); - - const std::string title = " MCTrajectory "+ energy + " Creation code = " + to_string(trajectoryIter->first->creationCode()) + "Stopping code = " + to_string(trajectoryIter->first->stoppingCode()) + " End Global Time = " + to_string(trajectoryIter->first->endGlobalTime()); - line->SetTitle(Form(title.c_str())); - - //Get PID label: - TEveText *t = GetLabel(trajectoryIter->first->pdgId(), line, line_twoDXZ, line_twoDXY); - line_twoDXZ->SetTitle(Form(title.c_str())); - line_twoDXY->SetTitle(Form(title.c_str())); - line->SetLineWidth(linewidth); - line->SetPickable(kTRUE); - line_twoDXZ->SetLineWidth(linewidth); - line_twoDXZ->SetPickable(kTRUE); - line_twoDXY->SetLineWidth(linewidth); - line_twoDXY->SetPickable(kTRUE); - fTrackList2DXZ->AddElement(line_twoDXZ); - fTrackList2DXY->AddElement(line_twoDXY); - fTrackList3D->AddElement(line); - fTrackList3D->AddElement(t); - } - - else std::cout<<"Warning: No Particles of User-Specified Type In File "<fXYMgr->ImportElements(fTrackList2DXY, tracker2Dproj->fEvtXYScene); - tracker2Dproj->fRZMgr->ImportElements(fTrackList2DXZ, tracker2Dproj->fEvtRZScene); - gEve->AddElement(fTrackList3D); - gEve->Redraw3D(kTRUE); - } - } -} diff --git a/TEveEventDisplay/src/TEveMu2eMCTraj.cc b/TEveEventDisplay/src/TEveMu2eMCTraj.cc deleted file mode 100644 index aee3d084db..0000000000 --- a/TEveEventDisplay/src/TEveMu2eMCTraj.cc +++ /dev/null @@ -1,69 +0,0 @@ -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCTraj.h" - -using namespace mu2e; -namespace mu2e{ - - TEveMu2eMCTraj::TEveMu2eMCTraj(){} - - /*------------Function to make track title:-------------*/ - std::string TEveMu2eMCTraj::DataTitle(const std::string &pstr, Int_t n){ - std::string dstr = ""; - if (n != -1){dstr=" hit#" + std::to_string(n) + "\nLayer: ";} - std::string strlab=pstr+dstr; - return (strlab); - } - - /*------------Function to draw 3D line:-------------*/ - void TEveMu2eMCTraj::DrawHit3D(const std::string &pstr, Int_t n, CLHEP::Hep3Vector pointInMu2e, TEveElementList *HitList) - { - this->SetTitle((DataTitle(pstr, n)).c_str()); - hep3vectormmTocm(pointInMu2e); - this->SetNextPoint(pointInMu2e.x(), pointInMu2e.y(), pointInMu2e.z()); - this->SetMarkerColor(kBlue); - this->SetMarkerSize(2); - this->SetPickable(kTRUE); - HitList->AddElement(this); - } - - /*------------Function to draw straight line:-------------*/ - void TEveMu2eMCTraj::DrawSimpleLine(const std::string &pstr, CLHEP::Hep3Vector Start, CLHEP::Hep3Vector End, TEveElementList *HitList) - {//For straight lines only - - this->SetTitle((DataTitle(pstr, -1)).c_str()); - - hep3vectormmTocm(Start); - hep3vectormmTocm(End); - TEveLine *line = new TEveLine(); - - line->SetPoint(0, Start.x(), Start.y(), Start.z()); - line->SetNextPoint(End.x(), End.y(), End.z()); - - line->SetLineColor(kYellow); - this->SetMarkerColor(kYellow); - this->SetMarkerSize(5); - this->SetPickable(kTRUE); - HitList->AddElement(line); - HitList->AddElement(this); - } - - /*------------Function to draw full trajectory:-------------*/ - void TEveMu2eMCTraj::DrawFullLine(const std::string &pstr, CLHEP::Hep3Vector Start, CLHEP::Hep3Vector End, TEveElementList *HitList) - { - std::cout<<"Drawing Line"<SetTitle((DataTitle(pstr, -1)).c_str()); - - hep3vectormmTocm(Start); - hep3vectormmTocm(End); - TEveLine *line = new TEveLine(); - - line->SetPoint(0, Start.x(), Start.y(), Start.z()); - line->SetNextPoint(End.x(), End.y(), End.z()); - - line->SetLineColor(kYellow); - this->SetMarkerColor(kYellow); - this->SetMarkerSize(5); - this->SetPickable(kTRUE); - HitList->AddElement(line); - HitList->AddElement(this); - } -} diff --git a/TEveEventDisplay/src/TEveMu2eMainWindow.cc b/TEveEventDisplay/src/TEveMu2eMainWindow.cc deleted file mode 100644 index 702c3c82d4..0000000000 --- a/TEveEventDisplay/src/TEveMu2eMainWindow.cc +++ /dev/null @@ -1,960 +0,0 @@ -//TEveMu2e: -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMainWindow.h" -#include "Offline/ConfigTools/inc/ConfigFileLookupPolicy.hh" -namespace fhicl -{ - class ParameterSet; -} - -using namespace mu2e; -using namespace std; - - /*------------Function to make colour scheme:-------------*/ - void setRecursiveColorTransp(TGeoVolume *vol, Int_t color, Int_t transp) - { - if(color>=0)vol->SetLineColor(color); - if(transp>=0)vol->SetTransparency(transp); - Int_t nd = vol->GetNdaughters(); - for (Int_t i=0; iGetNode(i)->GetVolume(), color, transp); - } - } - -namespace mu2e{ - - - /*------ Default Constructor ------ */ - TEveMu2eMainWindow::TEveMu2eMainWindow() : TGMainFrame(gClient->GetRoot(), 320, 320){} - - /*------------Function to construct main frame, add buttons and GUI:-------------*/ - TEveMu2eMainWindow::TEveMu2eMainWindow(const TGWindow* p, UInt_t w, UInt_t h, fhicl::ParameterSet _pset, const DrawOptions drawOpts, const GeomOptions geomOpts) : - TGMainFrame(p, w, h), - DrawOpts(drawOpts), - GeomOpts(geomOpts), - fTeRun(0), - fTeEvt(0), - fTTEvt(0), - fTlRun(0), - fTlEvt(0), - fTlTEvt(0), - br(0), - clusterscheck(0), - hitscheck(0), - trackscheck(0), - cosmicscheck(0), - cosmictrkscheck(0), - mctrajcheck(0) - { - //Create TEve Manager: - TEveManager::Create(); - //Create Browser : - gEve->GetBrowser()->GetTabRight()->SetTab(0); - gClient->GetRoot(); - browser = gEve->GetBrowser(); - //Build GUI (function below) - CreateGUI(); - //Build Multiple View Window: - //CreateMultiViews(); --> option for pop up window no deprecated - //Add your Event: - gEve->AddEvent(new TEveEventManager("Event", "Empty Event")); - - } - - /*------------Function to create multiple windows for 2D projections:-------------*/ - void TEveMu2eMainWindow::CreateMultiViews(){ - gEve->GetBrowser()->GetTabRight()->SetTab(0); - - fPad = new TEvePad(); - fPad->SetFillColor(kBlack); - // create the split frames - fSplitFrame = new TGSplitFrame(this, 900, 1300); - AddFrame(fSplitFrame, new TGLayoutHints(kLHintsExpandX | kLHintsExpandY)); - // split it once - fSplitFrame->HSplit(350); - fSplitFrame->GetFirst()->VSplit(410); - fSplitFrame->GetSecond()->VSplit(410); - // get top (main) split frame - frm = fSplitFrame->GetFirst()->GetFirst(); - frm->SetName("Calorimeter_XY_View"); - fViewer0 = new TGLEmbeddedViewer(frm, fPad); - frm->AddFrame(fViewer0->GetFrame(), new TGLayoutHints(kLHintsExpandX | - kLHintsExpandY)); - // set the camera to perspective (XOZ) for this viewer - fViewer0->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - // connect signal we are interested to - - fViewer[0] = new TEveViewer("SplitGLViewer[0]"); - fViewer[0]->SetGLViewer(fViewer0, fViewer0->GetFrame()); - fViewer[0]->IncDenyDestroy(); - if (fIsEmbedded && gEve) { - gEve->GetViewers()->AddElement(fViewer[0]); - proj0 = gEve->SpawnNewScene("Calorimeter XY Scene"); - //fViewer[1]->AddScene(fdetXY); - CfXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - proj0->AddElement(CfXYMgr); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(CfXYMgr); - proj0->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(CfXYMgr,kTRUE); - fViewer[0]->AddScene(proj0); - } - frm = fSplitFrame->GetFirst()->GetSecond(); - frm->SetName("Calorimeter_RZ_View"); - fViewer1 = new TGLEmbeddedViewer(frm, fPad); - frm->AddFrame(fViewer1->GetFrame(), new TGLayoutHints(kLHintsExpandX | - kLHintsExpandY)); - // set the camera to perspective (XOZ) for this viewer - fViewer1->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - // connect signal we are interested to - - fViewer[1] = new TEveViewer("SplitGLViewer[0]"); - fViewer[1]->SetGLViewer(fViewer1, fViewer1->GetFrame()); - fViewer[1]->IncDenyDestroy(); - if (fIsEmbedded && gEve) { - gEve->GetViewers()->AddElement(fViewer[1]); - proj1 = gEve->SpawnNewScene("Calorimeter XY Scene"); - //fViewer[1]->AddScene(fdetXY); - CfRZMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - proj1->AddElement(CfRZMgr); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(CfRZMgr); - proj1->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(CfRZMgr,kTRUE); - fViewer[1]->AddScene(proj1); - } - - frm = fSplitFrame->GetSecond()->GetFirst(); - frm->SetName("Tracker_XY_View"); - fViewer2 = new TGLEmbeddedViewer(frm, fPad); - frm->AddFrame(fViewer2->GetFrame(), new TGLayoutHints(kLHintsExpandX | - kLHintsExpandY)); - // set the camera to perspective (XOZ) for this viewer - fViewer2->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - // connect signal we are interested to - - fViewer[2] = new TEveViewer("SplitGLViewer[2]"); - fViewer[2]->SetGLViewer(fViewer2, fViewer2->GetFrame()); - fViewer[2]->IncDenyDestroy(); - if (fIsEmbedded && gEve) { - gEve->GetViewers()->AddElement(fViewer[2]); - proj2 = gEve->SpawnNewScene("Tracker XY Scene"); - //fViewer[1]->AddScene(fdetXY); - TfXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - proj2->AddElement(TfXYMgr); - TEveProjectionAxes* axes_xytracker = new TEveProjectionAxes(TfXYMgr); - proj2->AddElement(axes_xytracker); - gEve->AddToListTree(axes_xytracker,kTRUE); - gEve->AddToListTree(TfXYMgr,kTRUE); - fViewer[2]->AddScene(proj2); - } - - frm = fSplitFrame->GetSecond()->GetSecond(); - frm->SetName("Tracker_RZ_View"); - fViewer3 = new TGLEmbeddedViewer(frm, fPad); - frm->AddFrame(fViewer3->GetFrame(), new TGLayoutHints(kLHintsExpandX | - kLHintsExpandY)); - // set the camera to perspective (XOZ) for this viewer - fViewer3->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - // connect signal we are interested to - - fViewer[3] = new TEveViewer("SplitGLViewer[3]"); - fViewer[3]->SetGLViewer(fViewer3, fViewer3->GetFrame()); - fViewer[3]->IncDenyDestroy(); - if (fIsEmbedded && gEve) { - gEve->GetViewers()->AddElement(fViewer[3]); - proj3 = gEve->SpawnNewScene("Tracker RZ Scene"); - //fViewer[1]->AddScene(fdetXY); - TfRZMgr = new TEveProjectionManager(TEveProjection::kPT_ZY); - proj3->AddElement(TfRZMgr); - TEveProjectionAxes* axes_xytracker = new TEveProjectionAxes(TfRZMgr); - proj3->AddElement(axes_xytracker); - gEve->AddToListTree(axes_xytracker,kTRUE); - gEve->AddToListTree(TfRZMgr,kTRUE); - fViewer[3]->AddScene(proj3); - } - // create the split frames - fPadCRV = new TEvePad(); - fPadCRV->SetFillColor(kBlack); - - fSplitFrameCRV = new TGSplitFrame(this, 900, 1300); - AddFrame(fSplitFrameCRV, new TGLayoutHints(kLHintsExpandX | kLHintsExpandY)); - // split it once - fSplitFrameCRV->HSplit(350); - //fSplitFrameCRV->GetFirst()->VSplit(410); - //fSplitFrameCRV->GetSecond()->VSplit(410); - //get top (main) split frame - frmCRV = fSplitFrameCRV->GetFirst();//->GetFirst(); - frmCRV->SetName("CRV_XY_View"); - fViewer4 = new TGLEmbeddedViewer(frmCRV, fPadCRV); - frmCRV->AddFrame(fViewer4->GetFrame(), new TGLayoutHints(kLHintsExpandX | kLHintsExpandY)); - // set the camera to perspective (XOZ) for this viewer - fViewer4->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - // connect signal we are interested to - - fViewer[4] = new TEveViewer("SplitGLViewer[4]"); - fViewer[4]->SetGLViewer(fViewer4, fViewer4->GetFrame()); - fViewer[4]->IncDenyDestroy(); - if (fIsEmbedded && gEve) { - gEve->GetViewers()->AddElement(fViewer[4]); - proj4 = gEve->SpawnNewScene("CRV XY Scene"); - //fViewer[1]->AddScene(fdetXY); - CrfXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - proj4->AddElement(CrfXYMgr); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(CrfXYMgr); - proj4->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(CrfXYMgr,kTRUE); - fViewer[4]->AddScene(proj4); - } - - frmCRV = fSplitFrameCRV->GetSecond();//->GetSecond(); - frmCRV->SetName("CRV_YZ_View"); - fViewer5 = new TGLEmbeddedViewer(frmCRV, fPadCRV); - frmCRV->AddFrame(fViewer5->GetFrame(), new TGLayoutHints(kLHintsExpandX | - kLHintsExpandY)); - // set the camera to perspective (XOZ) for this viewer - fViewer5->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - // connect signal we are interested to - - fViewer[5] = new TEveViewer("SplitGLViewer[5]"); - fViewer[5]->SetGLViewer(fViewer5, fViewer5->GetFrame()); - fViewer[5]->IncDenyDestroy(); - if (fIsEmbedded && gEve) { - gEve->GetViewers()->AddElement(fViewer[5]); - proj5 = gEve->SpawnNewScene("CRV YZ Scene"); - //fViewer[1]->AddScene(fdetXY); - CrfRZMgr = new TEveProjectionManager(TEveProjection::kPT_ZY); - proj5->AddElement(CrfRZMgr); - TEveProjectionAxes* axes_xytracker = new TEveProjectionAxes(CrfRZMgr); - proj5->AddElement(axes_xytracker); - gEve->AddToListTree(axes_xytracker,kTRUE); - gEve->AddToListTree(CrfRZMgr,kTRUE); - fViewer[5]->AddScene(proj5); - } - - Resize(GetDefaultSize()); - MapSubwindows(); - MapWindow(); - -} - - /*------------Function to create GUI buttons etc.:-------------*/ - void TEveMu2eMainWindow::CreateGUI(){ - FontStruct_t buttonfont = gClient->GetFontByName("-*-helvetica-medium-r-*-*-8-*-*-*-*-*-iso8859-1"); - GCValues_t gval; - gval.fMask = kGCForeground | kGCFont; - gval.fFont = gVirtualX->GetFontHandle(buttonfont); - gClient->GetColorByName("black", gval.fForeground); - - browser->StartEmbedding(TRootBrowser::kLeft); // insert nav frame as new tab in left pane - - frmMain = new TGMainFrame(gClient->GetRoot(), 1000, 600); - frmMain->SetWindowName("EVT NAV"); - frmMain->SetCleanup(kDeepCleanup); - - TGHorizontalFrame* navFrame = new TGHorizontalFrame(frmMain); - TGVerticalFrame* evtidFrame = new TGVerticalFrame(frmMain); - { - TString icondir(TString::Format("%s/icons/", gSystem->Getenv("ROOTSYS")) ); - - TGPictureButton *b = new TGPictureButton(navFrame, gClient->GetPicture(icondir + "GoBack.gif"),1100); - navFrame->AddFrame(b); - b->Associate(this); - - TGPictureButton *f = new TGPictureButton(navFrame, gClient->GetPicture(icondir + "GoForward.gif"),1001); - navFrame->AddFrame(f); - f->Associate(this); - - // ... Create run num text entry widget and connect to "GotoEvent" rcvr in visutils - TGHorizontalFrame* runoFrame = new TGHorizontalFrame(evtidFrame); - fTlRun = new TGLabel(runoFrame,"Run Number"); - fTlRun->SetTextJustify(kTextLeft); - fTlRun->SetMargins(5,5,5,0); - runoFrame->AddFrame(fTlRun); - - fTeRun = new TGTextEntry(runoFrame, _runNumber = new TGTextBuffer(5), 1); - _runNumber->AddText(0, "Enter Run Number"); - - runoFrame->AddFrame(fTeRun,new TGLayoutHints(kLHintsExpandX)); - fTeRun->Associate(this); - - // ... Create evt num text entry widget and connect to "GotoEvent" rcvr in visutils - TGHorizontalFrame* evnoFrame = new TGHorizontalFrame(evtidFrame); - fTlEvt = new TGLabel(evnoFrame,"Evt Number"); - fTlEvt->SetTextJustify(kTextLeft); - fTlEvt->SetMargins(5,5,5,0); - evnoFrame->AddFrame(fTlEvt); - - fTeEvt = new TGTextEntry(evnoFrame, _eventNumber = new TGTextBuffer(5), 1); - _eventNumber->AddText(0, "Enter Run Number"); - - evnoFrame->AddFrame(fTeEvt,new TGLayoutHints(kLHintsExpandX)); - fTeEvt->Associate(this); - - TGTextButton *Gobutton = new TGTextButton(navFrame, "&Go", 1999); - navFrame->AddFrame(Gobutton, new TGLayoutHints(kLHintsLeft,3,0,3,0)); - Gobutton->Associate(this); - - //Add Mu2e logo - ConfigFileLookupPolicy configFile; - std::string logoFile = configFile("Offline/TEveEventDisplay/src/Icons/mu2e_logo_oval.png"); - const TGPicture *logo = gClient->GetPicture(logoFile.c_str()); - TGIcon *icon = new TGIcon(navFrame,logo,50,50); - navFrame->AddFrame(icon,new TGLayoutHints(kLHintsLeft,20,0,0,0)); - - celabel = new TGLabel(evtidFrame, "Cluster Energy"); - - TGHorizontalFrame *centenergyframe = new TGHorizontalFrame(evtidFrame); - cminenergy = new TGTextEntry(centenergyframe, _clustminenergy = new TGTextBuffer(5), 1701); - _clustminenergy->AddText(0, "0.0"); - centenergyframe->AddFrame(cminenergy,new TGLayoutHints(kLHintsExpandX)); - cminenergy->Associate(this); - spacer = new TGLabel(centenergyframe," "); - centenergyframe->AddFrame(spacer); - cmaxenergy = new TGTextEntry(centenergyframe, _clustmaxenergy = new TGTextBuffer(5), 1701); - _clustmaxenergy->AddText(0, "0.0"); - centenergyframe->AddFrame(cmaxenergy,new TGLayoutHints(kLHintsExpandX)); - cmaxenergy->Associate(this); - - std::string clusterenergy = configFile("Offline/TEveEventDisplay/src/Icons/purplegradient.png"); - const TGPicture *ce = gClient->GetPicture(clusterenergy.c_str()); - TGIcon *ceicon = new TGIcon(evtidFrame, ce, 40, 8); - - helabel = new TGLabel(evtidFrame, "Hit Energy"); - std::string hitenergy = configFile("Offline/TEveEventDisplay/src/Icons/greengradient.png");; - const TGPicture *he = gClient->GetPicture(hitenergy.c_str()); - TGIcon *heicon = new TGIcon(evtidFrame, he, 40 ,8); - - TGHorizontalFrame *hentenergyframe = new TGHorizontalFrame(evtidFrame); - hminenergy = new TGTextEntry(hentenergyframe, _hitminenergy = new TGTextBuffer(5), 1702); - _hitminenergy->AddText(0, "0.0"); - hentenergyframe->AddFrame(hminenergy,new TGLayoutHints(kLHintsExpandX)); - hminenergy->Associate(this); - spacer1 = new TGLabel(hentenergyframe," "); - hentenergyframe->AddFrame(spacer); - hmaxenergy = new TGTextEntry(hentenergyframe, _hitmaxenergy = new TGTextBuffer(5), 1702); - _hitmaxenergy->AddText(0, "0.0"); - hentenergyframe->AddFrame(hmaxenergy,new TGLayoutHints(kLHintsExpandX)); - hmaxenergy->Associate(this); - timelabel = new TGLabel(evtidFrame, "Time Interval [ns]"); - TGHorizontalFrame *henttimeframe = new TGHorizontalFrame(evtidFrame); - hmintime = new TGTextEntry(henttimeframe, _hitmintime = new TGTextBuffer(5), 1703); - _hitmintime->AddText(0, "0.0"); - henttimeframe->AddFrame(hmintime,new TGLayoutHints(kLHintsExpandX)); - hmintime->Associate(this); - spacer1 = new TGLabel(henttimeframe," "); - henttimeframe->AddFrame(spacer); - hmaxtime = new TGTextEntry(henttimeframe, _hitmaxtime = new TGTextBuffer(5), 1703); - _hitmaxtime->AddText(0, "0.0"); - henttimeframe->AddFrame(hmaxtime,new TGLayoutHints(kLHintsExpandX)); - hmaxtime->Associate(this); - - br = new TGButtonGroup(evtidFrame, "Data Products", kVerticalFrame); - clusterscheck = new TGCheckButton(br, new TGHotString("Clusters"), 1200); - clusterscheck->SetState(kButtonDown); - hitscheck = new TGCheckButton(br, new TGHotString("Hits"), 1201); - hitscheck->SetState(kButtonDown); - trackscheck = new TGCheckButton(br, new TGHotString("Tracks"), 1202); - trackscheck->SetState(kButtonDown); - cosmicscheck = new TGCheckButton(br, new TGHotString("Cosmics"), 1203); - cosmicscheck->SetState(kButtonDown); - cosmictrkscheck = new TGCheckButton(br, new TGHotString("Cosmic Tracks"), 1204); - cosmictrkscheck->SetState(kButtonDown); - mctrajcheck = new TGCheckButton(br, new TGHotString("MC Trajectories"), 1205); - mctrajcheck->SetState(kButtonDown); - - // ... Add horizontal run & event number subframes to vertical evtidFrame - evtidFrame->AddFrame(runoFrame,new TGLayoutHints(kLHintsExpandX)); - evtidFrame->AddFrame(evnoFrame,new TGLayoutHints(kLHintsExpandX)); - - evtidFrame->AddFrame(celabel, new TGLayoutHints(kLHintsLeft,3,0,3,0)); - evtidFrame->AddFrame(ceicon, new TGLayoutHints(kLHintsLeft,20,0,0,0)); - evtidFrame->AddFrame(centenergyframe, new TGLayoutHints(kLHintsLeft,3,0,3,0)); - evtidFrame->AddFrame(helabel, new TGLayoutHints(kLHintsLeft,3,0,3,0)); - evtidFrame->AddFrame(heicon, new TGLayoutHints(kLHintsLeft,20,0,0,0)); - evtidFrame->AddFrame(hentenergyframe, new TGLayoutHints(kLHintsLeft,3,0,3,0)); - evtidFrame->AddFrame(timelabel, new TGLayoutHints(kLHintsLeft,3,0,3,0)); - evtidFrame->AddFrame(henttimeframe, new TGLayoutHints(kLHintsLeft,3,0,3,0)); - evtidFrame->AddFrame(br, new TGLayoutHints(kLHintsExpandX)); - - clusterscheck->Associate(this); - hitscheck->Associate(this); - trackscheck->Associate(this); - cosmictrkscheck->Associate(this); - mctrajcheck->Associate(this); - - // ... Add navFrame and evtidFrame to MainFrame - frmMain->AddFrame(navFrame); - TGHorizontal3DLine *separator = new TGHorizontal3DLine(frmMain); - frmMain->AddFrame(separator, new TGLayoutHints(kLHintsExpandX)); - frmMain->AddFrame(evtidFrame); - - frmMain->MapSubwindows(); - frmMain->Resize(); - frmMain->MapWindow(); - - browser->StopEmbedding(); - browser->SetTabTitle("Event Nav", 0); - } - - - } - - /*------------Function to create 2D Tabs:-------------*/ - void TEveMu2eMainWindow::StartProjectionTabs(){ - if(DrawOpts.addCRVInfo) {pass_proj->CreateCRVProjection(CRV2Dproj);} - if(DrawOpts.addClusters or DrawOpts.addCryHits)pass_proj->CreateCaloProjection(calo2Dproj); - pass_proj->CreateTrackerProjection(tracker2Dproj); - } - - /*------------Function to add calo 2D projection to display:-------------*/ - void TEveMu2eMainWindow::CreateCaloProjection(){ - // Create detector and event scenes for ortho views - calo2Dproj->fDetXYScene = gEve->SpawnNewScene("Calo XY D0 Scene", ""); - calo2Dproj->fDetRZScene = gEve->SpawnNewScene("Calo XY D1 Scene", ""); - calo2Dproj->fEvtXYScene = gEve->SpawnNewScene("Calo Evt XY D0 Scene", ""); - calo2Dproj->fEvtRZScene = gEve->SpawnNewScene("Calo Evt XY D1 Scene", ""); - - // Create XY/RZ calo2Dprojection mgrs, draw projected axes, & add them to scenes - calo2Dproj->fXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(calo2Dproj->fXYMgr); - calo2Dproj->fDetXYScene->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(calo2Dproj->fXYMgr,kTRUE); - - calo2Dproj->fRZMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_rz = new TEveProjectionAxes(calo2Dproj->fRZMgr); - calo2Dproj->fDetRZScene->AddElement(axes_rz); - gEve->AddToListTree(axes_rz,kTRUE); - gEve->AddToListTree(calo2Dproj->fRZMgr,kTRUE); - - // Create side-by-side ortho D1, D2 views in new tab & add det/evt scenes - TEveWindowSlot *slot = 0; - TEveWindowPack *pack = 0; - - slot = TEveWindow::CreateWindowInTab(gEve->GetBrowser()->GetTabRight()); - pack = slot->MakePack(); - pack->SetElementName("Calo Views"); - pack->SetHorizontal(); - pack->SetShowTitleBar(kFALSE); - - pack->NewSlot()->MakeCurrent(); - calo2Dproj->fXYView = gEve->SpawnNewViewer("Disk0 View", ""); - calo2Dproj->fXYView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - calo2Dproj->fXYView->AddScene(calo2Dproj->fDetXYScene); - calo2Dproj->fXYView->AddScene(calo2Dproj->fEvtXYScene); - - pack->NewSlot()->MakeCurrent(); - calo2Dproj->fRZView = gEve->SpawnNewViewer("Disk1 View", ""); - calo2Dproj->fRZView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - calo2Dproj->fRZView->AddScene(calo2Dproj->fDetRZScene); - calo2Dproj->fRZView->AddScene(calo2Dproj->fEvtRZScene); - - gEve->GetBrowser()->GetTabRight()->SetTab(0); - } - - /*------------Function to add tracker 2D projection to display:-------------*/ - void TEveMu2eMainWindow::CreateTrackerProjection(){ - // Create detector and event scenes for ortho views - tracker2Dproj->fDetXYScene = gEve->SpawnNewScene("Tracker Det XY Scene", ""); - tracker2Dproj->fDetRZScene = gEve->SpawnNewScene("Tracker Det RZ Scene", ""); - tracker2Dproj->fEvtXYScene = gEve->SpawnNewScene("Tracker Evt XY Scene", ""); - tracker2Dproj->fEvtRZScene = gEve->SpawnNewScene("Tracker Evt RZ Scene", ""); - - // Create XY/RZ tracker2Dprojection mgrs, draw projected axes, & add them to scenes - tracker2Dproj->fXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(tracker2Dproj->fXYMgr); - tracker2Dproj->fDetXYScene->AddElement(axes_xy); - tracker2Dproj->fEvtXYScene->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(tracker2Dproj->fXYMgr,kTRUE); - - tracker2Dproj->fRZMgr = new TEveProjectionManager(TEveProjection::kPT_ZY); - TEveProjectionAxes* axes_rz = new TEveProjectionAxes(tracker2Dproj->fRZMgr); - tracker2Dproj->fDetRZScene->AddElement(axes_rz); - tracker2Dproj->fEvtRZScene->AddElement(axes_rz); - gEve->AddToListTree(axes_rz,kTRUE); - gEve->AddToListTree(tracker2Dproj->fRZMgr,kTRUE); - - // Create side-by-side ortho XY & RZ views in new tab & add det/evt scenes - TEveWindowSlot *slot = 0; - TEveWindowPack *pack = 0; - - slot = TEveWindow::CreateWindowInTab(gEve->GetBrowser()->GetTabRight()); - pack = slot->MakePack(); - pack->SetElementName("Tracker Views"); - pack->SetHorizontal(); - pack->SetShowTitleBar(kFALSE); - - pack->NewSlot()->MakeCurrent(); - tracker2Dproj->fXYView = gEve->SpawnNewViewer("Tracker XY View", ""); - tracker2Dproj->fXYView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - tracker2Dproj->fXYView->AddScene(tracker2Dproj->fDetXYScene); - tracker2Dproj->fXYView->AddScene(tracker2Dproj->fEvtXYScene); - - pack->NewSlot()->MakeCurrent(); - tracker2Dproj->fRZView = gEve->SpawnNewViewer("Tracker RZ View", ""); - tracker2Dproj->fRZView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - tracker2Dproj->fRZView->AddScene(tracker2Dproj->fDetRZScene); - tracker2Dproj->fRZView->AddScene(tracker2Dproj->fEvtRZScene); - - gEve->GetBrowser()->GetTabRight()->SetTab(0); - - } - /*------------Function to add CRV 2D projection to display:-------------*/ - void TEveMu2eMainWindow::CreateCRVProjection(){ - // Create detector and event scenes for ortho views - CRV2Dproj->fDetXYScene = gEve->SpawnNewScene("CRV Det XY Scene", ""); - CRV2Dproj->fDetRZScene = gEve->SpawnNewScene("CRV Det RZ Scene", ""); - CRV2Dproj->fEvtXYScene = gEve->SpawnNewScene("CRV Evt XY Scene", ""); - CRV2Dproj->fEvtRZScene = gEve->SpawnNewScene("CRV Evt RZ Scene", ""); - - // Create XY/RZ CRV2Dprojection mgrs, draw projected axes, & add them to scenes - CRV2Dproj->fXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(CRV2Dproj->fXYMgr); - CRV2Dproj->fDetXYScene->AddElement(axes_xy); - CRV2Dproj->fEvtXYScene->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(CRV2Dproj->fXYMgr,kTRUE); - - // Create side-by-side ortho XY & RZ views in new tab & add det/evt scenes - TEveWindowSlot *slot = 0; - TEveWindowPack *pack = 0; - - slot = TEveWindow::CreateWindowInTab(gEve->GetBrowser()->GetTabRight()); - pack = slot->MakePack(); - pack->SetElementName("CRV XY View"); - pack->SetHorizontal(); - pack->SetShowTitleBar(kFALSE); - - pack->NewSlot()->MakeCurrent(); - CRV2Dproj->fXYView = gEve->SpawnNewViewer("CRV XY View", ""); - CRV2Dproj->fXYView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - CRV2Dproj->fXYView->AddScene(CRV2Dproj->fDetXYScene); - CRV2Dproj->fXYView->AddScene(CRV2Dproj->fEvtXYScene); - - gEve->GetBrowser()->GetTabRight()->SetTab(0); - - CRV2Dproj->fRZMgr = new TEveProjectionManager(TEveProjection::kPT_ZY); - TEveProjectionAxes* axes_rz = new TEveProjectionAxes(CRV2Dproj->fRZMgr); - CRV2Dproj->fDetRZScene->AddElement(axes_rz); - CRV2Dproj->fEvtRZScene->AddElement(axes_rz); - gEve->AddToListTree(axes_rz,kTRUE); - gEve->AddToListTree(CRV2Dproj->fRZMgr,kTRUE); - - TEveWindowSlot *slotnew = 0; - TEveWindowPack *packnew = 0; - slotnew = TEveWindow::CreateWindowInTab(gEve->GetBrowser()->GetTabRight()); - packnew = slotnew->MakePack(); - packnew->SetElementName("CRV YZ View"); - packnew->SetHorizontal(); - packnew->SetShowTitleBar(kFALSE); - packnew->NewSlot()->MakeCurrent(); - CRV2Dproj->fRZView = gEve->SpawnNewViewer("CRV YZ View", ""); - CRV2Dproj->fRZView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - CRV2Dproj->fRZView->AddScene(CRV2Dproj->fDetRZScene); - CRV2Dproj->fRZView->AddScene(CRV2Dproj->fEvtRZScene); - - gEve->GetBrowser()->GetTabRight()->SetTab(0); - - } - - - /*------------Function to create Calo 2D tab:-------------*/ - void TEveMu2eMainWindow::PrepareCaloProjectionTab(const art::Run& run){ - calo2Dproj->fDetXYScene->DestroyElements(); - calo2Dproj->fDetRZScene->DestroyElements(); - - TEveElementList *orthodet0 = new TEveElementList("CaloOrthoDet0"); - TEveElementList *orthodet1 = new TEveElementList("CaloOrthoDet1"); - TGeoVolume* topvol = geom->GetTopVolume(); - Mu2eCalo->DrawCaloDetector(run, topvol,orthodet0,orthodet1); - gEve->AddGlobalElement(orthodet0); - gEve->AddGlobalElement(orthodet1); - - //CfXYMgr->ImportElements(orthodet0); - //CfRZMgr->ImportElements(orthodet1); - - // ... Import elements of the list into the projected views - calo2Dproj->fXYMgr->ImportElements(orthodet0, calo2Dproj->fDetXYScene); - calo2Dproj->fRZMgr->ImportElements(orthodet1, calo2Dproj->fDetRZScene); - - //fXYMgr->ImportElements(orthodet0, fdetXY); - // ... Turn OFF rendering of duplicate detector in main 3D view - gEve->GetGlobalScene()->FindChild("CaloOrthoDet0")->SetRnrState(kFALSE); - gEve->GetGlobalScene()->FindChild("CaloOrthoDet1")->SetRnrState(kFALSE); - - // ... Turn ON rendering of detector in RPhi and RZ views - calo2Dproj->fDetXYScene->FindChild("CaloOrthoDet0 [P]")->SetRnrState(kTRUE); - calo2Dproj->fDetRZScene->FindChild("CaloOrthoDet1 [P]")->SetRnrState(kTRUE); - - } - - /*------------Function to create Tracker 2D tab:-------------*/ - void TEveMu2eMainWindow::PrepareTrackerProjectionTab(const art::Run& run){ - tracker2Dproj->fDetXYScene->DestroyElements(); - tracker2Dproj->fDetRZScene->DestroyElements(); - //fdetXY->DestroyElements(); - - TEveElementList *orthodetXY = new TEveElementList("OrthoDetXY"); - TEveElementList *orthodetXZ = new TEveElementList("OrthoDetXZ"); - //TEveElementList *orthodetsplit = new TEveElementList("OrthoDet"); - - TGeoVolume* topvol = geom->GetTopVolume(); - Mu2eTracker->DrawTrackerDetector(topvol, orthodetXZ, orthodetXY); - //Mu2eTracker->DrawTrackerDetector(run, topvol, orthodetsplit); - - gEve->AddGlobalElement(orthodetXY); - gEve->AddGlobalElement(orthodetXZ); - - // ... Import elements of the list into the projected views - //TfXYMgr->ImportElements(orthodetsplit); - //TfRZMgr->ImportElements(orthodetsplit); - - tracker2Dproj->fXYMgr->ImportElements(orthodetXY, tracker2Dproj->fDetXYScene); - tracker2Dproj->fRZMgr->ImportElements(orthodetXZ, tracker2Dproj->fDetRZScene); - - // ... Turn OFF rendering of duplicate detector in main 3D view - gEve->GetGlobalScene()->FindChild("OrthoDetXY")->SetRnrState(kFALSE); - gEve->GetGlobalScene()->FindChild("OrthoDetXZ")->SetRnrState(kFALSE); - //fdetXY->FindChild("OrthoDet [P]")->SetRnrState(kTRUE); - // ... Turn ON rendering of detector in RPhi and RZ views - tracker2Dproj->fDetXYScene->FindChild("OrthoDetXY [P]")->SetRnrState(kTRUE); - tracker2Dproj->fDetRZScene->FindChild("OrthoDetXZ [P]")->SetRnrState(kTRUE); - - } - - /*------------Function to create CRV tab:-------------*/ - void TEveMu2eMainWindow::PrepareCRVProjectionTab(const art::Run& run){ - - CRV2Dproj->fDetXYScene->DestroyElements(); - CRV2Dproj->fEvtXYScene->DestroyElements(); - - TGeoVolume* topvol = geom->GetTopVolume(); - - //TEveElementList *orthodetT1 = new TEveElementList("CRVT1OrthoDet"); - // TEveElementList *orthodetT2 = new TEveElementList("CRVT2OrthoDet"); - TEveElementList *orthodetT3 = new TEveElementList("CRVT3OrthoDet"); - TEveElementList *orthodetT4 = new TEveElementList("CRVT4OrthoDet"); - //TEveElementList *orthodetlist[] = {orthodetT1, orthodetT2, orthodetT3, orthodetT4}; - - Mu2eCRV->DrawCRVDetector(run, topvol, orthodetT3, orthodetT4); - - //for (unsigned int i=0; i<2; i++){ - gEve->AddGlobalElement(orthodetT3); - gEve->AddGlobalElement(orthodetT4); - // } - - //for (unsigned int i=0; i<2; i++){ - CRV2Dproj->fXYMgr->ImportElements(orthodetT4, CRV2Dproj->fDetXYScene); - CRV2Dproj->fRZMgr->ImportElements(orthodetT4, CRV2Dproj->fDetRZScene); - // } - - // ... Turn OFF rendering of duplicate detector in main 3D view - gEve->GetGlobalScene()->FindChild("CRVT4OrthoDet")->SetRnrState(kFALSE); - gEve->GetGlobalScene()->FindChild("CRVT4OrthoDet")->SetRnrState(kFALSE); - - // ... Turn ON rendering of detector in RPhi and RZ views - CRV2Dproj->fDetXYScene->FindChild("CRVT4OrthoDet [P]")->SetRnrState(kTRUE); - CRV2Dproj->fDetRZScene->FindChild("CRVT4OrthoDet [P]")->SetRnrState(kTRUE); - - } - - /*------------Function to import the GDML and make 3D geometry:-------------*/ - void TEveMu2eMainWindow::SetRunGeometry(const art::Run& run, std::string gdmlname, int _diagLevel){ - if(gGeoManager){ - gGeoManager->GetListOfNodes()->Delete(); - gGeoManager->GetListOfVolumes()->Delete(); - gGeoManager->GetListOfShapes()->Delete(); - } - gEve->GetGlobalScene()->DestroyElements(); - - // Import the GDML of entire Mu2e Geometry - ConfigFileLookupPolicy configFile; - std::string fn = configFile(gdmlname.c_str()); - - geom = mu2e_geom->Geom_Interface::getGeom(fn); - - //Get Top Volume - TGeoVolume* topvol = geom->GetTopVolume(); - - //Set Top Volume for gGeoManager: - gGeoManager->SetTopVolume(topvol); - gGeoManager->SetTopVisible(kTRUE); - int nn = gGeoManager->GetNNodes(); - printf("nodes in geom = %d\n",nn); - - //Get Top Node: - TGeoNode* topnode = gGeoManager->GetTopNode(); - TEveGeoTopNode* etopnode = new TEveGeoTopNode(gGeoManager, topnode); - etopnode->SetVisLevel(4); - etopnode->GetNode()->GetVolume()->SetVisibility(kFALSE); - - setRecursiveColorTransp(etopnode->GetNode()->GetVolume(), kWhite-10,70); - - if(!GeomOpts.showbuilding){ - mu2e_geom->SolenoidsOnly(topnode); - mu2e_geom->hideTop(topnode, _diagLevel); - } - if(GeomOpts.showDSOnly) mu2e_geom->InsideDS(topnode, false ); - if(GeomOpts.showInsidePS) mu2e_geom->InsidePS(topnode, false ); - if(GeomOpts.showCRV) mu2e_geom->InsideCRV(topnode, true); - - //Add static detector geometry to global scene - gEve->AddGlobalElement(etopnode); - geom->Draw("ogl"); - } - - /*------------Function to allow user to recheck the check box, and redraw data:-------------*/ - void TEveMu2eMainWindow::RedrawDataProducts(std::string type){ - if (type == "Clusters"){ - *clusterenergy = pass_data->AddCaloClusters(_firstLoop, _emptydata.clustercol, calo2Dproj,true, fclustmin, fclustmax, ftimemin, ftimemax, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1); - } - if (type == "Hits"){ - if (_data.chcol !=0){*hitenergy = pass_data->AddComboHits(_firstLoop, _emptydata.chcol, tracker2Dproj, true, fhitmin, fhitmax,ftimemin, ftimemax,_accumulate, TfXYMgr, TfRZMgr, proj2, proj3);} - if (_data.tccol !=0){pass_data->AddTimeClusters(_firstLoop, _emptydata.tccol, tracker2Dproj, true, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3);} - if (_data.chcol !=0){pass_data->AddTrkHits(_firstLoop, _emptydata.chcol, _emptydata.track_tuple, tracker2Dproj, true, fhitmin, fhitmax,ftimemin, ftimemax,_accumulate, TfXYMgr, TfRZMgr, proj2, proj3);} - if(_data.cryHitcol !=0){pass_data->AddCrystalHits(_firstLoop, _emptydata.cryHitcol, calo2Dproj, ftimemin, ftimemax, true, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1);} - - } - if (type == "Tracks"){ - pass_data->AddHelixPieceWise3D(_firstLoop, _emptydata.track_tuple, tracker2Dproj, ftimemin, ftimemax, true, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - } - if (type == "Cosmics"){ - if(_data.crvcoincol!= 0){pass_data->AddCRVInfo(_firstLoop, _emptydata.crvcoincol, ftimemin, ftimemax, CRV2Dproj, true, _accumulate, TfXYMgr, TfRZMgr, proj4, proj5); } - } - if (type == "Cosmic Tracks"){std::cout<<"Cosmic tracks "<AddCosmicTrack(_firstLoop, _emptydata.cosmiccol, tracker2Dproj, ftimemin, ftimemax, true, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3);} - } - if (type == "MC Trajectories"){ - if(_data.mctrajcol!=0){pass_mc->AddFullMCTrajectory(_firstLoop, _emptydata.mctrajcol, tracker2Dproj, true, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3, particles);} - } - gSystem->ProcessEvents(); - gClient->NeedRedraw(fTeRun); - gApplication->Run(true); - } - - /*------------Function to call button options:-------------*/ - Bool_t TEveMu2eMainWindow::ProcessMessage(Long_t msg, Long_t param1, Long_t param2){ - switch (GET_MSG(msg)) - { - - case kC_TEXTENTRY: - switch (GET_SUBMSG(msg)){ - case kTE_TEXTCHANGED: - if (param1 == 1701){ - fclustmin = atof(_clustminenergy->GetString()); - fclustmax = atof(_clustmaxenergy->GetString()); - if (fclustmin < fclustmax) {*clusterenergy = pass_data->AddCaloClusters(_firstLoop, _data.clustercol, calo2Dproj, false, fclustmin, fclustmax, ftimemin, ftimemax, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1);} - if (fclustmin > fclustmax){ - std::cout<<"Cluster Minimum Energy is greater than Maximum Energy"<GetRoot(), gClient->GetRoot(), "Event Not Found", msg, kMBIconExclamation,kMBOk); - } - } - if (param1 == 1702){ - fhitmin = atof(_hitminenergy->GetString()); - fhitmax = atof(_hitmaxenergy->GetString()); - //if (fhitmin < fhitmax) {*hitenergy = pass_data->AddComboHits(_firstLoop, _data.chcol, tracker2Dproj, false, fhitmin, fhitmax,ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3);} - //if (fhitmin < fhitmax) {pass_data->AddTrkHits(_firstLoop, _data.chcol, _data.track_tuple, tracker2Dproj, false, fhitmin, fhitmax,ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3);} - if (fhitmin > fhitmax){ - std::cout<<"Hit Minimum Energy is greater than Maximum Energy"<GetRoot(), gClient->GetRoot(), "Event Not Found", msg, kMBIconExclamation,kMBOk); - } - } - if (param1 == 1703){ - ftimemin = atof(_hitmintime->GetString()); - ftimemax = atof(_hitmaxtime->GetString()); - if (ftimemin < ftimemax) { - if(_data.chcol!=0) { - *hitenergy = pass_data->AddComboHits(_firstLoop, _data.chcol, tracker2Dproj, false, fhitmin, fhitmax, ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - pass_data->AddTrkHits(_firstLoop, _data.chcol, _data.track_tuple, tracker2Dproj, false, fhitmin, fhitmax, ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - } - if(_data.tccol!=0) { - pass_data->AddTimeClusters(_firstLoop, _data.tccol, tracker2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - }if(_data.clustercol!=0){ - *clusterenergy = pass_data->AddCaloClusters(_firstLoop, _data.clustercol, calo2Dproj, false, fclustmin, fclustmax,ftimemin, ftimemax, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1); - }if(_data.crvcoincol!=0) { - pass_data->AddCRVInfo(_firstLoop, _data.crvcoincol, ftimemin, ftimemax, CRV2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj4, proj5); - } - } - } - break; - } - break; - case kC_COMMAND: - switch (GET_SUBMSG(msg)) - { - case kCM_CHECKBUTTON: - if(param1==1200){ - if(clusterscheck->IsDown()){ - *clusterenergy = pass_data->AddCaloClusters(_firstLoop, _data.clustercol, calo2Dproj, false, fclustmin, fclustmin, ftimemin, ftimemax, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1);} - if(!clusterscheck->IsDown() && _data.clustercol!=0){RedrawDataProducts("Clusters");} - } - if(param1==1201){ - if(hitscheck->IsDown()){ - *hitenergy = pass_data->AddComboHits(_firstLoop, _data.chcol, tracker2Dproj, false, fhitmin, fhitmax,ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - pass_data->AddTimeClusters(_firstLoop, _data.tccol, tracker2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - pass_data->AddTrkHits(_firstLoop, _data.chcol, _data.track_tuple, tracker2Dproj, false, fhitmin, fhitmax,ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - pass_data->AddCrystalHits(_firstLoop, _data.cryHitcol, calo2Dproj, ftimemin, ftimemax, false, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1); - } - if(!hitscheck->IsDown()){RedrawDataProducts("Hits");} - } - if(param1==1202){ - - if(trackscheck->IsDown()){pass_data->AddHelixPieceWise3D(_firstLoop, _data.track_tuple, tracker2Dproj, ftimemin, ftimemax, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3);} - - if(!trackscheck->IsDown()){RedrawDataProducts("Tracks");} - } - if(param1==1203){ - if(cosmicscheck->IsDown()){ - pass_data->AddCRVInfo(_firstLoop, _data.crvcoincol, ftimemin, ftimemax, CRV2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj4, proj5); - - } - if(!cosmicscheck->IsDown()){RedrawDataProducts("Cosmics");} - } - if(param1==1204){ - if(cosmictrkscheck->IsDown()){ - pass_data->AddCosmicTrack(_firstLoop, _data.cosmiccol, tracker2Dproj, ftimemin, ftimemax, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - } - if(!cosmictrkscheck->IsDown()){RedrawDataProducts("Cosmic Tracks");} - } - if(param1==1205){ - if(mctrajcheck->IsDown()){ - pass_mc->AddFullMCTrajectory(_firstLoop, _data.mctrajcol, tracker2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3, particles); - } - if(!mctrajcheck->IsDown()){RedrawDataProducts("MC Trajectories");} - } - break; - case kCM_BUTTON: - if(param1==1111) - {} - if(param1==1001)//Forward - { - gApplication->Terminate(0); - } - if(param1==1100)//Back - { - std::cout<<"Still developing backwards navigation"<GetText()); - runToFind = atoi(fTeRun->GetText()); - usereventSelected = true; - gApplication->Terminate(0); - } - if(param1==1400){ - //RedrawGeometry(); - } - break; - } - break; - } - return kTRUE; - } - - /*------------Function to add the actual data to the plot (entrance from module):-------------*/ - void TEveMu2eMainWindow::setEvent(const art::Event& event, bool firstLoop, Data_Collections &data, double time, bool accumulate, int &runn, int &eventn, bool &eventSelected, bool isMCOnly) - { - - _event=event.id().event(); - _subrun=event.id().subRun(); - _run=event.id().run(); - _firstLoop = firstLoop; - _accumulate = accumulate; - _data.chcol = data.chcol; - _data.tccol = data.tccol; - _data.clustercol = data.clustercol; - _data.crvcoincol = data.crvcoincol; - _data.track_tuple = data.track_tuple; - _data.mctrajcol = data.mctrajcol; - _data.crvcoincol = data.crvcoincol; - _data.cryHitcol = data.cryHitcol; - _data.cosmiccol = data.cosmiccol; - - std::string eveinfo = Form("Event : %i Run : %i Subrun : %i",_event,_run,_subrun); - auto evinfo = new TEveText(eveinfo.c_str()); - double posy = -140.0; - double posz = 0.0; - evinfo->SetFontSize(15); - evinfo->SetMainColor(kRed); - evinfo->RefMainTrans().SetPos(posz,posy,posz); - gEve->AddElement(evinfo); - if(!isMCOnly){ - std::vector track_list = std::get<1>(data.track_tuple); - std::vector times = pass_data->getTimeRange(firstLoop, data.chcol, data.crvcoincol, data.clustercol, data.cryHitcol, DrawOpts.addCRVInfo, DrawOpts.addComboHits, DrawOpts.addClusters ); - - if(DrawOpts.addCRVInfo){ - pass_data->AddCRVInfo(firstLoop, data.crvcoincol, ftimemin, ftimemax, CRV2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj4, proj5); - } - hitenergy = new vector(2); - - if(DrawOpts.addComboHits) *hitenergy = pass_data->AddComboHits(firstLoop, data.chcol, tracker2Dproj, false, fhitmin, fhitmax,ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - if(DrawOpts.addTrkHits) pass_data->AddTrkHits(firstLoop, data.chcol, data.track_tuple, tracker2Dproj, false, fhitmin, fhitmax,ftimemin, ftimemax, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - if(DrawOpts.addTimeClusters) pass_data->AddTimeClusters(firstLoop, data.tccol, tracker2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - - clusterenergy = new std::vector(2); - - if(DrawOpts.addClusters ) *clusterenergy = pass_data->AddCaloClusters(firstLoop, data.clustercol, calo2Dproj, false, fclustmin, fclustmax, ftimemin, ftimemax, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1); - - if (DrawOpts.addCryHits) pass_data->AddCrystalHits(firstLoop, data.cryHitcol, calo2Dproj, ftimemin, ftimemax, false, _accumulate, CfXYMgr, CfRZMgr, proj0, proj1); - - if (DrawOpts.addTracks) pass_data->AddHelixPieceWise3D(firstLoop, data.track_tuple, tracker2Dproj, ftimemin, ftimemax, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - if (DrawOpts.addTracks) pass_data->FillKinKalTrajectory(firstLoop, data.track_tuple, tracker2Dproj, TfXYMgr, TfRZMgr, proj2, proj3); - - - if(DrawOpts.addCosmicTracks) pass_data->AddCosmicTrack(firstLoop, data.cosmiccol, tracker2Dproj, ftimemin, ftimemax, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3); - - _clustminenergy->Clear(); - _clustmaxenergy->Clear(); - _hitminenergy->Clear(); - _hitmaxenergy->Clear(); - _hitmintime->Clear(); - _hitmaxtime->Clear(); - - _clustminenergy->AddText(0, (to_string(clusterenergy->at(0))).c_str()); - _clustmaxenergy->AddText(0, (to_string(clusterenergy->at(1))).c_str()); - _hitminenergy->AddText(0, (to_string(hitenergy->at(0))).c_str()); - _hitmaxenergy->AddText(0, (to_string(hitenergy->at(1))).c_str()); - _hitmintime->AddText(0, (to_string(times.at(0))).c_str()); - _hitmaxtime->AddText(0, (to_string(times.at(1))).c_str()); - } - - if(DrawOpts.addMCTraj) pass_mc->AddFullMCTrajectory(firstLoop, data.mctrajcol, tracker2Dproj, false, _accumulate, TfXYMgr, TfRZMgr, proj2, proj3, particles); - - gSystem->ProcessEvents(); - gSystem->IgnoreInterrupt(); - gSystem->IgnoreSignal(kSigTermination); - gSystem->IgnoreSignal(kSigSegmentationViolation); - - gClient->NeedRedraw(fTeRun); - - gApplication->Run(true); - - gEve->Redraw3D(kTRUE); - if(usereventSelected == true){ - eventn = eventToFind; - runn = runToFind; - eventSelected = true; - } - delete evinfo; - } - - /*------------Function to find event:-------------*/ - int TEveMu2eMainWindow::getEventToFind(bool &findEvent) const - { - findEvent=_findEvent; - return _eventToFind; - } - - /*------------Function to check if closed:-------------*/ - bool TEveMu2eMainWindow::isClosed() const - { - return _isClosed; - } -} - diff --git a/TEveEventDisplay/src/TEveMu2eProjectionInterface.cc b/TEveEventDisplay/src/TEveMu2eProjectionInterface.cc deleted file mode 100644 index 0ee8224560..0000000000 --- a/TEveEventDisplay/src/TEveMu2eProjectionInterface.cc +++ /dev/null @@ -1,206 +0,0 @@ -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eProjectionInterface.h" - -using namespace mu2e; -namespace mu2e{ - - /*------------Function to add CRV 2D projection to Display:-------------*/ - void TEveMu2eProjectionInterface::CreateCRVProjection(TEveMu2e2DProjection *CRV2Dproj){ - // Create detector and event scenes for ortho views - CRV2Dproj->fDetXYScene = gEve->SpawnNewScene("CRV Top", ""); - CRV2Dproj->fEvtXYScene = gEve->SpawnNewScene("CRV Top event", ""); - - // Create XY/RZ calo2Dprojection mgrs, draw projected axes, & add them to scenes - CRV2Dproj->fXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_xy1 = new TEveProjectionAxes(CRV2Dproj->fXYMgr); - CRV2Dproj->fDetXYScene->AddElement(axes_xy1); - gEve->AddToListTree(axes_xy1,kTRUE); - gEve->AddToListTree(CRV2Dproj->fXYMgr,kTRUE); - - // Create side-by-side ortho D1, D2 views in new tab & add det/evt scenes - TEveWindowSlot *slot = 0; - TEveWindowPack *pack = 0; - - slot = TEveWindow::CreateWindowInTab(gEve->GetBrowser()->GetTabRight()); - pack = slot->MakePack(); - pack->SetElementName("CRV Views"); - pack->SetHorizontal(); - pack->SetShowTitleBar(kFALSE); - - pack->NewSlot()->MakeCurrent(); - CRV2Dproj->fXYView = gEve->SpawnNewViewer("CRV Top View", ""); - CRV2Dproj->fXYView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - CRV2Dproj->fXYView->AddScene(CRV2Dproj->fDetXYScene); - CRV2Dproj->fXYView->AddScene(CRV2Dproj->fEvtXYScene); - } - - - /*------------Function to add calo 2D projection to display:-------------*/ - void TEveMu2eProjectionInterface::CreateCaloProjection(TEveMu2e2DProjection *calo2Dproj){ - // Create detector and event scenes for ortho views - calo2Dproj->fDetXYScene = gEve->SpawnNewScene("Calo XY D0 Scene", ""); - calo2Dproj->fDetRZScene = gEve->SpawnNewScene("Calo XY D1 Scene", ""); - calo2Dproj->fEvtXYScene = gEve->SpawnNewScene("Calo Evt XY D0 Scene", ""); - calo2Dproj->fEvtRZScene = gEve->SpawnNewScene("Calo Evt XY D1 Scene", ""); - - // Create XY/RZ calo2Dprojection mgrs, draw projected axes, & add them to scenes - calo2Dproj->fXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(calo2Dproj->fXYMgr); - calo2Dproj->fDetXYScene->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(calo2Dproj->fXYMgr,kTRUE); - - calo2Dproj->fRZMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_rz = new TEveProjectionAxes(calo2Dproj->fRZMgr); - calo2Dproj->fDetRZScene->AddElement(axes_rz); - gEve->AddToListTree(axes_rz,kTRUE); - gEve->AddToListTree(calo2Dproj->fRZMgr,kTRUE); - - // Create side-by-side ortho D1, D2 views in new tab & add det/evt scenes - TEveWindowSlot *slot = 0; - TEveWindowPack *pack = 0; - - slot = TEveWindow::CreateWindowInTab(gEve->GetBrowser()->GetTabRight()); - pack = slot->MakePack(); - pack->SetElementName("Calo Views"); - pack->SetHorizontal(); - pack->SetShowTitleBar(kFALSE); - - pack->NewSlot()->MakeCurrent(); - calo2Dproj->fXYView = gEve->SpawnNewViewer("Disk0 View", ""); - calo2Dproj->fXYView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - calo2Dproj->fXYView->AddScene(calo2Dproj->fDetXYScene); - calo2Dproj->fXYView->AddScene(calo2Dproj->fEvtXYScene); - - pack->NewSlot()->MakeCurrent(); - calo2Dproj->fRZView = gEve->SpawnNewViewer("Disk1 View", ""); - calo2Dproj->fRZView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - calo2Dproj->fRZView->AddScene(calo2Dproj->fDetRZScene); - calo2Dproj->fRZView->AddScene(calo2Dproj->fEvtRZScene); - - // gEve->GetBrowser()->GetTabRight()->SetTab(0); - } - - /*------------Function to add tracker 2D projection to display:-------------*/ - void TEveMu2eProjectionInterface::CreateTrackerProjection(TEveMu2e2DProjection *tracker2Dproj){ - // Create detector and event scenes for ortho views - tracker2Dproj->fDetXYScene = gEve->SpawnNewScene("Tracker Det XY Scene", ""); - tracker2Dproj->fDetRZScene = gEve->SpawnNewScene("Tracker Det RZ Scene", ""); - tracker2Dproj->fEvtXYScene = gEve->SpawnNewScene("Tracker Evt XY Scene", ""); - tracker2Dproj->fEvtRZScene = gEve->SpawnNewScene("Tracker Evt RZ Scene", ""); - - // Create XY/RZ tracker2Dprojection mgrs, draw projected axes, & add them to scenes - tracker2Dproj->fXYMgr = new TEveProjectionManager(TEveProjection::kPT_RPhi); - TEveProjectionAxes* axes_xy = new TEveProjectionAxes(tracker2Dproj->fXYMgr); - tracker2Dproj->fDetXYScene->AddElement(axes_xy); - gEve->AddToListTree(axes_xy,kTRUE); - gEve->AddToListTree(tracker2Dproj->fXYMgr,kTRUE); - - tracker2Dproj->fRZMgr = new TEveProjectionManager(TEveProjection::kPT_RhoZ); - TEveProjectionAxes* axes_rz = new TEveProjectionAxes(tracker2Dproj->fRZMgr); - tracker2Dproj->fDetRZScene->AddElement(axes_rz); - gEve->AddToListTree(axes_rz,kTRUE); - gEve->AddToListTree(tracker2Dproj->fRZMgr,kTRUE); - - // Create side-by-side ortho XY & RZ views in new tab & add det/evt scenes - TEveWindowSlot *slot = 0; - TEveWindowPack *pack = 0; - - slot = TEveWindow::CreateWindowInTab(gEve->GetBrowser()->GetTabRight()); - pack = slot->MakePack(); - pack->SetElementName("Tracker Views"); - pack->SetHorizontal(); - pack->SetShowTitleBar(kFALSE); - - pack->NewSlot()->MakeCurrent(); - tracker2Dproj->fXYView = gEve->SpawnNewViewer("Tracker XY View", ""); - tracker2Dproj->fXYView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - tracker2Dproj->fXYView->AddScene(tracker2Dproj->fDetXYScene); - tracker2Dproj->fXYView->AddScene(tracker2Dproj->fEvtXYScene); - - pack->NewSlot()->MakeCurrent(); - tracker2Dproj->fRZView = gEve->SpawnNewViewer("Tracker RZ View", ""); - tracker2Dproj->fRZView->GetGLViewer()->SetCurrentCamera(TGLViewer::kCameraOrthoXOY); - tracker2Dproj->fRZView->AddScene(tracker2Dproj->fDetRZScene); - tracker2Dproj->fRZView->AddScene(tracker2Dproj->fEvtRZScene); - - //gEve->GetBrowser()->GetTabRight()->SetTab(0); - - } - -/* - void TEveMu2eMainWindow::PrepareCaloProjectionTab(const art::Run& run){ - calo2Dproj->fDetXYScene->DestroyElements(); - calo2Dproj->fDetRZScene->DestroyElements(); - TEveElementList *orthodet0 = new TEveElementList("CaloOrthoDet0"); - TEveElementList *orthodet1 = new TEveElementList("CaloOrthoDet1"); - TGeoVolume* topvol = geom->GetTopVolume(); - Mu2eCalo->DrawCaloDetector(run, topvol,orthodet0,orthodet1); - - gEve->AddGlobalElement(orthodet0); - gEve->AddGlobalElement(orthodet1); - - // ... Import elements of the list into the projected views - calo2Dproj->fXYMgr->ImportElements(orthodet0, calo2Dproj->fDetXYScene); - calo2Dproj->fRZMgr->ImportElements(orthodet1, calo2Dproj->fDetRZScene); - - // ... Turn OFF rendering of duplicate detector in main 3D view - gEve->GetGlobalScene()->FindChild("OrthoDet")->SetRnrState(kFALSE); - - // ... Turn ON rendering of detector in RPhi and RZ views - calo2Dproj->fDetXYScene->FindChild("CaloOrthoDet0 [P]")->SetRnrState(kTRUE); - calo2Dproj->fDetRZScene->FindChild("CaloOrthoDet1 [P]")->SetRnrState(kTRUE); - } - - void TEveMu2eMainWindow::PrepareTrackerProjectionTab(const art::Run& run){ - tracker2Dproj->fDetXYScene->DestroyElements(); - tracker2Dproj->fDetRZScene->DestroyElements(); - TEveElementList *orthodet = new TEveElementList("OrthoDet"); - TGeoVolume* topvol = geom->GetTopVolume(); - Mu2eTracker->DrawTrackerDetector(run, topvol, orthodet); - - gEve->AddGlobalElement(orthodet); - - // ... Import elements of the list into the projected views - tracker2Dproj->fXYMgr->ImportElements(orthodet, tracker2Dproj->fDetXYScene); - tracker2Dproj->fRZMgr->ImportElements(orthodet, tracker2Dproj->fDetRZScene); - - // ... Turn OFF rendering of duplicate detector in main 3D view - gEve->GetGlobalScene()->FindChild("OrthoDet")->SetRnrState(kFALSE); - - // ... Turn ON rendering of detector in RPhi and RZ views - tracker2Dproj->fDetXYScene->FindChild("OrthoDet [P]")->SetRnrState(kTRUE); - tracker2Dproj->fDetRZScene->FindChild("OrthoDet [P]")->SetRnrState(kTRUE); - } - - void TEveMu2eMainWindow::PrepareCRVProjectionTab(const art::Run& run){ - - CRV2Dproj->fDetXYScene->DestroyElements(); - CRV2Dproj->fEvtXYScene->DestroyElements(); - - TGeoVolume* topvol = geom->GetTopVolume(); - - TEveElementList *orthodetT1 = new TEveElementList("CRVT1OrthoDet"); - TEveElementList *orthodetT2 = new TEveElementList("CRVT2OrthoDet"); - TEveElementList *orthodetT3 = new TEveElementList("CRVT3OrthoDet"); - TEveElementList *orthodetT4 = new TEveElementList("CRVT4OrthoDet"); - TEveElementList *orthodetlist[] = {orthodetT1, orthodetT2, orthodetT3, orthodetT4}; - - Mu2eCRV->DrawCRVDetector(run, topvol, orthodetlist); - - for (unsigned int i=0; i<4; i++){ - gEve->AddGlobalElement(orthodetlist[i]); - } - - for (unsigned int i=0; i<4; i++){ - CRV2Dproj->fXYMgr->ImportElements(orthodetlist[i], CRV2Dproj->fDetXYScene); - } - - // ... Turn OFF rendering of duplicate detector in main 3D view - gEve->GetGlobalScene()->FindChild("OrthoDet")->SetRnrState(kFALSE); - - // ... Turn ON rendering of detector in RPhi and RZ views - //CRV2Dproj->fDetXYScene->FindChild("OrthoDet [P]")->SetRnrState(kTRUE); - //CRV2Dproj->fDetRZScene->FindChild("OrthoDets0 [P]")->SetRnrState(kTRUE); - - }*/ -} diff --git a/TEveEventDisplay/src/TEveMu2eStraightTrack.cc b/TEveEventDisplay/src/TEveMu2eStraightTrack.cc deleted file mode 100644 index 1d8b882834..0000000000 --- a/TEveEventDisplay/src/TEveMu2eStraightTrack.cc +++ /dev/null @@ -1,12 +0,0 @@ -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eStraightTrack.h" - -using namespace mu2e; -namespace mu2e{ - - TEveMu2eStraightTrack::TEveMu2eStraightTrack(){} - - /*------------Function to access position and direction:-------------*/ - XYZVectorF TEveMu2eStraightTrack::GetPositon(){ return fCosmicTrackSeed_->_track.MinuitEquation.Pos; } - XYZVectorF TEveMu2eStraightTrack::GetDirection(){ return fCosmicTrackSeed_->_track.MinuitEquation.Dir; } - -} diff --git a/TEveEventDisplay/src/TEveMu2eTracker.cc b/TEveEventDisplay/src/TEveMu2eTracker.cc deleted file mode 100644 index 4a9491d432..0000000000 --- a/TEveEventDisplay/src/TEveMu2eTracker.cc +++ /dev/null @@ -1,133 +0,0 @@ -#include "Offline/GeometryService/inc/DetectorSystem.hh" -#include "Offline/GeometryService/inc/GeomHandle.hh" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h" -Int_t transpOpt = 100; -using namespace mu2e; -namespace mu2e{ - - TEveMu2eTracker::TEveMu2eTracker(){} - - /*------------Function to construct Tracker (for 2D only):-------------*/ - void TEveMu2eTracker::DrawTrackerDetector(TGeoVolume* topvol, TEveElementList *orthodetXZ, TEveElementList *orthodetXY){ - GeomHandle trkr; - - TubsParams envelope(trkr->g4Tracker()->getInnerTrackerEnvelopeParams()); - TubsParams planeEnvelope(trkr->g4Tracker()->getPlaneEnvelopeParams()); - - Double_t dz{pointmmTocm(envelope.zHalfLength())}; - Double_t zpanel{pointmmTocm(planeEnvelope.zHalfLength())}; - Double_t rmin{pointmmTocm(planeEnvelope.innerRadius())}; - Double_t rmax{pointmmTocm(planeEnvelope.outerRadius())}; - - Double_t fullLength = trkr->planes().back().origin().z()- trkr->planes().front().origin().z(); - Double_t planespace = 2*((pointmmTocm(fullLength) - trkr->nPlanes()*zpanel)/(trkr->nPlanes()-2)); - double p = -dz; - Double_t panelpos[3]; - panelpos [0] = 0.0; - panelpos [1] = 0.0; - //Tracker Planes in XZ - for(size_t i =0;inPlanes()/2;i++) - { - - TEveGeoShape *panel = new TEveGeoShape(); - panelpos [2] = p; - panel->SetShape(new TGeoBBox("panel",rmax+rmin/2,rmax+rmin/2,zpanel*2,panelpos)); - panel->SetMainTransparency(transpOpt); - orthodetXZ->AddElement(panel); - p = p + planespace + zpanel*2; - } - - //XY: - TEveGeoShape *tr = new TEveGeoShape(); - tr->SetShape(new TGeoTube(rmin, rmax, dz)); - tr->SetMainTransparency(transpOpt); - orthodetXY->AddElement(tr); - - // ... Create tracker using the composite shape defined above - TGeoMaterial *mat = new TGeoMaterial("Mylar", 12,6,1.4); - TGeoMedium *My = new TGeoMedium("Mylar",2, mat); - GeomHandle det; - CLHEP::Hep3Vector trackerCentrMu2e = det->getOrigin(); - - TGeoShape *gs = new TGeoTube("Straw Tracker",rmin,rmax,dz); - TGeoVolume *tracker = new TGeoVolume("Straw Tracker ",gs, My); - tracker->SetVisLeaves(kFALSE); - tracker->SetInvisible(); - topvol->AddNode(tracker, 1); - - //Stopping Target - GeomHandle target; - CLHEP::Hep3Vector _detSysOrigin = mu2e::GeomHandle()->getOrigin(); - double stoppingtargetlength = target->cylinderLength(); - double stoppingtargetz = target->centerInMu2e().z() - _detSysOrigin.z(); - double startz = stoppingtargetz - stoppingtargetlength*0.5; - unsigned int nFoils = target->nFoils(); - double j =0.0; - for(unsigned int i=0; i 0) j = j+abs(target->foil(i-1).centerInMu2e().z() - target->foil(i).centerInMu2e().z()); - const mu2e::TargetFoil &foil=target->foil(i); - double halfThickness = foil.halfThickness(); - double r = foil.rOut() - foil.rIn(); - - CLHEP::Hep3Vector center = foil.centerInDetectorSystem(); - - CLHEP::Hep3Vector foilposition(center.x() ,center.y(),pointmmTocm(startz+j)); // Stopping Target Location - - Double_t foilpos[3]; - foilpos [0] = foilposition.x(); - foilpos [1] = foilposition.y(); - foilpos [2] = foilposition.z(); - - TEveGeoShape *stXZ = new TEveGeoShape(); - - stXZ->SetShape(new TGeoBBox("foil",pointmmTocm(r),pointmmTocm(r),pointmmTocm(halfThickness), foilpos)); - stXZ->SetMainTransparency(transpOpt); - orthodetXZ->AddElement(stXZ); - - TEveGeoShape *stXY = new TEveGeoShape(); - stXY->SetShape(new TGeoTube(pointmmTocm(foil.rIn()),pointmmTocm(foil.rOut()),pointmmTocm(halfThickness))); - - stXY->SetMainTransparency(transpOpt); - orthodetXY->AddElement(stXY); - } - - //Calo disk outline in the Tracker XZ display window - GeomHandle calo; - - double diskInnerRingIn = calo->caloInfo().getDouble("diskInnerRingIn"); - double diskOuterRingOut = calo->caloInfo().getDouble("diskOuterRingOut"); - double diskOuterRailOut = diskOuterRingOut + calo->caloInfo().getDouble("diskOutRingEdgeRLength"); - double FPCarbonDZ = calo->caloInfo().getDouble("FPCarbonZLength")/2.0; - double FPFoamDZ = calo->caloInfo().getDouble("FPFoamZLength")/2.0; - double FPCoolPipeRadius = calo->caloInfo().getDouble("FPCoolPipeRadius"); - double pipeRadius = calo->caloInfo().getDouble("pipeRadius"); - double frontPanelHalfThick = (2.0*FPCarbonDZ+2.0*FPFoamDZ-pipeRadius+FPCoolPipeRadius)/2.0; - double holeDZ = calo->caloInfo().getDouble("BPHoleZLength")/2.0; - - double crystalDXY = calo->caloInfo().getDouble("crystalXYLength")*2.0; - double crystalDZ = calo->caloInfo().getDouble("crystalZLength")/2.0; - double wrapperDXY = crystalDXY + calo->caloInfo().getDouble("wrapperThickness"); - - Double_t crystalpos[3]; - for(unsigned int idisk=0; idisknDisks(); idisk++){ - - CLHEP::Hep3Vector diskPos = calo->disk(idisk).geomInfo().origin() + CLHEP::Hep3Vector(0.0, 0.0, (-holeDZ+frontPanelHalfThick)) - _detSysOrigin; - double diskXZwidth = diskOuterRailOut + diskInnerRingIn; - crystalpos [0] = pointmmTocm(diskPos.x()); - crystalpos [2] = pointmmTocm(diskPos.z()); - while(diskXZwidth > -(diskOuterRailOut + diskInnerRingIn)) - { - crystalpos [1] = pointmmTocm(diskPos.y() + diskXZwidth); - - TEveGeoShape *crystalXZ = new TEveGeoShape(); - crystalXZ->SetShape(new TGeoBBox("Crystal",pointmmTocm(wrapperDXY),pointmmTocm(wrapperDXY),pointmmTocm(crystalDZ), crystalpos)); - crystalXZ->SetMainTransparency(transpOpt); - orthodetXZ->AddElement(crystalXZ); - diskXZwidth-=wrapperDXY; - } - } - } -} - - diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h deleted file mode 100644 index a899a8a10f..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h +++ /dev/null @@ -1,31 +0,0 @@ -#ifndef TEveMu2e2DProjection_h -#define TEveMu2e2DProjection_h - -#include -#include -#include -#include - -namespace mu2e { - - class TEveMu2e2DProjection: public TEveProjectionManager { - public: - #ifndef __CINT__ - TEveMu2e2DProjection(){}; - virtual ~TEveMu2e2DProjection(){}; - #endif - TEveViewer *fXYView; - TEveViewer *fRZView; - TEveProjectionManager *fXYMgr; - TEveProjectionManager *fRZMgr; - TEveScene *fDetXYScene; - TEveScene *fDetRZScene; - TEveScene *fEvtXYScene; - TEveScene *fEvtRZScene; - ClassDef(TEveMu2e2DProjection, 0); - }; -} -#endif - - - diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eBField.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eBField.h deleted file mode 100644 index e9b0cdcf73..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eBField.h +++ /dev/null @@ -1,35 +0,0 @@ -#ifndef TEveMu2eBField_h -#define TEveMu2eBField_h - -#include -#include -#include - -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wtautological-compare" -#include "Offline/BFieldGeom/inc/BFieldConfig.hh" -#include "Offline/BFieldGeom/inc/BFieldManager.hh" -#include "Offline/BeamlineGeom/inc/Beamline.hh" -#pragma GCC diagnostic pop - - -//This class will be used in conjunction with the TEveTrack to make helical tracks from the field in the TS and DS. -namespace mu2e { - - class TEveMu2eBField: public TEveMagField { //TEveMagField is defined in TrackPropagator - - Beamline* fBeamline; - BFieldConfig* fBfc; - BFieldManager* fBmgr; - - public: - #ifndef __CINT__ - explicit TEveMu2eBField(){}; - virtual ~TEveMu2eBField(){}; - #endif - //virtual TEveVectorD GetField(Double_t X, Double_t Y, Double_t Z) const ; - //virtual Double_t GetMaxFieldMagD() const; - ClassDef(TEveMu2eBField, 0); -}; -} -#endif diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCRVEvent.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCRVEvent.h deleted file mode 100644 index a3b3a6a61b..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCRVEvent.h +++ /dev/null @@ -1,45 +0,0 @@ -#ifndef TEveMu2eCRVEvent_h -#define TEveMu2eCRVEvent_h - -#include - -#include -#include -#include -#include -#include -#include "Offline/RecoDataProducts/inc/CrvCoincidenceCluster.hh" -#include "Offline/CosmicRayShieldGeom/inc/CosmicRayShield.hh" -#include "Offline/DataProducts/inc/CRSScintillatorBarIndex.hh" -#include "Offline/RecoDataProducts/inc/CrvRecoPulse.hh" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" - -namespace mu2e { - class TEveMu2eCRVEvent : public TEvePointSet { - public: - #ifndef __CINT__ - explicit TEveMu2eCRVEvent(); - TEveMu2eCRVEvent(CrvRecoPulse chit) : fCrvRecoPulse_(chit){}; - virtual ~TEveMu2eCRVEvent(){}; - - CrvCoincidenceCluster fCrvCoincidenceCluster_; - CrvRecoPulse fCrvRecoPulse_; - - Int_t mColor_ = kBlue; - Int_t mSize_ = 1; - bool AddErrorBar_ = true; - - std::tuple DrawSciBar(); - void DrawHit2DXY(const std::string &pstr, Int_t b,CLHEP::Hep3Vector HitPos, TEveElementList *list2DXY); - void DrawHit2DYZ(const std::string &pstr, Int_t b,CLHEP::Hep3Vector HitPos, TEveElementList *list2DYZ); - void DrawHit3D(const std::string &pstr, Int_t b,CLHEP::Hep3Vector HitPos, TEveElementList *list3D); - std::string DataTitle(const std::string &pstr, int n); - #endif - ClassDef(TEveMu2eCRVEvent, 0); - }; - typedef std::vector TEveMu2eCRVEventCollection; -} -#endif - - diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCluster.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCluster.h deleted file mode 100644 index cbd30e517e..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCluster.h +++ /dev/null @@ -1,34 +0,0 @@ -#ifndef TEveMu2eCluster_h -#define TEveMu2eCluster_h - -#include -#include -#include -#include "Offline/RecoDataProducts/inc/CaloCluster.hh" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -#include -#include - - -namespace mu2e { - class TEveMu2eCluster: public TEvePointSet{ - - public: - #ifndef __CINT__ - explicit TEveMu2eCluster(); - TEveMu2eCluster(CaloCluster cluster) : fCaloCluster_(cluster){}; - virtual ~TEveMu2eCluster(){}; - - CaloCluster fCaloCluster_; - - void DrawCluster(const std::string &pstr, CLHEP::Hep3Vector COG, int energylevel, TEveElementList *list, std::vector hits, bool addHits); - void DrawCrystalHits(const std::string &pstr, CLHEP::Hep3Vector COG, TEveElementList *list); - const CLHEP::Hep3Vector GetPositon() { return fCaloCluster_.cog3Vector() ;} - double GetEnergy() { return fCaloCluster_.energyDep();} - std::string DataTitle(const std::string &pstr, double edep); - #endif - ClassDef(TEveMu2eCluster, 0); - }; -} -#endif diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h deleted file mode 100644 index 6a7ce3a19b..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h +++ /dev/null @@ -1,40 +0,0 @@ -#ifndef TEveMu2eCustomHelix_h -#define TEveMu2eCustomHelix_h - -#include -#include -#include -#include "Offline/RecoDataProducts/inc/HelixSeed.hh" -#include "Offline/RecoDataProducts/inc/KalSeed.hh" - -using namespace mu2e; - -namespace mu2e { - class TEveMu2eCustomHelix: public TEveLine { - public: - #ifndef __CINT__ - explicit TEveMu2eCustomHelix(); - TEveMu2eCustomHelix(const TEveMu2eCustomHelix &helix); - virtual ~TEveMu2eCustomHelix(){}; - #endif - - KalSeed fKalSeed_; - HelixSeed fHelixSeed_; - - void DrawHelixTrack(); - void Draw2DProjection(); - - void SetSeedInfo(KalSeed seed); - - XYZVectorF Direction_; - XYZVectorF Position_; - double Momentum_; - int PDGcode_; - double Charge_; - double Mass_; - double Time_; - double Radius_; - ClassDef( TEveMu2eCustomHelix, 0); - }; -} -#endif diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eDataInterface.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eDataInterface.h deleted file mode 100644 index 79655b2c28..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eDataInterface.h +++ /dev/null @@ -1,94 +0,0 @@ -#ifndef TEveMu2eDataInterface_h -#define TEveMu2eDataInterface_h -//ROOT -#include -#include -#include -#include -//libGeom -#include -//TEve -#include -#include -//Mu2e General: -#include "Offline/GeometryService/inc/DetectorSystem.hh" -//TEveMu2e -#include "Offline/TEveEventDisplay/src/dict_classes/Collection_Filler.h" -#include "Offline/TEveEventDisplay/src/dict_classes/Geom_Interface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCRVEvent.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCluster.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eStraightTrack.h" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -#include "Offline/CalorimeterGeom/inc/CaloGeomUtil.hh" -//C++ -#include -#include -#include -#include - -namespace mu2e{ - class TEveMu2eDataInterface { - public: - #ifndef __CINT__ - TEveMu2eDataInterface() : fHitsList2DXY(0),fHitsList2DXZ(0),fHitsList3D(0),fTrkHitsList2DXY(0),fTrkHitsList2DXZ(0),fTrkHitsList3D(0),fTCHitsList2DXY(0),fTCHitsList2DXZ(0),fTCHitsList3D(0), - fCrystalHitList(0),fTrackList2DXY(0),fTrackList2DXZ(0),fTrackList3D(0), fClusterList2D_disk0(0), fClusterList2D_disk1(0), fClusterList3D(0), fCrvList2DXY(0), - fCrvList2DYZ(0), fCrvList3D(0), fExtTrackList2D(0), fExtTrackList3D(0){}; - TEveMu2eDataInterface(const TEveMu2eDataInterface &); - TEveMu2eDataInterface& operator=(const TEveMu2eDataInterface &); - virtual ~TEveMu2eDataInterface(){}; - #endif - bool show2D; - TEveElementList *fHitsList2DXY; - TEveElementList *fHitsList2DXZ; - TEveElementList *fHitsList3D; - TEveElementList *fTrkHitsList2DXY; - TEveElementList *fTrkHitsList2DXZ; - TEveElementList *fTrkHitsList3D; - TEveElementList *fTCHitsList2DXY; - TEveElementList *fTCHitsList2DXZ; - TEveElementList *fTCHitsList3D; - TEveElementList *fCrystalHitList; - TEveElementList *fTrackList2DXY; - TEveElementList *fTrackList2DXZ; - TEveElementList *fTrackList3D; - TEveElementList *fClusterList2D_disk0; - TEveElementList *fClusterList2D_disk1; - TEveElementList *fClusterList3D; - TEveElementList *fCrvList2DXY; - TEveElementList *fCrvList2DYZ; - TEveElementList *fCrvList3D; - TEveElementList *fExtTrackList2D; - TEveElementList *fExtTrackList3D; - - std::vector getTimeRange(bool firstloop, const ComboHitCollection *chcol, const CrvRecoPulseCollection *crvcoincol, const CaloClusterCollection *clustercol, const CaloHitCollection *cryHitcol, bool addCRV, bool addHits, bool addCalo); - - void AddCRVInfo(bool firstloop, const CrvRecoPulseCollection *crvcoincol, double min_time, double max_time, TEveMu2e2DProjection *CRV2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr,TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - std::vector AddComboHits(bool firstloop, const ComboHitCollection *chcol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, double min_energy, double max_energy, double min_time, double max_time, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - - void AddTrkHits(bool firstloop, const ComboHitCollection *chcol, std::tuple, std::vector> track_tuple, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, double min_energy, double max_energy, double min_time, double max_time, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - void AddTimeClusters(bool firstloop, const TimeClusterCollection *tccol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - template void AddKinKalTrajectory( std::unique_ptr const& trajectory, TEveMu2eCustomHelix *line, TEveMu2eCustomHelix *line_twoDXY, TEveMu2eCustomHelix *line_twoDXZ); - void FillKinKalTrajectory(bool firstloop, std::tuple, std::vector> track_tuple, TEveMu2e2DProjection *tracker2Dproj, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - - std::vector AddCaloClusters(bool firstloop, const CaloClusterCollection *clustercol,TEveMu2e2DProjection *calo2Dproj, bool Redraw, double min_energy, double max_energy, double min_time, double max_time, bool accumulate, TEveProjectionManager *CfXYMgr, TEveProjectionManager *CfRZMgr, TEveScene *scene1, TEveScene *scene2); - - void AddCrystalHits(bool firstloop, const CaloHitCollection *cryHitcol, TEveMu2e2DProjection *calo2Dproj, double min_time, double max_time, bool Redraw, bool accumulate, TEveProjectionManager *CfXYMgr, TEveProjectionManager *CfRZMgr, TEveScene *scene1, TEveScene *scene2); - - void AddCosmicTrack(bool firstloop, const CosmicTrackSeedCollection *cosmiccol, TEveMu2e2DProjection *tracker2Dproj, double min_time, double max_time, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - - void AddHelixPieceWise3D(bool firstloop, std::tuple, std::vector> track_tuple, TEveMu2e2DProjection *tracker2Dproj, double min_time, double max_time, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - - void AddHelixPieceWise2D(bool firstloop, std::tuple, std::vector> track_tuple, TEveMu2e2DProjection *tracker2Dproj, double min_time, double max_time, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - - ClassDef(TEveMu2eDataInterface,0); - - }; //end class def - -}//end namespace mu2e - -#endif /*TEveMu2eDataInterface.h*/ diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h deleted file mode 100644 index bb423d6f76..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h +++ /dev/null @@ -1,42 +0,0 @@ -#ifndef TEveMu2eHit_h -#define TEveMu2eHit_h - -#include -#include -#include -#include -#include -#include -#include -#include "Offline/RecoDataProducts/inc/ComboHit.hh" -//Mu2e General: -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h" -#include "Offline/TrackerGeom/inc/Tracker.hh" - -namespace mu2e { - class TEveMu2eHit : public TEvePointSet { - public: - #ifndef __CINT__ - explicit TEveMu2eHit(); - TEveMu2eHit(ComboHit chit) : fComboHit_(chit){}; - virtual ~TEveMu2eHit(){}; - - ComboHit fComboHit_; - Int_t mSize_ = 3; - bool AddErrorBar_ = false; - - std::tuple DrawStraw(); - void DrawHit2DXZ(const std::string &pstr, Int_t b,CLHEP::Hep3Vector HitPos, int energylevel, TEveElementList *listz); - void DrawHit2DXY(const std::string &pstr, Int_t b,CLHEP::Hep3Vector HitPos, int energylevel, TEveElementList *listz); - void DrawHit3D(const std::string &pstr, Int_t b,CLHEP::Hep3Vector HitPos, int energylevel, TEveElementList *list); - void DrawHitCollection(const std::string &pstr, size_t i, std::vector HitPos, int energylevel, TEveElementList *list); - XYZVectorF const GetPosition() { return fComboHit_.pos();} - double GetEnergy(){ return fComboHit_.energyDep();} - std::string DataTitle(const std::string &pstr, int n); - #endif - ClassDef(TEveMu2eHit, 0); - }; - typedef std::vector TEveMu2eHitCollection; -} -#endif diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCInterface.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCInterface.h deleted file mode 100644 index 6978075eb8..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCInterface.h +++ /dev/null @@ -1,51 +0,0 @@ -#ifndef TEveMu2eMCInterface_h -#define TEveMu2eMCInterface_h -//ROOT -#include -#include -#include -#include -#include -//TEve -#include -#include -#include -//Mu2e General: -#include "Offline/GeometryService/inc/DetectorSystem.hh" -#include "Offline/MCDataProducts/inc/MCTrajectoryPoint.hh" -//TEveMu2e -#include "Offline/TEveEventDisplay/src/dict_classes/Collection_Filler.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCTraj.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -namespace mu2e{ - class TEveMu2eMCInterface { - - public: - #ifndef __CINT__ - TEveMu2eMCInterface() : fTrackList2DXY(0),fTrackList2DXZ(0),fTrackList3D(0){}; - TEveMu2eMCInterface(const TEveMu2eMCInterface &); - TEveMu2eMCInterface& operator=(const TEveMu2eMCInterface &); - virtual ~TEveMu2eMCInterface(){}; - void AddSimpleMCTrajectory(bool firstloop, const MCTrajectoryCollection *trajcol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2); - int Contains(const std::vector& list, int x); - TEveText *GetLabel(int PDGCode, TEveMu2eCustomHelix *line, TEveMu2eCustomHelix *line_twoDXY, TEveMu2eCustomHelix *line_twoDXZ); - void AddFullMCTrajectory(bool firstloop, const MCTrajectoryCollection *trajcol, TEveMu2e2DProjection *tracker2Dproj, bool Redraw, bool accumulate, TEveProjectionManager *TXYMgr, TEveProjectionManager *TRZMgr, TEveScene *scene1, TEveScene *scene2, std::vector ids); - #endif - TEveElementList *fTrackList2DXY; - TEveElementList *fTrackList2DXZ; - TEveElementList *fTrackList3D; - std::vector particleIds_; - const Int_t linewidth = 3; - const Int_t fontsize = 15; - const double text_z_pos = 300.; - ClassDef(TEveMu2eMCInterface,0); - - }; //end class def - -}//end namespace mu2e - -#endif /*TEveMu2eMCInterface.h*/ diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCTraj.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCTraj.h deleted file mode 100644 index 58fa3b1c2b..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCTraj.h +++ /dev/null @@ -1,27 +0,0 @@ -#ifndef TEveMu2eMCTraj_h -#define TEveMu2eMCTraj_h - -#include -#include -#include -#include -#include -#include "Offline/RecoDataProducts/inc/ComboHit.hh" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -#include "Offline/ConfigTools/inc/SimpleConfig.hh" -#include "Offline/GeometryService/inc/DetectorSystem.hh" -namespace mu2e { - class TEveMu2eMCTraj : public TEvePointSet{ - public: - #ifndef __CINT__ - explicit TEveMu2eMCTraj(); - virtual ~TEveMu2eMCTraj(){}; - void DrawHit3D(const std::string &pstr, Int_t b,CLHEP::Hep3Vector HitPos, TEveElementList *list); - void DrawSimpleLine(const std::string &pstr, CLHEP::Hep3Vector Start, CLHEP::Hep3Vector End, TEveElementList *HitList); - void DrawFullLine(const std::string &pstr, CLHEP::Hep3Vector Start, CLHEP::Hep3Vector End, TEveElementList *HitList); - std::string DataTitle(const std::string &pstr, Int_t n); - #endif - ClassDef(TEveMu2eMCTraj, 0); - }; -} -#endif diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMainWindow.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMainWindow.h deleted file mode 100644 index 73176d8dd3..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMainWindow.h +++ /dev/null @@ -1,240 +0,0 @@ -#ifndef TEveMu2eMainWindow_h -#define TEveMu2eMainWindow_h - - -// ... libRIO -#include -#include -#include -#include -#include -// ... libGui -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -// ... libRGL -#include -#include -#include -#include -#include -// ... libEve -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -//libGeom -#include -//Mu2e: -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Run.h" - -#include "Offline/ConfigTools/inc/SimpleConfig.hh" -//...TEveMu2e - -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCluster.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCRVEvent.h" -#include "Offline/TEveEventDisplay/src/dict_classes/Geom_Interface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCRV.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eDataInterface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCInterface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eProjectionInterface.h" -class TBox; -class TGTextEntry; -class TPad; -class TGCanvas; -class TRootEmbeddedCanvas; -class TGTextButton; -class TText; -class TGSplitFrame; -class TGLOverlayButton; -namespace mu2e{ - - struct DrawOptions{ - // data options - bool addCRVInfo = false; - bool addCosmicTracks = false; - bool addTracks = false; - bool addClusters = false; - bool addComboHits = false; - bool addTrkHits = false; - bool addTimeClusters = false; - bool addCryHits = false; - bool addMCTraj = false; - bool addKKTracks = false; - DrawOptions(){}; - DrawOptions(bool crv, bool cosmictracks, bool tracks, bool clusters, bool combohits, bool trkhits, bool timeclusters, bool cryhits, bool mctraj, bool kktracks) - : addCRVInfo(crv), addCosmicTracks(cosmictracks), addTracks(tracks), addClusters(clusters), addComboHits(combohits), addTrkHits(trkhits), addTimeClusters(timeclusters), addCryHits(cryhits), addMCTraj(mctraj), addKKTracks(kktracks) {}; - }; - - - - class TEveMu2eMainWindow : public TGMainFrame { - public: - - struct GeomOptions{ - GeomOptions(){} - GeomOptions( bool abuilding, bool aCRV, bool aDSOnly, bool aInsidePS ) - : showbuilding(abuilding) - , showCRV(aCRV) - , showDSOnly(aDSOnly) - , showInsidePS(aInsidePS){ - } - - bool showbuilding = false; - bool showCRV = false; - bool showDSOnly = false; - bool showInsidePS = false; - }; - - - #ifndef __CINT__ - TEveMu2eMainWindow(); - TEveMu2eMainWindow(const TEveMu2eMainWindow &); - TEveMu2eMainWindow& operator=(const TEveMu2eMainWindow &); - - TEveMu2eMainWindow(const TGWindow* p, UInt_t w, UInt_t h, fhicl::ParameterSet _pset, const DrawOptions drawOpts, const GeomOptions geomOpts); - virtual ~TEveMu2eMainWindow(){}; - enum ETestComandIdentifiers{HId1, HId2, HId3}; - - // For viewers: - void StartProjectionTabs(); - void CreateMultiViews(); - void CreateCaloProjection(); - void CreateTrackerProjection(); - void CreateCRVProjection(); - void PrepareTrackerProjectionTab(const art::Run& run); - void PrepareCaloProjectionTab(const art::Run& run); - void PrepareCRVProjectionTab(const art::Run& run); - void SetParticleOpts(std::vector particles_) { particles = particles_;} - - //GUI and geom: - void CreateGUI(); - void SetRunGeometry(const art::Run& run, std::string gdmlname, int _diagLevel); - void RedrawDataProducts(std::string type); - - // for menu: - Bool_t ProcessMessage(Long_t msg, Long_t param1, Long_t param2); - - // to add event info: - void setEvent(const art::Event& event, bool firstLoop, Data_Collections &data, double time, bool accumulate, int& runn, int& eventn, bool& update, bool isMCOnly); - bool isClosed() const; - int getEventToFind(bool &findEvent) const; - - //List of parameters: - TGeoManager* geom = new TGeoManager("geom","Geom"); - Geom_Interface *mu2e_geom = new Geom_Interface(); - TEveMu2eDataInterface *pass_data = new TEveMu2eDataInterface(); - TEveMu2eMCInterface *pass_mc = new TEveMu2eMCInterface(); - TEveMu2eProjectionInterface *pass_proj = new TEveMu2eProjectionInterface(); - - // data options - DrawOptions DrawOpts; - GeomOptions GeomOpts; - std::vector *clusterenergy = 0; - std::vector *hitenergy = 0; - std::vector times; - - TEvePad *fPad = nullptr; - TEvePad *fPadCRV = nullptr; - TGSplitFrame *fSplitFrame = nullptr; - TGSplitFrame *fSplitFrameCRV = nullptr; - TGSplitFrame *frm = nullptr; - TGSplitFrame *frmCRV = nullptr; - TGLEmbeddedViewer *fViewer0 = nullptr; - TGLEmbeddedViewer *fViewer1 = nullptr; - TGLEmbeddedViewer *fViewer2 = nullptr; - TGLEmbeddedViewer *fViewer3 = nullptr; - TGLEmbeddedViewer *fViewer4 = nullptr; - TGLEmbeddedViewer *fViewer5 = nullptr; - Bool_t fIsEmbedded; - - TEveViewer *fViewer[6]; - TEveProjectionManager *fRPhiMgr = nullptr; - TEveProjectionManager *fRhoZMgr = nullptr; - TEveProjectionManager *fXYMgr = nullptr; - TEveProjectionManager *gRPhiMgr = 0; - TEveProjectionManager *gRhoZMgr = 0; - TEveProjectionManager *TfXYMgr = 0; - TEveProjectionManager *TfRZMgr = 0; - TEveProjectionManager *CfXYMgr = 0; - TEveProjectionManager *CfRZMgr = 0; - TEveProjectionManager *CrfXYMgr = 0; - TEveProjectionManager *CrfRZMgr = 0; - TGMainFrame* frmMain = nullptr; - TEveBrowser* browser = nullptr; - TEveScene *s = 0; - TEveScene *proj0 = 0; - TEveScene *proj1 = 0; - TEveScene *proj2 = 0; - TEveScene *proj3 = 0; - TEveScene *proj4 = 0; - TEveScene *proj5 = 0; - - - bool usereventSelected = false; - TGTextEntry *fTeRun,*fTeEvt, *fTTEvt, *fTeh1, *fTeh2, *fTeh3, *cminenergy, *cmaxenergy, *hminenergy, *hmaxenergy, *hmintime, *hmaxtime; - TGLabel *fTlRun,*fTlEvt, *fTlTEvt, *fTlHSlid, *celabel, *helabel,*timelabel, *spacer, *spacer1; - TGButtonGroup *br; - TGCheckButton *clusterscheck, *hitscheck, *trackscheck, *cosmicscheck, *cosmictrkscheck, *mctrajcheck; - - TGTextBuffer *_eventNumber, *_subrunNumber, *_runNumber, *_time, *_clustminenergy, *_clustmaxenergy, *_hitminenergy, *_hitmaxenergy, *_hitmintime, *_hitmaxtime; - - int eventToFind, runToFind; - int _eventToFind = 0; - - bool _isClosed = false; - bool _findEvent = true; - bool _firstLoop = true; - bool _accumulate = false; - - TEveMu2e2DProjection *tracker2Dproj = new TEveMu2e2DProjection(); - TEveMu2e2DProjection *calo2Dproj = new TEveMu2e2DProjection(); - TEveMu2e2DProjection *CRV2Dproj = new TEveMu2e2DProjection(); - - TEveMu2eCalorimeter *Mu2eCalo = new TEveMu2eCalorimeter(); - TEveMu2eTracker *Mu2eTracker = new TEveMu2eTracker(); - TEveMu2eCRV *Mu2eCRV = new TEveMu2eCRV(); - - int _event, _subrun, _run; - Data_Collections _data; - Data_Collections _emptydata; - - double fclustmin = -1; - double fclustmax = -1; - double fhitmin = -1; - double fhitmax = -1; - double ftimemin = -1; - double ftimemax = -1; - - std::vector particles; - #endif - ClassDef(TEveMu2eMainWindow,0); - - }; //end class def - -}//end namespace mu2e - -#endif /*TEveMu2eMainWindow.h*/ diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eProjectionInterface.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eProjectionInterface.h deleted file mode 100644 index 7788249c56..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eProjectionInterface.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef TEveMu2eProjectionInterface_h -#define TEveMu2eProjectionInterface_h - -#include "Offline/TEveEventDisplay/src/dict_classes/Geom_Interface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCRV.h" - -namespace mu2e{ - class TEveMu2eProjectionInterface : public TGMainFrame { - public: - #ifndef __CINT__ - void CreateCRVProjection(TEveMu2e2DProjection *CRV2Dproj); - void CreateCaloProjection(TEveMu2e2DProjection *calo2Dproj); - void CreateTrackerProjection(TEveMu2e2DProjection *tracker2DProj); - #endif - ClassDef(TEveMu2eProjectionInterface,0); - - }; //end class def - -}//end namespace mu2e - -#endif /*TEveMu2eProjectionInterface.h*/ diff --git a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eStraightTrack.h b/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eStraightTrack.h deleted file mode 100644 index 81054ca5ac..0000000000 --- a/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eStraightTrack.h +++ /dev/null @@ -1,26 +0,0 @@ -#ifndef TEveMu2eStraightTrack_h -#define TEveMu2eStraightTrack_h - -#include -#include "Offline/RecoDataProducts/inc/CosmicTrackSeed.hh" -#include "Offline/DataProducts/inc/GenVector.hh" -#include - -namespace mu2e { - class TEveMu2eStraightTrack: public TEveStraightLineSet{ - - public: - #ifndef __CINT__ - explicit TEveMu2eStraightTrack(); - virtual ~TEveMu2eStraightTrack(){}; - - CosmicTrackSeed* fCosmicTrackSeed_; - - void DrawStraightTrack(); - XYZVectorF GetPositon(); - XYZVectorF GetDirection(); - #endif - ClassDef( TEveMu2eStraightTrack, 0); - }; -} -#endif diff --git a/TEveEventDisplay/src/TEveNonGDMLTest_module.cc b/TEveEventDisplay/src/TEveNonGDMLTest_module.cc deleted file mode 100644 index f5790853bc..0000000000 --- a/TEveEventDisplay/src/TEveNonGDMLTest_module.cc +++ /dev/null @@ -1,151 +0,0 @@ -// ... libCore -#include -#include -#include -#include -#include -#include -#include -// ... libRIO -#include -// ... libGui -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -// ... libGeom -#include -#include -#include -#include -#include -#include -// ... libRGL -#include -// ... libEve -#include -#include -#include -#include -#include -#include -#include -// Framework includes. -#include "art/Framework/Core/EDAnalyzer.h" -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Handle.h" -#include "art_root_io/TFileService.h" -#include -void setRecursiveColorTransp(TGeoVolume *vol, Int_t color, Int_t transp) - { - if(color>=0)vol->SetLineColor(color); - if(transp>=0)vol->SetTransparency(transp); - Int_t nd = vol->GetNdaughters(); - for (Int_t i=0; iGetNode(i)->GetVolume(), color, transp); - } - } - - -namespace mu2e -{ - class TEveNonGDMLTest : public art::EDAnalyzer { - public: - - struct Config{ - using Name=fhicl::Name; - using Comment=fhicl::Comment; - fhicl::Atom diagLevel{Name("diagLevel"), Comment("for info"),0}; - }; - - typedef art::EDAnalyzer::Table Parameters; - explicit TEveNonGDMLTest(const Parameters& conf); - virtual ~TEveNonGDMLTest(); - virtual void beginJob() override; - virtual void beginRun(const art::Run& run) override; - virtual void analyze(const art::Event& e); - virtual void endJob() override; - private: - Config _conf; - int _diagLevel; - bool isFirstEvent = true; - TApplication* application_; - TDirectory* directory_ = nullptr; - TEveBox* b = new TEveBox; - fhicl::ParameterSet _pset; - void MakeTEveMu2eMainWindow(); - }; - - TEveNonGDMLTest::TEveNonGDMLTest(const Parameters& conf) : - art::EDAnalyzer(conf), - _diagLevel(conf().diagLevel()) - - {} - - TEveNonGDMLTest::~TEveNonGDMLTest(){} - - - void TEveNonGDMLTest::beginJob(){ - std::cout<<"[Starting TEveNonGDMLTest::beginJob()]"<SetMainColor(kCyan); - b->SetMainTransparency(0); - std::cout<<"Point 2"<SetVertex(0, x - 10 + xnew, y - 10 + ynew, z - 10 + znew); - b->SetVertex(1, x - 10 + xnew, y + 10 + ynew, z - 10 + znew); - b->SetVertex(2, x + 10 + xnew, y + 10 + ynew, z - 10 + znew); - b->SetVertex(3, x + 10 + xnew, y - 10 + ynew, z - 10 + znew); - b->SetVertex(4, x - 10 + xnew, y - 10 + ynew, z + 10 + znew); - b->SetVertex(5, x - 10 + xnew, y + 10 + ynew, z + 10 + znew); - b->SetVertex(6, x + 10 + xnew, y + 10 + ynew, z + 10 + znew); - b->SetVertex(7, x + 10 + xnew, y - 10 + ynew, z + 10 + znew); - std::cout<<"Point 4"<AddElement(b); - gEve->Redraw3D(kTRUE); - std::cout<<"Point 5"<>enter; - std::cout<<"[Ending TEveNonGDMLTest::analyze()]"<SetMainColor(kCyan); - b->SetMainTransparency(0); -#define RND_BOX(x) r.Uniform(-(x), (x)) - b->SetVertex(0, x - a + RND_BOX(d), y - a + RND_BOX(d), z - a + RND_BOX(d)); - b->SetVertex(1, x - a + RND_BOX(d), y + a + RND_BOX(d), z - a + RND_BOX(d)); - b->SetVertex(2, x + a + RND_BOX(d), y + a + RND_BOX(d), z - a + RND_BOX(d)); - b->SetVertex(3, x + a + RND_BOX(d), y - a + RND_BOX(d), z - a + RND_BOX(d)); - b->SetVertex(4, x - a + RND_BOX(d), y - a + RND_BOX(d), z + a + RND_BOX(d)); - b->SetVertex(5, x - a + RND_BOX(d), y + a + RND_BOX(d), z + a + RND_BOX(d)); - b->SetVertex(6, x + a + RND_BOX(d), y + a + RND_BOX(d), z + a + RND_BOX(d)); - b->SetVertex(7, x + a + RND_BOX(d), y - a + RND_BOX(d), z + a + RND_BOX(d)); -#undef RND_BOX - gEve->AddElement(b); - gEve->Redraw3D(kTRUE); - return b; -} - diff --git a/TEveEventDisplay/src/classes.h b/TEveEventDisplay/src/classes.h deleted file mode 100644 index 2bb9cecf01..0000000000 --- a/TEveEventDisplay/src/classes.h +++ /dev/null @@ -1,22 +0,0 @@ -//Dictionary Classes: -#include "Offline/TEveEventDisplay/src/dict_classes/Geom_Interface.h" -#include "Offline/TEveEventDisplay/src/dict_classes/Collection_Filler.h" -#include "Offline/TEveEventDisplay/src/dict_classes/Data_Collections.h" -//TEveMu2e Base Classes: -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMainWindow.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eDataInterface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCInterface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eHit.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCluster.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eStraightTrack.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eBField.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eProjectionInterface.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCustomHelix.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eCRVEvent.h" -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2eMCTraj.h" - -//TEveMu2e Detectors: -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h" -#include "Offline/TEveEventDisplay/src/shape_classes/TEveMu2eCRV.h" diff --git a/TEveEventDisplay/src/classes_def.xml b/TEveEventDisplay/src/classes_def.xml deleted file mode 100644 index e6661b823e..0000000000 --- a/TEveEventDisplay/src/classes_def.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/TEveEventDisplay/src/dict_classes/Collection_Filler.h b/TEveEventDisplay/src/dict_classes/Collection_Filler.h deleted file mode 100644 index cfce485ca0..0000000000 --- a/TEveEventDisplay/src/dict_classes/Collection_Filler.h +++ /dev/null @@ -1,118 +0,0 @@ -#ifndef Collection_Filler_h -#define Collection_Filler_h -//ROOT -#include -#include -#include -#include -#include -#include -#include -#include -//Cosmics: -#include "Offline/RecoDataProducts/inc/CosmicTrackSeed.hh" -//Calo: -#include "Offline/RecoDataProducts/inc/CaloHit.hh" -#include "Offline/RecoDataProducts/inc/TimeCluster.hh" -//MC Products: -#include "Offline/MCDataProducts/inc/MCTrajectoryCollection.hh" -//Kalman Tracks -#include "Offline/RecoDataProducts/inc/KalSeed.hh" -#include "Offline/RecoDataProducts/inc/HelixSeed.hh" -//Tracker Hits: -#include "Offline/RecoDataProducts/inc/ComboHit.hh" -//CRV: -#include "Offline/RecoDataProducts/inc/CrvRecoPulse.hh" -//#include "RecoDataProducts/inc/CrvCoincidenceCluster.hh" -//Art: -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Run.h" -#include "art/Framework/Principal/SubRun.h" -#ifndef __ROOTCLING__ -#include "fhiclcpp/types/Atom.h" -#include "fhiclcpp/types/Sequence.h" -#include "fhiclcpp/types/Table.h" -#endif - -using namespace CLHEP; - -#include "Offline/TEveEventDisplay/src/dict_classes/Data_Collections.h" - -namespace mu2e{ - - enum RecoDataProductName {ComboHits, TimeClusters, CaloCrystalHits, CaloClusters, CosmicTracks, HelixSeeds, KalSeeds, CRVRecoPulses}; - enum MCDataProductName {MCTrajectories}; - - class Collection_Filler - { - public: -#ifndef __ROOTCLING__ - - struct Config{ - using Name=fhicl::Name; - using Comment=fhicl::Comment; - //RecoData Products - fhicl::Atom diagLevel{Name("diagLevel"), Comment("for info"),0}; - fhicl::AtomchTag{Name("ComboHitCollection"),Comment("chTag"), "makePH"}; - fhicl::AtomtcTag{Name("TimeClusterCollection"),Comment("tcTag"), "makePH"}; - fhicl::AtomcrvdigiTag{Name("CrvRecoPulseCollection"),Comment("crvTag")}; - fhicl::AtomcosmicTag{Name("CosmicTrackSeedCollection"),Comment("cosmicTag"), "CosmicTrackFinderTimeFit"}; - fhicl::AtomcluTag{Name("CaloClusterCollection"),Comment("cluTag")}; - fhicl::AtomcryHitTag{Name("CaloHitCollection"),Comment("cryHitTag")}; - fhicl::AtomhseedTag{Name("HelixSeedCollection"),Comment("hseedTag")}; - fhicl::SequencekalseedTag{Name("KalSeedCollection"),Comment("kalseedTag")}; - //MC Data Products - fhicl::AtommctrajTag{Name("MCTrajectoryCollection"),Comment("mctrajTag")}; - - //To add RecoDataProducts - fhicl::Atom addHits{Name("addHits"), Comment("set to add the hits"),false}; - fhicl::Atom addTimeClusters{Name("addTimeClusters"), Comment("set to add the TC hits"),false}; - fhicl::Atom addTrkHits{Name("addTrkHits"), Comment("set to add the Trk hits"),false}; - fhicl::Atom addTracks{Name("addTracks"), Comment("set to add tracks"),false}; - fhicl::Atom addClusters{Name("addClusters"), Comment("set to add calo lusters"),false}; - fhicl::Atom addCrvHits{Name("addCrvHits"), Comment("set to add crv hits"),false}; - fhicl::Atom addCrystallHits{Name("addCrystalHits"), Comment("for calo cry hits"), false}; - fhicl::Atom addCosmicSeedFit{Name("addCosmicSeedFit"), Comment("for fitted cosmic track"), false}; - fhicl::Atom RecoOnly{Name("RecoOnly"), Comment("set to see only Reco Data Products"), false}; - fhicl::Atom FillAll{Name("FillAll"), Comment("to see all available products"), false}; - fhicl::Atom addMCTraj{Name("addMCTraj"), Comment("set to add MC trajectories"), false}; - fhicl::Atom addKKTracks{Name("addKKTracks"), Comment("set to add KinKal traj"), false}; - fhicl::Atom MCOnly{Name("MCOnly"), Comment("set to see only MC Data Products"), false}; - }; - - explicit Collection_Filler(const Config& conf); -#endif - Collection_Filler(const Collection_Filler &); - Collection_Filler& operator=(const Collection_Filler &); - - //RecoDataProducts: - art::InputTag chTag_; - art::InputTag tcTag_; - art::InputTag crvcoinTag_; - art::InputTag cosmicTag_; - art::InputTag cluTag_; - art::InputTag cryHitTag_; - art::InputTag hseedTag_; - std::vector kalseedTag_; - art::InputTag trkexttrajTag_; - - //MCDataProdutcs: - art::InputTag mctrajTag_; - - art::Event *_event; - art::Run *_run; - bool addHits_, addTimeClusters_, addTrkHits_, addTracks_, addClusters_, addCrvHits_, addCosmicSeedFit_, isCosmic_, RecoOnly_, FillAll_, addMCCaloDigis_, addMCTraj_, addKKTracks_, MCOnly_; - void FillRecoCollections(const art::Event& evt, Data_Collections &data, RecoDataProductName code); - void FillMCCollections(const art::Event& evt, Data_Collections &data, MCDataProductName code); - virtual ~Collection_Filler(){}; - - private: -#ifndef __ROOTCLING__ - Config _conf; - #endif - ClassDef(Collection_Filler,0); -}; - -} - -#endif diff --git a/TEveEventDisplay/src/dict_classes/Data_Collections.h b/TEveEventDisplay/src/dict_classes/Data_Collections.h deleted file mode 100644 index 03335f49d1..0000000000 --- a/TEveEventDisplay/src/dict_classes/Data_Collections.h +++ /dev/null @@ -1,63 +0,0 @@ -#ifndef Data_Collections_h -#define Data_Collections_h -//Cosmics: -#include "Offline/RecoDataProducts/inc/CosmicTrackSeed.hh" -//Calo: -#include "Offline/RecoDataProducts/inc/CaloHit.hh" -#include "Offline/RecoDataProducts/inc/TimeCluster.hh" -//MC Products: -#include "Offline/MCDataProducts/inc/MCTrajectoryCollection.hh" -//Kalman Tracks -#include "Offline/RecoDataProducts/inc/KalSeed.hh" -#include "Offline/RecoDataProducts/inc/HelixSeed.hh" -//Tracker Hits: -#include "Offline/RecoDataProducts/inc/ComboHit.hh" -//CRV: -#include "Offline/RecoDataProducts/inc/CrvRecoPulse.hh" -#include "Offline/RecoDataProducts/inc/CrvCoincidenceCluster.hh" -//Art/FCL: -#include "art/Framework/Principal/Event.h" -#include "art/Framework/Principal/Run.h" - -#include -#include -#include -#include -#include -#include -#include -using namespace CLHEP; - -namespace mu2e{ - class Data_Collections - { - public: - #ifndef __CINT__ - explicit Data_Collections(){}; - Data_Collections(const Data_Collections &){}; - Data_Collections& operator=(const Data_Collections &); - - //RecoDataProducts: - const ComboHitCollection *chcol = 0; - const TimeClusterCollection *tccol = 0; - const CrvRecoPulseCollection* crvcoincol = 0; - const CosmicTrackSeedCollection* cosmiccol = 0; - const CaloClusterCollection* clustercol = 0; - const CaloHitCollection* cryHitcol = 0; - const HelixSeedCollection* hseedcol = 0; - const KalSeedCollection* kalseedcol = 0; - std::vector track_list; - std::vector track_labels; - std::tuple, std::vector> track_tuple; - - //MCDataProducts: - const MCTrajectoryCollection *mctrajcol = 0; - - virtual ~Data_Collections(){}; - #endif - ClassDef(Data_Collections,0); - }; - -} - -#endif diff --git a/TEveEventDisplay/src/dict_classes/GeomUtils.h b/TEveEventDisplay/src/dict_classes/GeomUtils.h deleted file mode 100644 index 83f0a4d7da..0000000000 --- a/TEveEventDisplay/src/dict_classes/GeomUtils.h +++ /dev/null @@ -1,13 +0,0 @@ -#ifndef GeomUtils_h -#define GeomUtils_h - -//C++ -#include -using namespace CLHEP; - -namespace mu2e{ - inline constexpr double pointmmTocm(double mm){ return mm/10; } - inline void hep3vectormmTocm(CLHEP::Hep3Vector &vector){vector.set(vector.x()/10, vector.y()/10, vector.z()/10);} - -} -#endif diff --git a/TEveEventDisplay/src/dict_classes/Geom_Interface.h b/TEveEventDisplay/src/dict_classes/Geom_Interface.h deleted file mode 100644 index a1140f7586..0000000000 --- a/TEveEventDisplay/src/dict_classes/Geom_Interface.h +++ /dev/null @@ -1,74 +0,0 @@ -#ifndef Geom_Interface_h -#define Geom_Interface_h - -#include -#include -// ... libRIO -#include -// ... libGui -#include -// ... libGeom -#include -#include -#include -#include -#include -#include -// ... libRGL -#include -// ... libEve -#include -#include -#include -#include -#include -#include -#include -#include - -//Geom: -#include "Offline/GeometryService/inc/DetectorSystem.hh" -#include "Offline/GeometryService/inc/WorldG4.hh" -#include "Offline/GeometryService/inc/WorldG4Maker.hh" -#include "Offline/GeometryService/inc/TrackerMaker.hh" -#include "Offline/GeometryService/inc/Mu2eHallMaker.hh" -#include "Offline/GeometryService/inc/G4GeometryOptions.hh" - - -namespace mu2e{ - class Geom_Interface { - - public: - #ifndef __CINT__ - explicit Geom_Interface(); - virtual ~Geom_Interface(){}; - TGeoManager *_geom; - TGeoManager* getGeom(TString filename) { - TGeoManager *geom; - geom = geom->TGeoManager::Import(filename); - return geom; - } - void CreateGeomManager(); - void RemoveComponents(); - void toForeground(); - void InsidePS( TGeoNode * node, bool inPSVac ); - void InsideDS( TGeoNode * node, bool inDSVac ); - void hideTop(TGeoNode* node, int _diagLevel); - void hideNodesByName(TGeoNode* node, const std::string& str, bool onOff, int _diagLevel) ; - void showNodesByName(TGeoNode* node, const std::string& str, bool onOff); - void InsideCRV( TGeoNode * node, bool inCRVVac); - void hideNodesByMaterial(TGeoNode* node, const std::string& mat, bool onOff); - void SolenoidsOnly(TGeoNode* node); - void TrackerVolumeHeirarchy( TGeoNode * node, std::vector &TransformList ); - CLHEP::Hep3Vector TrackerG4Origin; - CLHEP::Hep3Vector CaloG4Origin; - CLHEP::Hep3Vector TrackMu2eOrigin; - CLHEP::Hep3Vector CaloMu2eOrigin; - #endif - ClassDef(Geom_Interface,0); - - }; //end class def - -}//end namespace mu2e - -#endif /*Geom_Interface.h*/ diff --git a/TEveEventDisplay/src/dict_classes/StyleOpts.hh b/TEveEventDisplay/src/dict_classes/StyleOpts.hh deleted file mode 100644 index f289828afb..0000000000 --- a/TEveEventDisplay/src/dict_classes/StyleOpts.hh +++ /dev/null @@ -1,3 +0,0 @@ -const Int_t transpOpt = 100; -const Int_t linewidth = 3; -const Int_t fontsize = 15; diff --git a/TEveEventDisplay/src/mu2e.gdml b/TEveEventDisplay/src/mu2e.gdml deleted file mode 100644 index 6dedf95ba9..0000000000 --- a/TEveEventDisplay/src/mu2e.gdml +++ /dev/null @@ -1,95304 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - -
-
- - - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - -
-
- - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - -
-
- - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - -
-
- - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - -
-
- - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - -
-
- - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - -
-
- - - - - -
-
- - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/TEveEventDisplay/src/shape_classes/TEveMu2eCRV.h b/TEveEventDisplay/src/shape_classes/TEveMu2eCRV.h deleted file mode 100644 index 71236de1c5..0000000000 --- a/TEveEventDisplay/src/shape_classes/TEveMu2eCRV.h +++ /dev/null @@ -1,42 +0,0 @@ -#ifndef TEveMu2eCRV_h -#define TEveMu2eCRV_h - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -//ROOT -#include -//CRV/CRS: -#include "Offline/CosmicRayShieldGeom/inc/CosmicRayShield.hh" -#include "Offline/CosmicRayShieldGeom/inc/CRSScintillatorShield.hh" -#include "Offline/CosmicRayShieldGeom/inc/CRSScintillatorModule.hh" -//TEveMu2e: -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" - -namespace art { class Run; } - -namespace mu2e{ - class TEveMu2eCRV - { - public: - #ifndef __CINT__ - explicit TEveMu2eCRV(); - TEveMu2eCRV(const TEveMu2eCRV &){}; - TEveMu2eCRV& operator=(const TEveMu2eCRV &); - virtual ~TEveMu2eCRV(){}; - void DrawCRVDetector(art::Run const& run, TGeoVolume* topvol , TEveElementList *orthodetT1, TEveElementList *orthodetT2); - TEveMu2e2DProjection *CRV2Dproj = new TEveMu2e2DProjection(); - #endif - ClassDef(TEveMu2eCRV, 0); - }; -} -#endif diff --git a/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h b/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h deleted file mode 100644 index b16b80fff2..0000000000 --- a/TEveEventDisplay/src/shape_classes/TEveMu2eCalorimeter.h +++ /dev/null @@ -1,50 +0,0 @@ -#ifndef TEveMu2eCalorimeter_h -#define TEveMu2eCalorimeter_h - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -// ... libRIO -#include -//Calorimeter: -#include "Offline/CalorimeterGeom/inc/CaloGeomUtil.hh" -#include "Offline/CalorimeterGeom/inc/CaloInfo.hh" -#include "Offline/CalorimeterGeom/inc/Calorimeter.hh" -#include "Offline/CalorimeterGeom/inc/DiskCalorimeter.hh" -#include "Offline/CalorimeterGeom/inc/DiskGeomInfo.hh" -#include "Offline/CalorimeterGeom/inc/Disk.hh" -//TEveMu2e: -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -//Mu2e: -#include "Offline/GeometryService/inc/DetectorSystem.hh" - -namespace art{ - class Run; -} - -namespace mu2e{ - class TEveMu2eCalorimeter - { - public: - #ifndef __CINT__ - explicit TEveMu2eCalorimeter(); - TEveMu2eCalorimeter(const TEveMu2eCalorimeter &){}; - TEveMu2eCalorimeter& operator=(const TEveMu2eCalorimeter &); - virtual ~TEveMu2eCalorimeter(){}; - void DrawCaloDetector(art::Run const& run, TGeoVolume* topvol , TEveElementList *orthodet0,TEveElementList *orthodet1); - TEveMu2e2DProjection *calo2Dproj = new TEveMu2e2DProjection(); - #endif - ClassDef(TEveMu2eCalorimeter, 0); - }; -} -#endif diff --git a/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h b/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h deleted file mode 100644 index a3ee90cb67..0000000000 --- a/TEveEventDisplay/src/shape_classes/TEveMu2eTracker.h +++ /dev/null @@ -1,43 +0,0 @@ -#ifndef TEveMu2eTracker_h -#define TEveMu2eTracker_h - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -// ... libRIO -#include -//Tracker -#include "Offline/TrackerGeom/inc/Tracker.hh" -//TEveMu2e: -#include "Offline/TEveEventDisplay/src/TEveMu2e_base_classes/TEveMu2e2DProjection.h" -#include "Offline/TEveEventDisplay/src/dict_classes/GeomUtils.h" -#include "Offline/StoppingTargetGeom/inc/StoppingTarget.hh" -#include "Offline/StoppingTargetGeom/inc/TargetFoil.hh" -#include "Offline/CalorimeterGeom/inc/DiskCalorimeter.hh" -#include "Offline/CalorimeterGeom/inc/Calorimeter.hh" -#include - -namespace mu2e { - -class TEveMu2eTracker{ - public: - #ifndef __CINT__ - explicit TEveMu2eTracker(); - TEveMu2eTracker(const TEveMu2eTracker &){}; - TEveMu2eTracker& operator=(const TEveMu2eTracker &); - virtual ~TEveMu2eTracker(){}; - TEveMu2e2DProjection *tracker2Dproj = new TEveMu2e2DProjection(); - void DrawTrackerDetector(TGeoVolume* topvol , TEveElementList *orthodetXZ, TEveElementList *orthodetXY); - #endif - ClassDef(TEveMu2eTracker, 0); - }; -} -#endif