Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename type to PDG in ReconstructedParticle #273

Merged
merged 3 commits into from
Feb 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,16 @@ A generic event data model for future HEP collider experiments.
| [CalorimeterHit](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L304) | [ParticleID](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L316) | [Cluster](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L329) |
| [TrackerHit](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L350) | [TrackerHitPlane](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L367) | [RawTimeSeries](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L388) |
| [Track](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L401) | [Vertex](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L420) | [ReconstructedParticle](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L437) |
| [SimPrimaryIonizationCluster](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L541) | [TrackerPulse](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L575) | [RecIonizationCluster](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L588) |
| [TimeSeries](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L599) | [RecDqdx](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L611) | |
| [SimPrimaryIonizationCluster](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L545) | [TrackerPulse](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L579) | [RecIonizationCluster](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L592) |
| [TimeSeries](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L603) | [RecDqdx](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L615) | |

**Associations**

| | | |
|-|-|-|
| [MCRecoParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L467) | [MCRecoCaloAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L476) | [MCRecoTrackerAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L485) |
| [MCRecoTrackerHitPlaneAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L494) | [MCRecoCaloParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L503) | [MCRecoClusterParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L512) |
| [MCRecoTrackParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L521) | [RecoParticleVertexAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L530) | |
| [MCRecoParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L471) | [MCRecoCaloAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L480) | [MCRecoTrackerAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L489) |
| [MCRecoTrackerHitPlaneAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L498) | [MCRecoCaloParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L507) | [MCRecoClusterParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L516) |
| [MCRecoTrackParticleAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L525) | [RecoParticleVertexAssociation](https://github.com/key4hep/EDM4hep/blob/main/edm4hep.yaml#L534) | |

The tests and examples in the `tests` directory show how to read, write, and use these types in your code.

Expand Down
6 changes: 5 additions & 1 deletion edm4hep.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,7 @@ datatypes:
Description: "Reconstructed Particle"
Author: "F.Gaede, DESY"
Members:
- int32_t type //type of reconstructed particle. Check/set collection parameters ReconstructedParticleTypeNames and ReconstructedParticleTypeValues.
- int32_t PDG // PDG of the reconstructed particle.
- float energy // [GeV] energy of the reconstructed particle. Four momentum state is not kept consistent internally.
- edm4hep::Vector3f momentum // [GeV] particle momentum. Four momentum state is not kept consistent internally.
- edm4hep::Vector3f referencePoint // [mm] reference, i.e. where the particle has been measured
Expand All @@ -457,11 +457,15 @@ datatypes:
ExtraCode:
declaration: "
bool isCompound() const { return particles_size() > 0 ;}\n
[[deprecated(\"use setPDG instead\")]]\n
int32_t getType() const { return getPDG(); }\n
"
MutableExtraCode:
declaration: "
//vertex where the particle decays This method actually returns the start vertex from the first daughter particle found.\n
//TODO: edm4hep::Vertex getEndVertex() { return edm4hep::Vertex( (getParticles(0).isAvailable() ? getParticles(0).getStartVertex() : edm4hep::Vertex(0,0) ) ) ; }\n
[[deprecated(\"use setPDG instead\")]]\n
void setType(int32_t pdg) { setPDG(pdg); }\n
"

edm4hep::MCRecoParticleAssociation:
Expand Down
Loading