Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
train_ambiguity_solver Namespace Reference

Functions

def readDataSet
 
def prepareTrainingData
 
def batchSplit
 
def computeLoss
 
def scoringBatch
 
def train
 

Variables

list avg_mean [0, 0, 0, 0, 0, 0, 0, 0]
 
list avg_sdv [0, 0, 0, 0, 0, 0, 0, 0]
 
int events 0
 
tuple CKF_files sorted(glob.glob("odd_output" + "/event0000000[0-7][0-9]-tracks_ckf.csv"))
 
tuple data readDataSet(CKF_files)
 
tuple input_dim np.shape(x_train)
 
list layers_dim [10, 15, 10]
 
tuple duplicateClassifier
 
 input data.index,x_train,y_train
 
tuple input_test torch.tensor(x_train, dtype=torch.float32)
 
list input_names ["x"]
 
list output_names ["y"]
 
dictionary dynamic_axes {"x": {0: "batch_size"}, "y": {0: "batch_size"}}
 
tuple CKF_files_test
 
tuple test readDataSet(CKF_files_test)
 
list output_predict []
 
tuple x_test torch.tensor(x_test, dtype=torch.float32)
 
int id 0
 
list pid test.index[0]
 
int nb_part 1
 
int nb_good_match 0
 
int max_match 0
 
int max_score 0
 

Function Documentation

def train_ambiguity_solver.batchSplit (   data)

Definition at line 78 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 78 of file train_ambiguity_solver.py

References computeLoss(), and Acts.zip().

Referenced by train().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

def train_ambiguity_solver.computeLoss (   score_good)

Definition at line 104 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 104 of file train_ambiguity_solver.py

Referenced by batchSplit(), and scoringBatch().

+ Here is the caller graph for this function:

def train_ambiguity_solver.prepareTrainingData (   data)

Definition at line 40 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 40 of file train_ambiguity_solver.py

References fit(), and Acts::Test.transform.

+ Here is the call graph for this function:

def train_ambiguity_solver.readDataSet (   CKS_files)

Definition at line 20 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 20 of file train_ambiguity_solver.py

References ambiguity_solver_network.prepareDataSet().

+ Here is the call graph for this function:

def train_ambiguity_solver.scoringBatch (   batch)

Definition at line 124 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 124 of file train_ambiguity_solver.py

References computeLoss(), duplicateClassifier, train(), and Acts.zip().

Referenced by train().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

def train_ambiguity_solver.train (   duplicateClassifier)

Definition at line 200 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 200 of file train_ambiguity_solver.py

References batchSplit(), print(), and scoringBatch().

Referenced by scoringBatch().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Variable Documentation

list train_ambiguity_solver.avg_mean [0, 0, 0, 0, 0, 0, 0, 0]

Definition at line 15 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 15 of file train_ambiguity_solver.py

list train_ambiguity_solver.avg_sdv [0, 0, 0, 0, 0, 0, 0, 0]

Definition at line 16 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 16 of file train_ambiguity_solver.py

tuple train_ambiguity_solver.CKF_files sorted(glob.glob("odd_output" + "/event0000000[0-7][0-9]-tracks_ckf.csv"))

Definition at line 249 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 249 of file train_ambiguity_solver.py

tuple train_ambiguity_solver.CKF_files_test
Initial value:
1 sorted(
2  glob.glob("odd_output" + "/event0000000[8-9][0-9]-tracks_ckf.csv")
3 )

Definition at line 283 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 283 of file train_ambiguity_solver.py

tuple train_ambiguity_solver.data readDataSet(CKF_files)

Definition at line 250 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 250 of file train_ambiguity_solver.py

tuple train_ambiguity_solver.duplicateClassifier
Initial value:
1 nn.Sequential(
2  Normalise(avg_mean, avg_sdv), DuplicateClassifier(input_dim, layers_dim)
3 )

Definition at line 262 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 262 of file train_ambiguity_solver.py

Referenced by scoringBatch().

dictionary train_ambiguity_solver.dynamic_axes {"x": {0: "batch_size"}, "y": {0: "batch_size"}}

Definition at line 278 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 278 of file train_ambiguity_solver.py

int train_ambiguity_solver.events 0

Definition at line 17 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 17 of file train_ambiguity_solver.py

int train_ambiguity_solver.id 0

Definition at line 304 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 304 of file train_ambiguity_solver.py

Referenced by PHG4TruthInfoContainer.AddShower(), TrkrTruthTrackContainerv1.addTruthTrack(), ospEvent.addUnstructPacketData(), PHG4TruthInfoContainer.AddVertex(), PHG4InEvent.AddVtxCommon(), PHG4InEvent.AddVtxHepMC(), Acts::Test.BOOST_AUTO_TEST_CASE(), ActsExamples::Generic.buildDetector(), catalogInfo(), Jetscape::Parton.CheckAcceptability(), Acts::MaterialMapJsonConverter.convertToHierarchy(), Acts::SeedFinder< external_spacepoint_t, Acts::Cuda >.createSeedsForGroup(), genfit::Track.deletePoint(), genfit::Track.deleteTrackRep(), genfit::EventDisplay.drawEvent(), QAG4SimulationVertex.embed_id_cut(), DSTEmulator.evaluate_tracks(), TrackEvaluation.evaluate_tracks(), A_Event.existPacket(), SubSystemAction.FindById(), daqONCSEvent.formatHeader(), PHG4Prototype3InnerHcalDetector.get_scinti_row_id(), PHG4Prototype2InnerHcalDetector.get_scinti_row_id(), PHG4Prototype2OuterHcalDetector.get_scinti_row_id(), PHG4Prototype3InnerHcalDetector.get_steel_plate_id(), PHG4Prototype2OuterHcalDetector.get_steel_plate_id(), PHG4Prototype2InnerHcalDetector.get_steel_plate_id(), oncsEvent.getPacket(), A_Event.getPacket(), TrkrTruthTrackContainerv1.getTruthTrack(), genfit::EventDisplay.gotoEvent(), EmbRecoMatchContainerv1.ids_TruthMatched(), PHG4CylinderGeom_Spacalv1.ImportParameters(), genfit::Track.insertPoint(), genfit::Track.insertPoints(), SVReco.MakeSvtxTrack(), TpcPrototypeGenFitTrkFitter.MakeSvtxTrack(), PHGenFitTrkFitter.MakeSvtxTrack(), graph.new_edge_id(), graph.new_node_id(), operator<<(), FullJetFinder.process_event(), genfit.RaveToGFVertex(), readFile(), PHG4Sector::PHG4SectorConstructor.RegisterPhysicalVolume(), ActsExamples::SensitiveSurfaceMapper.remapSensitiveNames(), ActsExamples::HepMC3Event.removeParticle(), pq_tree.replace_pert(), Acts::SurfaceView3DTest.run(), PROTOTYPE4_FEM.SampleFit_PowerLawDoubleExp(), TPCDaqDefs::FEEv1.SampleFit_PowerLawDoubleExp(), TpcPrototypeDefs::FEEv2.SampleFit_PowerLawDoubleExp(), PROTOTYPE4_FEM.SampleFit_PowerLawExp(), SvtxTrack_v1.set_cal_cluster_id(), SvtxTrack_v2.set_cal_cluster_id(), SvtxTrack_v3.set_cal_cluster_id(), SvtxTrack_v1.set_cal_cluster_key(), SvtxTrack_v2.set_cal_cluster_key(), SvtxTrack_v3.set_cal_cluster_key(), PHG4CylinderCellv1.set_cell_id(), Jetscape::Parton.set_edgeid(), QAG4SimulationTracking.set_embed_id_cut(), Fun4AllHepMCOutputManager.set_embedding_id(), PHHepMCParticleSelectorDecayProductChain.set_embedding_id(), PHHepMCGenEvent.set_embedding_id(), Quarkonia2LeptonsMC.set_embedding_id(), Leptoquarks.set_embedding_id(), SynRadAna.set_embedding_id(), PHHepMCGenHelper.set_embedding_id(), HFMLTriggerHepMCTrigger.set_embedding_id(), HFMLTriggerOccupancy.set_embedding_id(), HFMLTriggerInterface.set_embedding_id(), TruthJetTagging.set_embedding_id(), HFFastSim.set_embedding_id(), HFJetTruthTrigger.set_embedding_id(), DirectPhotonPythia.set_embedding_id(), MbdVertexv2.set_id(), MbdVertexv1.set_id(), BbcVertexv1.set_id(), BbcVertexv2.set_id(), InttVertexv1.set_id(), RawTower_Prototype4.set_id(), SvtxVertex_v2.set_id(), RawTowerv1.set_id(), SvtxVertex_v1.set_id(), RawTower_Prototype2.set_id(), RawTower_Prototype3.set_id(), RawTower_Temperature.set_id(), PHG4Showerv1.set_id(), GlobalVertexv2.set_id(), GlobalVertexv1.set_id(), sPHElectronPairv1.set_id(), ParticleFlowElementv1.set_id(), Jetv1.set_id(), SvtxTrack_v1.set_id(), SvtxTrack_v2.set_id(), SvtxTrack_v3.set_id(), SvtxTrack_v4.set_id(), sPHElectronv1.set_id(), Jetv2.set_id(), RawClusterv1.set_id(), Jetscape::JetScapeParticleBase.set_id(), PidInfo_RICH_v1.set_track_id(), SvtxTrack_v1.set_vertex_id(), SvtxTrack_v2.set_vertex_id(), SvtxTrack_v3.set_vertex_id(), SvtxTrack_v4.set_vertex_id(), PgPostCalBankIterator.setBankID(), mvtx::ChipPixelData.setChipID(), TpcPrototypeCluster.setClusKey(), ActsFatras::Barcode.setGeneration(), KFPTrack.SetID(), KFPTrack.SetId(), KFParticleBase.SetId(), KFParticleBaseSIMD.SetId(), SColdQcdCorrelatorAnalysis::SCorrelatorUtilities::JetInfo.SetInfo(), SColdQcdCorrelatorAnalysis::SCorrelatorUtilities::CstInfo.SetInfo(), KFMCParticle.SetMCTrackID(), KFMCParticle.SetMotherId(), ActsFatras::Barcode.setParticle(), ActsFatras::Barcode.setSubParticle(), TrkrClusterv3.setSubSurfKey(), TrkrClusterv4.setSubSurfKey(), TrkrClusterv5.setSubSurfKey(), TrkrClusterv2.setSubSurfKey(), OnlMonServer.SetThreadId(), Acts::MutablePodioTrackStateContainer.setUncalibratedSourceLink_impl(), ActsFatras::Barcode.setVertexPrimary(), ActsFatras::Barcode.setVertexSecondary(), SingleStreamingInput.SubsystemEnum(), MapHelper.surfaceToIdentifier(), and ActsExamples::SvgPointWriter< T, Acc >.writeT().

train_ambiguity_solver.input data.index,x_train,y_train

Definition at line 267 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 267 of file train_ambiguity_solver.py

tuple train_ambiguity_solver.input_dim np.shape(x_train)

Definition at line 259 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 259 of file train_ambiguity_solver.py

list train_ambiguity_solver.input_names ["x"]

Definition at line 276 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 276 of file train_ambiguity_solver.py

tuple train_ambiguity_solver.input_test torch.tensor(x_train, dtype=torch.float32)

Definition at line 270 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 270 of file train_ambiguity_solver.py

list train_ambiguity_solver.layers_dim [10, 15, 10]

Definition at line 260 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 260 of file train_ambiguity_solver.py

int train_ambiguity_solver.max_match 0

Definition at line 308 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 308 of file train_ambiguity_solver.py

int train_ambiguity_solver.max_score 0

Definition at line 309 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 309 of file train_ambiguity_solver.py

int train_ambiguity_solver.nb_good_match 0

Definition at line 307 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 307 of file train_ambiguity_solver.py

int train_ambiguity_solver.nb_part 1

Definition at line 306 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 306 of file train_ambiguity_solver.py

list train_ambiguity_solver.output_names ["y"]

Definition at line 277 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 277 of file train_ambiguity_solver.py

list train_ambiguity_solver.output_predict []

Definition at line 292 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 292 of file train_ambiguity_solver.py

train_ambiguity_solver.pid test.index[0]

Definition at line 305 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 305 of file train_ambiguity_solver.py

Referenced by BOOST_AUTO_TEST_CASE(), BOOST_DATA_TEST_CASE(), RICHEvaluator.calculate_true_emission_angle(), DVMPHelper.calculateInvariantMass_2(), DVMPHelper.calculateInvariantMass_5(), DVMPHelper.calculateInvariantMass_6(), Fun4AllOscarInputManager.ConvertFromOscar(), Fun4AllHepMCInputManager.ConvertFromOscar(), create_pythia_dummy(), Matter.DoEnergyLoss(), AdSCFT.DoEnergyLoss(), LBT.DoEnergyLoss(), ColoredHadronization.DoHadronization(), ColorlessHadronization.DoHadronization(), Jetscape::JetEnergyLoss.DoShower(), DrawEcal_Likelihood(), dvcs_plot(), eic_sphenix_fill_xq2(), MBDStudy.End(), BBCStudy.End(), ActsExamples::HitsPrinter.execute(), ActsEvaluator.fillG4Particle(), fillHist(), TruthTrackerHepMC.FindDaughterParticle(), TruthTrackerHepMC.FindParticle(), Fun4All_EMCalLikelihood(), PHTruthSiliconAssociation.getG4PrimaryParticle(), DVMPHelper.GetParticleTruth(), SColdQcdCorrelatorAnalysis::SCorrelatorUtilities.IsOutgoingParton(), SColdQcdCorrelatorAnalysis::SCorrelatorJetTree.IsOutgoingParton(), likelihood(), Jetscape::PartonShower.load_edge_info_handler(), MachineLearning_CSV(), main(), ActsExamples::ParticleTrackingAction.makeParticleId(), makeTestSimhits(), mg_start_process(), ActsExamples::ParametricParticleGenerator.operator()(), PIDProbabilities.particle_probs(), TemplateCreation.process_event(), QAG4SimulationUpsilon.process_event(), CaloTowerBuilder.process_event(), PHHepMCParticleSelectorDecayProductChain.process_event(), LEDTowerBuilder.process_event(), FastPid_RICH.process_event(), InttMon.process_event(), QAG4SimulationTracking.process_event(), MBDStudy.process_event(), hijbkg_upc.process_event(), MbdDigitization.process_event(), BBCStudy.process_event(), ElectronID.process_event(), PHG4TrackFastSim.process_event(), sPHAnalysis.process_event_pythiaupsilon(), ActsExamples::RootSimHitReader.read(), ActsExamples::EventGenerator.read(), SColdQcdCorrelatorAnalysis::SCorrelatorUtilities::ParInfo.Reset(), SColdQcdCorrelatorAnalysis::SCorrelatorUtilities::CstInfo.Rest(), Jetscape::PartonShower.SaveAsGV(), QAG4SimulationUpsilon.setDaughterAbsPID(), SColdQcdCorrelatorAnalysis::SCorrelatorUtilities::CstInfo.SetInfo(), SColdQcdCorrelatorAnalysis::SCorrelatorUtilities::ParInfo.SetInfo(), PHHepMCParticleSelectorDecayProductChain.SetParticle(), PHPy6ParticleTrigger.SetParticleType(), QAG4SimulationUpsilon.setQuarkoniaPID(), HybridHadronization::HHhadron.status(), TrackCaloDist(), PHG4ZDCSteppingAction.UserSteppingAction(), and ActsExamples::CKFPerformanceWriter.writeT().

tuple train_ambiguity_solver.x_test torch.tensor(x_test, dtype=torch.float32)

Definition at line 294 of file train_ambiguity_solver.py.

View newest version in sPHENIX GitHub at line 294 of file train_ambiguity_solver.py