diff --git a/Project.toml b/Project.toml index 7011f96..6f33f6a 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "OndaEDF" uuid = "e3ed2cd1-99bf-415e-bb8f-38f4b42a544e" authors = ["Beacon Biosignals, Inc."] -version = "0.12.1" +version = "0.12.2" [deps] Compat = "34da2185-b29b-5c13-b0c7-acf172513d20" diff --git a/src/import_edf.jl b/src/import_edf.jl index eb7dce9..98559e2 100644 --- a/src/import_edf.jl +++ b/src/import_edf.jl @@ -267,6 +267,13 @@ end ##### `EDF.Signal`s -> `Onda.Samples` ##### +const SAMPLES_ENCODED_WARNING = """ + !!! warning + Returned samples are integer-encoded. If these samples are being serialized out (e.g. via `Onda.store!`) + this is not an issue, but if the samples are being immediately analyzed in memory, call `Onda.decode` + to decode them to recover the time-series voltages. + """ + struct SamplesInfoError <: Exception msg::String cause::Exception @@ -517,6 +524,8 @@ If `validate=true` (the default), the plan is validated against the If `dither_storage=missing` (the default), dither storage is allocated automatically as specified in the docstring for `Onda.encode`. `dither_storage=nothing` disables dithering. + +$SAMPLES_ENCODED_WARNING """ function edf_to_onda_samples(edf::EDF.File, plan_table; validate=true, dither_storage=missing) @@ -632,6 +641,7 @@ See `Onda.encode`'s docstring for more details. This function is not meant to be called directly, but through [`edf_to_onda_samples`](@ref) +$SAMPLES_ENCODED_WARNING """ function onda_samples_from_edf_signals(target::SamplesInfoV2, edf_signals, edf_seconds_per_record; dither_storage=missing) @@ -804,6 +814,8 @@ following transformations: (e.g. "m1" in an EEG-matched channel name will be converted to "a1"). See the OndaEDF README for additional details regarding EDF formatting expectations. + +$SAMPLES_ENCODED_WARNING """ function edf_to_onda_samples(edf::EDF.File; kwargs...) signals_plan = plan_edf_to_onda_samples(edf; kwargs...)