-
Notifications
You must be signed in to change notification settings - Fork 7
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
More ljl_propfunc
functionality
#78
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One duplicate, otherwise this looks fine to me
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #78 +/- ##
==========================================
- Coverage 41.96% 35.42% -6.54%
==========================================
Files 26 25 -1
Lines 1959 1863 -96
==========================================
- Hits 822 660 -162
- Misses 1137 1203 +66 ☔ View full report in Codecov by Sentry. |
@fhagemann I resolved the duplicates, let's merge. |
@theHenks do you have some examples on how these will be used? I'm worried that we may be pushing this a bit too far, we shouldn't store algorithms ( |
I added these since I want to have variety in the description of the LAr anti-coincidence classifier and to express this in metadata. So far, we do, for example something like this hard-coded in let a = a, m = m
@pf (
trig_pe = $trig_max .* m .+ a,
trig_is_dc = [any(abs.($trig_pos_DC .- pos) .< 100u"ns") for pos in $trig_pos],
)
end Since the discharge trig_is_dc = [any(abs.($trig_pos_DC[findall.($trig_max_DC .> trig_max_DC_threshold)] .- pos) .< 100u"ns") for pos in $trig_pos], Etc. |
We should not turn metadata into a generic programming language, that's a rabbithole. Values and simple value combinations ("calibration functions") yes (like the |
I see your point. But then do you propose to put e.g. all the LAr cut generation into separate functions? |
Are we really going to use a large number of different algorithms for different channels? |
af586d5
to
3fc7739
Compare
I force-pushed to resolve the merge conflict introduced after merging #79 |
Will we use channel-dependent code for the unblinding? Also, the code that generates the files will need to know the functional form(s) - and so that's already under version control. So we may as well have the algorithm function under version control directly. JSON strings should not be used to exchange code between packages.
I assume we'll have a finite number of them, though? In the end, this is similar to DSP, we also don't put DSP chains as code into JSON files. |
Yes, we will probably have to handle channels independently because of the cross-talk between SiPMs and HPGe channel. Can you tell us which functions you don't want to have in here? If I can't put this in here than I have to move the whole logic into |
Definitely not I'm also very doubtful about |
Same for |
Oh, sorry, yes, we already had |
As far as |
What's an example use case for |
Actually we may want/need |
Some of the requested functions (not |
The PR now includes a lot of reversals to old code? |
I am sorry, I messed up my git. Will fix that! |
9af3a90
to
c835c1f
Compare
Increase possible functions in the allowed func set for the
ljl_propfunc
In particular needed for the SiPM processing and the definition of the
LAr
anti-coincidence conditions in metadata.