Skip to content

Commit

Permalink
Add Mermaid diagram of a draft entity-relationship model for DP0.2
Browse files Browse the repository at this point in the history
Eventually we should try to generate this automatically from Felis.
  • Loading branch information
gpdf committed Feb 5, 2024
1 parent 08d7fa4 commit 98fe0e3
Showing 1 changed file with 64 additions and 0 deletions.
64 changes: 64 additions & 0 deletions yml/dp02_dc2.mmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
---
title: DP0.2 Table Relationships
---
erDiagram
Object {
long objectId UK
long tract FK
long patch FK
}
Object ||--o{ MatchesTruth : matches
Object }o..|| CoaddPatches : "found in"
Object ||--|{ ForcedSource : seeds

Source {
long ccdVisitId FK
long visit FK
}
Source }o..|| CcdVisit : "found in"
Source }o..|| Visit : "found in"
ForcedSource {
long objectId FK
long ccdVisitId FK
long tract FK
long patch FK
}
ForcedSource }o..|| CcdVisit : "measured in"
DiaObject {
long diaObjectId UK
long nDiaSources
}
DiaObject |o..|{ DiaSource : "built from"
DiaObject ||--|{ ForcedSourceOnDiaObject : "seeds"
DiaSource {
long diaObjectId FK
long ccdVisitId FK
}
DiaSource }o..|| CcdVisit : "found in"
ForcedSourceOnDiaObject {
long diaObjectId FK
long ccdVisitId FK
long tract FK
long patch FK
}
ForcedSourceOnDiaObject }o..|| CcdVisit : "measured in"
CcdVisit {
long ccdVisitId UK
long visitId FK
}
Visit {
long visit UK
}
Visit ||--|{ CcdVisit : contains
CoaddPatches {
long lsst_tract PK
long lsst_patch PK
}
MatchesTruth {
string id_truth_type FK
long match_objectId FK
}
TruthSummary {
string id_truth_type PK
}
TruthSummary ||--o{ MatchesTruth : matches

0 comments on commit 98fe0e3

Please sign in to comment.