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

DCH v2 digitizer, which smears the position and adds cluster information #27

Open
wants to merge 41 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 28 commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
b5a9c6d
DCH v2 digitizer, which smears the position and adds cluster information
atolosadelgado Aug 5, 2024
c1fea2b
remove gaudi transformer linking/header
atolosadelgado Aug 8, 2024
87c1f44
filter out the new digitizer if DCH data extension is not found
atolosadelgado Aug 8, 2024
136b71b
update test of idea vx
atolosadelgado Aug 9, 2024
56000b3
fix vx test
atolosadelgado Aug 9, 2024
b7a6ee5
remove position_L/R member of data extension
atolosadelgado Aug 9, 2024
2a58e2c
add test for DCHdigi
atolosadelgado Aug 9, 2024
4d837b2
add protection in case the file for CLS is not available
atolosadelgado Aug 9, 2024
5392c1f
add ctest
atolosadelgado Aug 9, 2024
bafdf2a
cast variables to void to get rid of spurious compiler warning
atolosadelgado Aug 9, 2024
243ea2e
add edm4hep link in yaml
atolosadelgado Aug 12, 2024
7411696
use to mutable digi hit
atolosadelgado Aug 12, 2024
c8f8f3d
add association as second collection in the output
atolosadelgado Aug 12, 2024
7664d83
fix path to compact file of DCH stand alone
atolosadelgado Aug 12, 2024
008a313
array index in C start at 0...
atolosadelgado Aug 12, 2024
7ea6aea
use ref to mutable object, to be checked if association is correct
atolosadelgado Aug 12, 2024
cfc43ca
write association in the output
atolosadelgado Aug 23, 2024
e9bbb89
default z resolution 1 mm
atolosadelgado Aug 23, 2024
3eac1ee
default xy resolution 0.1 mm
atolosadelgado Aug 23, 2024
adb8650
expanded comment about the uid service
atolosadelgado Aug 23, 2024
330c62a
comment added
atolosadelgado Aug 23, 2024
9a4222c
add comment about advancing the random engines
atolosadelgado Aug 23, 2024
414805a
change value in test
atolosadelgado Aug 23, 2024
f27b963
output file with histograms for debugging is now configurable from st…
atolosadelgado Aug 23, 2024
f74c8a2
remove unused function
atolosadelgado Aug 23, 2024
db04af4
add shebang
atolosadelgado Aug 23, 2024
78065f4
remove alias for edm4hep classes
atolosadelgado Aug 23, 2024
47b0d5d
rename namespace of edm4hep extension to edm4hep, add interface
atolosadelgado Aug 23, 2024
107fde5
implement Thomas suggestion, exit code removed
atolosadelgado Aug 29, 2024
a0e3bcd
moving back new edm4hep classes to extension namespace
atolosadelgado Aug 30, 2024
7a6a5f3
add interface back again...
atolosadelgado Sep 2, 2024
609284b
add extension::Track
atolosadelgado Sep 21, 2024
29e8986
rename of cluster variables
atolosadelgado Sep 21, 2024
f832901
indentantion is compliant with local .clang-format file
atolosadelgado Sep 21, 2024
2e563cd
Merge branch 'key4hep:master' into DCH_digi
atolosadelgado Oct 15, 2024
64a3e8f
indentation corrected
atolosadelgado Oct 15, 2024
815ea4c
avoid downloading several times the cluster input file
atolosadelgado Oct 15, 2024
e13c7b6
initialize variables, fix compilation in ubuntu
atolosadelgado Oct 15, 2024
79619f6
major refactorization of cluster counting function
atolosadelgado Oct 18, 2024
061e554
data extension modified,
atolosadelgado Oct 18, 2024
8d69073
clang format of source code
atolosadelgado Oct 18, 2024
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
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ find_package(ROOT COMPONENTS RIO Tree MathCore)
find_package(EDM4HEP)
find_package(k4FWCore)
find_package(Gaudi)
find_package(GSL)
#---------------------------------------------------------------

include(GNUInstallDirs)
Expand Down
27 changes: 23 additions & 4 deletions DCHdigi/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ install(FILES

install(FILES
dataFormatExtension/driftChamberHit.yaml
DESTINATION "${CMAKE_INSTALL_DATADIR}/extension" COMPONENT dev)
DESTINATION "${CMAKE_INSTALL_PREFIX}/extension" COMPONENT dev)

install(FILES
"${PROJECT_BINARY_DIR}/libextensionDict_rdict.pcm"
Expand All @@ -42,15 +42,29 @@ file(GLOB headers
${PROJECT_SOURCE_DIR}/include/*.h
)

include(CheckIncludeFileCXX)
set(CMAKE_REQUIRED_LIBRARIES DD4hep::DDRec)
CHECK_INCLUDE_FILE_CXX(DDRec/DCH_info.h DCH_INFO_H_EXIST)
set(CMAKE_REQUIRED_LIBRARIES)
set(FILES_DEPENDINGON_DCH_INFO_H "DCHdigi.cpp" )
if(NOT DCH_INFO_H_EXIST)
list(FILTER sources EXCLUDE REGEX "${FILES_DEPENDINGON_DCH_INFO_H}")
message(WARNING "Gaudi algorithm defined in ${FILES_DEPENDINGON_DCH_INFO_H} will not be built because header file DDRec/DCH_info.h was not found")
endif()

gaudi_add_module(${PackageName}
SOURCES ${sources}
LINK
k4FWCore::k4FWCore
k4FWCore::k4Interface
Gaudi::GaudiKernel
EDM4HEP::edm4hep
extensionDict
k4FWCore::k4FWCore
k4FWCore::k4Interface
DD4hep::DDRec
DD4hep::DDCore
ROOT::MathCore
ROOT::MathMore
GSL::gsl
)

target_include_directories(${PackageName} PUBLIC
Expand All @@ -71,7 +85,7 @@ install(TARGETS ${PackageName}
EXPORT ${CMAKE_PROJECT_NAME}Targets
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" COMPONENT bin
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" COMPONENT shlib
PUBLIC_HEADER DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/@{CMAKE_PROJECT_NAME}" COMPONENT dev
PUBLIC_HEADER DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/${CMAKE_PROJECT_NAME}" COMPONENT dev
)

install(FILES ${scripts} DESTINATION test)
Expand All @@ -83,3 +97,8 @@ set_test_env(${test_name})
SET(test_name "test_DCHsimpleDigitizerExtendedEdm")
ADD_TEST(NAME ${test_name} COMMAND k4run test/runDCHsimpleDigitizerExtendedEdm.py)
set_test_env(${test_name})

SET(test_name "test_runDCHdigiV2")
ADD_TEST(NAME ${test_name} COMMAND sh +x test_DCHdigi.sh )
set_test_env(${test_name})
set_tests_properties(${test_name} PROPERTIES WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}/DCHdigi/test/test_DCHdigi")
43 changes: 43 additions & 0 deletions DCHdigi/dataFormatExtension/driftChamberHit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ schema_version: 1
options:
# should getters / setters be prefixed with get / set?
getSyntax: True
setSyntax: True
# should POD members be exposed with getters/setters in classes that have them as members?
exposePODMembers: False
includeSubfolder: True
Expand Down Expand Up @@ -41,3 +42,45 @@ datatypes:
OneToOneRelations:
- extension::DriftChamberDigi digi // reference to the digitized hit
- edm4hep::SimTrackerHit sim // reference to the simulated hit

edm4hep::DriftChamberDigiV2:
Description: "Digitized hit (before tracking) for Drift Chamber v2 (requires data extension)."
Author: "A. Tolosa-Delgado, B. Francois, CERN"
Members:
- uint64_t cellID // ID of the sensor that created this hit
- int32_t type // type of the raw data hit
- int32_t quality // quality bit flag of the hit
- float time // time of the hit [ns]
- float eDep // energy deposited on the hit [GeV]
- float eDepError // error measured on eDep [GeV]
- edm4hep::Vector3d position // point on the sensitive wire (SW) which is closest to the simhit [mm]
- edm4hep::Vector3d directionSW // direction of SW
- float distanceToWire // distance hit-wire [mm]
- uint32_t clusterCount // number of clusters associated to this hit
- uint32_t clusterSize // number of electrons per cluster
atolosadelgado marked this conversation as resolved.
Show resolved Hide resolved

edm4hep::MCRecoDriftChamberDigiV2Association:
Description: "Association between a DriftChamberDigi and the corresponding simulated hit"
Author: "B. Francois, CERN"
Members:
- float weight // weight of this association
OneToOneRelations:
- edm4hep::DriftChamberDigiV2 digi // reference to the digitized hit
- edm4hep::SimTrackerHit sim // reference to the simulated hit

interfaces:
edm4hep::TrackerHit:
Description: "Evolution of tracker hit interface class"
Author: "Thomas Madlener, DESY"
Members:
- uint64_t cellID // ID of the sensor that created this hit
- int32_t type // type of the raw data hit
- int32_t quality // quality bit flag of the hit
- float time [ns] // time of the hit
- float eDep [GeV] // energy deposited on the hit
- float eDepError [GeV] // error measured on eDep
- edm4hep::Vector3d position [mm] // hit position
Types:
- edm4hep::TrackerHit3D
- edm4hep::TrackerHitPlane
- edm4hep::DriftChamberDigiV2
Loading
Loading