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

Numerical Problems with UInt waveforms #33

Open
theHenks opened this issue Feb 3, 2025 · 2 comments
Open

Numerical Problems with UInt waveforms #33

theHenks opened this issue Feb 3, 2025 · 2 comments

Comments

@theHenks
Copy link

theHenks commented Feb 3, 2025

In case you are loading a RDWaveform which consists of Integers, most filter code in RadiationDetectorDSP fails because it wants to return Int types for each sample after the filter is applied.
So far, we convert the waveforms by something like this:

wvfs = shift_waveform.(wvfs, 0.0)

There should be a more elegant solution than this.

CC @fhagemann

@fhagemann
Copy link
Contributor

First thing I would think of: limit the filters that require floating point precision to floating point precision
(<:AbstractFloat instead of <:Real, <:Union{<:AbstractFloat, Quantity{<:AbstractFloat}} instead of RealQuantity)

@oschulz
Copy link
Member

oschulz commented Feb 3, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants