-
Notifications
You must be signed in to change notification settings - Fork 73
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added timestamp calculation to detsim city
Timestamp calculation is based on rate parameter and event number. In this commit there are all the changes: - Added get_rate_safe() function to detsim/sensor_utils.py. This is a function to get rate value safely before generate timestamp (event_number / rate). - Implementation of calculated timestamp into MC_hits_from_files() and get rate safely - Added rate variable (0.5 Hz) to detsim.conf - Implemented rate parameter in detsim() function and MC_hits_from_files() call inside detsim() - Added test for get_rate_safe function. - Updated output file of test_detsim_exact
- Loading branch information
1 parent
b7d66a4
commit cecf8f6
Showing
6 changed files
with
46 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,3 +34,5 @@ compression = "ZLIB4" | |
|
||
# How frequently to print events | ||
print_mod = 1 | ||
|
||
rate = 0.5 * hertz |
4 changes: 2 additions & 2 deletions
4
invisible_cities/database/test_data/detsim_new_kr83m_fast.newformat.sim.h5
Git LFS file not shown
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters