biopsykit.signals.imu.wear_detection module¶
Module for detection non-wear times from raw acceleration signals.
- class biopsykit.signals.imu.wear_detection.WearDetection(sampling_rate)[source]¶
Bases:
objectInitialize a new
WearDetectioninstance.- Parameters
sampling_rate (float) – sampling rate of recorded data in Hz
- predict(data)[source]¶
Predict non-wear times from acceleration data.
- Parameters
data (array_like) – input acceleration data. Must be 3-d.
- Returns
dataframe with wear (1) and non-wear (0) times per 15 minute interval
- Return type
- static get_major_wear_block(data)[source]¶
Return major wear block.
The major wear block is the longest continuous wear block in the data.
- Parameters
data (
DataFrame) – data with wear detection applied. The dataframe is expected to have a “wear” column.- Returns
- Return type
See also
predict()apply wear detection on accelerometer data