Low power receiver for in vivo channel sensing and ingestible sensor detection with wandering frequency

The wearable device system addresses the challenge of processing discontinuous data from ingestible event markers and physiological metrics by using enhanced algorithms and vector coprocessors to improve accuracy and reduce resource consumption, achieving precise step counts, heart rates, and orientation determination.

JP2024123169AActive Publication Date: 2024-09-10OTSUKA PHARM CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
JP2024100484
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Priority Date
2018-06-15
Filing Date
2024-06-21
Publication Date
2024-09-10
Estimated Expiration
2039-06-14

AI Technical Summary

Technical Problem

Wearable devices face challenges in accurately processing discontinuous data from ingestible event markers and physiological metrics due to limited resources and the need for high performance, leading to inaccurate physiological metric calculations such as step counts, heart rates, and orientation determination.

Method used

The system employs a wearable device with a processor and algorithms that handle discontinuous data by enriching accelerometer and ECG data using vector coprocessors and processors, applying filters and threshold adjustments to enhance data quality, and using reference vectors for orientation, thereby improving accuracy and reducing resource consumption.

Benefits of technology

The system achieves accurate determination of step counts within ±3% error, heart rates, and orientation with reduced power consumption, while handling discontinuous data effectively, enhancing the performance and accuracy of wearable devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2024123169000001
    Figure 2024123169000001
Patent Text Reader

Abstract

To provide a system and the like which can increase the accuracy of physiological metrics while detecting if a patient ingested digital medicine and / or improve performance of a wearable device.SOLUTION: A wearable device can comprise machine executable instructions that when executed by a processor, cause the processor to perform various algorithms, such as, for example, at least one of a step count algorithm, a body angle algorithm, a heart rate algorithm, a peak finder algorithm, an adaptive thresholding algorithm, a heart rate variability algorithm, a R-R cleaning algorithm, a delta R- R cleaning algorithm, a merge twin interval algorithm, a split tali intervals algorithm, an absorb short intervals algorithm, a bimodal detection algorithm, and a resting algorithm.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

[Background technology]

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS This application claims priority to U.S. Provisional Patent Application No. 62 / 685,878, entitled "LOW POWER RECEIVER FOR IN VIVO CHANNEL SENSING AND INGESTIBLE SENSOR DETECTION WITH WANDERING FREQUENCY," filed June 15, 2018, the entire contents of which are incorporated herein by reference in their entirety.

[0002] Wearable receiver assemblies can be utilized to detect signals transmitted through an individual from ingestible event markers (IEMs) and / or other physiological metrics. Various examples of such receiver assemblies can feature a reusable component that contains the firmware and electronics, and a disposable adhesive strip component that contains the electrodes and power source. Analysis of data from IEMs and other physiological metrics presents challenges. Summary of the Invention [Means for solving the problem]

[0003] In one example, a system for determining a step count of a patient is provided. The system includes a wearable device and a processor of at least one of the wearable device and a remote device communicatively coupled to the wearable device. The wearable device includes an accelerometer, the wearable device is configured to be coupled to a body of the patient and configured to detect discontinuous data utilizing at least the accelerometer. The discontinuous data includes frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data. The processor is configured to use the detected physiological data to determine a step count within a speed range of 80 to 150 steps per minute, with an average error of ±3 percent measured over at least 1000 steps.

[0004] In another example, a wearable device is provided that includes a processor coupled to a non-transitory memory, the non-transitory memory including machine executable instructions that, when executed on the processor, cause the processor to receive discontinuous data including frames of ingestible sensor data and frames of physiological data of a patient interspersed with time gaps between the frames of ingestible sensor data, and use the detected physiological data to determine a step count at a speed range of 80 to 150 steps per minute with an average error of ±3 percent measured over at least 1000 steps.

[0005] In yet another example, a method is provided for determining a patient's step count from discontinuous data. The method includes receiving discontinuous data including frames of ingestible sensor data and frames of physiological data interspersed with time gaps between the frames of ingestible sensor data. The physiological data includes accelerometer data from an accelerometer. The method includes enhancing the accelerometer data and calculating a number of level crossings in the enhanced accelerometer data, thereby obtaining a step count.

[0006] In one example, a system for automatically determining an orientation is provided. The system includes a wearable device and a processor of at least one of the wearable device and a remote device communicatively coupled to the wearable device. The wearable device includes an accelerometer. The wearable device is configured to be coupled to a patient's body and configured to detect discontinuous data utilizing at least the accelerometer. The discontinuous data includes frames of ingestible sensor data and frames of patient physiological data interspersed in time gaps between the frames of ingestible sensor data. The processor is configured to automatically determine an orientation of the wearable device relative to the patient's body utilizing the detected physiological data.

[0007] In another example, a wearable device is provided that includes a processor coupled to a non-transitory memory that includes machine executable instructions that, when executed on the processor, cause the processor to receive discontinuous data including frames of ingestible sensor data and frames of patient physiological data interspersed with time gaps between the frames of ingestible sensor data, the physiological data including accelerometer data, and utilizing the accelerometer data to automatically determine an orientation of the wearable device relative to the patient's body.

[0008] In yet another example, a method for automatically determining orientation is provided that includes receiving discontinuous data including frames of ingestible sensor data and frames of physiological data interspersed with time gaps between the frames of ingestible sensor data, the physiological data including accelerometer data from a wearable device, the method also including automatically determining an orientation of the wearable device relative to a patient's body utilizing the accelerometer data.

[0009] In one example, a system for determining a patient's heart rate is provided. The system includes a wearable device including electrodes. The wearable device is configured to be coupled to a patient's body and configured to detect discontinuous data utilizing at least the electrodes. The discontinuous data includes frames of ingestible sensor data and frames of patient physiological data interspersed in time gaps between the frames of ingestible sensor data. The system also includes a vector co-processor of at least one of the wearable device and a remote device communicatively coupled to the wearable device. The vector co-processor is configured to enhance the frames of physiological data. The system also includes a processor of at least one of the wearable device and the remote device. The processor is configured to determine a patient's heart rate using the enhanced frames of physiological data.

[0010] In another example, a wearable device is provided that includes a processor coupled to a non-transitory memory that includes machine executable instructions that, when executed on a processor and / or a vector coprocessor, cause the processor and / or coprocessor to receive discontinuous data including frames of ingestible sensor data and frames of physiological data of a patient interspersed in time gaps between the frames of ingestible sensor data, enhance, by the coprocessor, the frames of physiological data, and determine, by the processor, a heart rate of the patient using the enhanced frames of physiological data.

[0011] In yet another example, a method for determining a heart rate of a patient is provided. The method includes receiving discontinuous data utilizing at least the electrodes. The discontinuous data includes frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data. The method also includes enhancing, by a co-processor, the frames of physiological data and determining, by the processor, a heart rate of the patient using the enhanced frames of physiological data.

[0012] In one example, a system for determining level crossings in discontinuous data is provided. The system includes a wearable device and a processor of at least one of the wearable device and a remote device communicatively coupled to the wearable device. The wearable device is configured to be coupled to a patient's body and configured to detect continuous data. The discontinuous data includes frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data. The processor is configured to handle boundary effects in the frames of physiological data and to calculate a number of level crossings.

[0013] In another example, a wearable device is provided that includes a processor coupled to a non-transitory memory that includes machine executable instructions that, when executed by the processor, cause the processor to receive discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data, handle boundary effects in the frames of physiological data, and calculate a number of level crossings in the physiological data.

[0014] In yet another example, a method for determining a number of level crossings in discontinuous data is provided that includes receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data, handling boundary effects in the frames of physiological data, and calculating a number of level crossings in the discontinuous data.

[0015] In one example, a system for determining a patient's heart rate variability is provided. The system includes a wearable device and a processor of at least one of the wearable device and a remote device communicatively coupled to the wearable device. The wearable includes an electrode device and is configured to be coupled to a patient's body and is configured to detect discontinuous data utilizing at least the electrodes. The discontinuous data includes frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data. The processor is configured to group at least two of the frames of physiological data together into a block and utilize the block to determine the patient's heart rate variability.

[0016] In another example, a wearable device is provided that includes a processor coupled to a non-transitory memory that includes machine executable instructions that, when executed by the processor, cause the processor to receive discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data, group at least two of the frames of physiological data together into a block, and utilize the block to determine heart rate variability of the patient.

[0017] In yet another example, a method for determining heart rate variability of a patient is provided that includes receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data, grouping at least two of the frames of physiological data together into a block, and utilizing the block to determine heart rate variability of the patient.

[0018] In one example, a system for determining a patient's resting state is provided. The system includes a wearable device and a processor of at least one of the wearable device and a remote device communicatively coupled to the wearable device. The wearable device includes an accelerometer, the wearable device configured to be coupled to a body of the patient and configured to detect discontinuous data utilizing at least the accelerometer and electrodes. The discontinuous data includes frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data. The physiological data includes accelerometer data from the accelerometer. The processor is configured to determine that the patient is resting based on the accelerometer data.

[0019] In another example, a wearable device is provided that includes a processor coupled to a non-transitory memory that includes machine executable instructions that, when executed by the processor, cause the processor to receive discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data, and to determine that the patient is at rest based on the accelerometer data.

[0020] In yet another example, a method for determining patient rest is provided that includes receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from the patient interspersed with time gaps between the frames of ingestible sensor data, and determining that the patient is resting based on accelerometer data.

[0021] The novel features of the various aspects described herein are set forth with particularity in the appended claims, however the various aspects, both as to organization and method of operation, may be better understood by reference to the following description taken in conjunction with the accompanying drawings, in which: [Brief description of the drawings]

[0022] [Figure 1] FIG. 1 is a system diagram illustrating a wearable device according to the present disclosure.

[0023] [Diagram 2] FIG. 2 shows a front view of a wearable device according to the present disclosure.

[0024] [Diagram 3] FIG. 3 shows accelerometer data including individual traces for each axis according to the present disclosure.

[0025] [Figure 4A] FIG. 4A illustrates the analysis of various types of accelerometer data by a comparison algorithm. [Figure 4B] FIG. 4B illustrates the analysis of various types of accelerometer data by a comparison algorithm. [Figure 4C] FIG. 4C illustrates the analysis of various types of accelerometer data by a comparison algorithm. [Figure 4D] FIG. 4D illustrates the analysis of various types of accelerometer data by a comparison algorithm. [Figure 4E] FIG. 4E illustrates the analysis of various types of accelerometer data by a comparison algorithm.

[0026] [Diagram 5] FIG. 5 shows a plot of the accelerometer data analyzed by the comparison algorithm.

[0027] [Figure 6] FIG. 6 is a flow chart illustrating step count determination from accelerometer data according to the present disclosure.

[0028] [Figure 7A] FIG. 7A is a flow chart illustrating step count determination from two blocks of acceleration data in accordance with the present disclosure. [Figure 7B] FIG. 7B is a flow chart illustrating step count determination from two blocks of acceleration data in accordance with the present disclosure.

[0029] [Figure 8] FIG. 8 is a plot illustrating enhancement of accelerometer data to determine whether walking or other activity is indicative of the accelerometer data in accordance with the present disclosure.

[0030] [Figure 9] FIG. 9 is a block diagram illustrating a state machine for determining level crossings in accordance with the present disclosure.

[0031] [Figure 10A] FIG. 10A illustrates the analysis of various types of acceleration data by a comparison algorithm and a step counting algorithm according to the present disclosure. [Figure 10B] FIG. 10B illustrates the analysis of various types of acceleration data by a comparison algorithm and a step counting algorithm according to the present disclosure. [Figure 10C] FIG. 10C illustrates the analysis of various types of acceleration data by a comparison algorithm and a step counting algorithm according to the present disclosure. [Figure 10D] FIG. 10D illustrates the analysis of various types of acceleration data by a comparison algorithm and a step counting algorithm according to the present disclosure. [Figure 10E] FIG. 10E illustrates the analysis of various types of acceleration data by a comparison algorithm and a step counting algorithm according to the present disclosure.

[0032] [Figure 11A] FIG. 11A is a plot showing accelerometer data with threshold adjustment according to the present disclosure. [Figure 11B] FIG. 11B is a plot showing accelerometer data with threshold adjustment according to the present disclosure. [Figure 11C] FIG. 11C is a plot showing accelerometer data with threshold adjustment according to the present disclosure.

[0033] [Figure 12] FIG. 12A is a plot of acceleration data obtained from walking, and FIG. 12B is a plot of autocorrelation data obtained from the acceleration data of FIG. 12A in accordance with the present disclosure.

[0034] [Figure 13] 13A-13B are plots of autocorrelation data for various activities according to the present disclosure.

[0035] [Figure 14] FIG. 14 shows plots of various pedometers and various patient reported step counting rates as output by a wearable device including a comparison algorithm and a step counting algorithm according to the present disclosure.

[0036] [Figure 15] FIG. 15 is a block diagram of discontinuous data according to the present disclosure.

[0037] [Figure 16] FIG. 16 is a plot of subframes of accelerometer data according to the present disclosure.

[0038] [Figure 17]FIG. 17 is a plot of subframes of accelerometer data showing boundary effects.

[0039] [Figure 18] FIG. 18 shows a subframe of accelerometer data showing gradient changes.

[0040] [Figure 19] FIG. 19 shows the step counting algorithm processed in the processor of the wearable device and the step count values ​​output from a MATLAB model for post-processing raw accelerometer data from a wearable device on a remote device according to the present disclosure.

[0041] [Figure 20A] FIG. 20A is a plot of the total activity data. [Figure 20B] FIG. 20B is a plot of the acceleration data before and after boxcar filtering.

[0042] [Figure 21A] FIG. 21A is a block diagram illustrating generation of reference vectors by filling bins with ACRs according to the present disclosure. [Figure 21B] FIG. 21B is a block diagram illustrating generation of reference vectors by filling bins with ACRs in accordance with the present disclosure. [Figure 21C] FIG. 21C is a block diagram illustrating generation of reference vectors by filling bins with ACRs in accordance with the present disclosure. [Figure 21D] FIG. 21D is a block diagram illustrating generation of reference vectors by filling bins with ACRs in accordance with the present disclosure.

[0043] [Figure 22] FIG. 22A is a plot of heart rate data showing large blocks of missing data, FIG. 22B is a plot of body angle over time corresponding to the data in FIG. 22A, and FIG. 22C is a plot of raw ECG data that was ignored in the previous comparison algorithm.

[0044] [Diagram 23] FIG. 23 is a flow chart illustrating receipt and processing of ECG data according to the present disclosure.

[0045] [Figure 24] FIG. 24 is a flow chart illustrating enhancement of ECG data according to the present disclosure.

[0046] [Diagram 25] FIG. 25 is a plot illustrating the magnitude of response of a high pass filter in accordance with the present disclosure.

[0047] [Figure 26] FIG. 26 is a plot illustrating the magnitude of response of a low pass filter in accordance with the present disclosure.

[0048] [Figure 27] FIG. 27 is a plot illustrating the magnitude of response of a derivative filter according to the present disclosure.

[0049] [Figure 28] FIG. 28 is a plot showing magnitude of response for a boxcar filter in accordance with the present disclosure.

[0050] [Figure 29] 29A-29F are plots illustrating conversion of raw ECG data to enhanced ECG data by a vector co-processor including downsampling, in accordance with the present disclosure.

[0051] [Diagram 30] 30A-30G are plots illustrating the conversion of raw ECG data to enhanced ECG data by a vector co-processor according to the present disclosure.

[0052] [Diagram 31] FIG. 31 is a block diagram illustrating normalization of ECG data according to the present disclosure.

[0053] [Diagram 32] FIG. 32 is a block diagram illustrating distribution of buffers into subframes of an ECG frame of data in accordance with the present disclosure.

[0054] [Diagram 33] FIG. 33 is a flow chart illustrating processing of enhanced ECG data in a processor according to the present disclosure.

[0055] [Diagram 34] FIG. 34 is a block diagram illustrating a state machine of a peak finder algorithm according to the present disclosure.

[0056] [Diagram 35] 35A-B are plots illustrating a peak finder algorithm and peak refinement according to the present disclosure.

[0057] [Figure 36A] FIG. 36A is a plot illustrating adaptive thresholding according to the present disclosure. [Figure 36B] FIG. 36B is a plot illustrating adaptive thresholding according to the present disclosure. [Figure 36C] FIG. 36C is a plot illustrating adaptive thresholding according to the present disclosure. [Figure 36D] FIG. 36D is a plot illustrating adaptive thresholding according to the present disclosure. [Figure 36E] FIG. 36E is a plot illustrating adaptive thresholding in accordance with the present disclosure.

[0058] [Figure 37] FIG. 37 is a plot illustrating T wave rejection in accordance with the present disclosure. [Figure 38] FIG. 38 is a plot illustrating T wave rejection according to the present disclosure. [Figure 39] FIG. 39 is a plot illustrating T wave rejection according to the present disclosure.

[0059] [Diagram 40]FIG. 40 is a plot of various ECG data according to the present invention.

[0060] [Diagram 41] FIG. 41 is a plot of the sensitivity of the comparative algorithm and the HR algorithm according to the present disclosure.

[0061] [Diagram 42] FIG. 42 is a plot of the positive predictive data for the comparative algorithm and the HR algorithm according to the present disclosure.

[0062] [Diagram 43] 43A-C are plots of the results of sensitivity averaging across all 48 records in the MIT-BIH arrhythmia database with various added noise and with the quality filter on in a HR algorithm according to the present disclosure.

[0063] [Figure 44A] FIG. 44A is a plot of ECG data for various patients measured using a HR algorithm and comparative heart rate monitor according to the present disclosure. [Figure 44B] FIG. 44B is a plot of ECG data for various patients measured using a HR algorithm and comparative heart rate monitor according to the present disclosure. [Figure 44C] FIG. 44C is a plot of ECG data for various patients measured using a HR algorithm and comparative heart rate monitor according to the present disclosure. [Fig.44D] FIG. 44D is a plot of ECG data for various patients measured using a HR algorithm and comparative heart rate monitor according to the present disclosure. [Figure 44E] FIG. 44E is a plot of ECG data for various patients measured using a HR algorithm and comparative heart rate monitor according to the present disclosure.

[0064] [Figure 45A] FIG. 45A is a plot of ECG data during various activities. [Figure 45B] FIG. 45B is a plot of ECG data during various activities. [Figure 45C] FIG. 45C is a plot of ECG data during various activities. [Figure 45D] FIG. 45D is a plot of ECG data during various activities.

[0065] [Diagram 46] FIG. 46 is a flow chart illustrating the processing of ECG data to determine an HRV metric according to the present disclosure.

[0066] [Figure 47] FIG. 47 is a flowchart illustrating data flow for comparing HRV metrics according to the present disclosure.

[0067] [Figure 48] FIG. 48 is a plot showing HRV metrics for patient 5 in accordance with the present disclosure.

[0068] [Figure 49] FIG. 49 is a flow chart for determining serenity in accordance with the present disclosure.

[0069] [Figure 50] FIG. 50 is a detailed flow chart showing the blocks for the intermittent inactivity calculation of FIG. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0070] Various examples are described and illustrated herein for a general understanding of the structure, function, and use of the disclosed items and methods. The various examples described and illustrated herein are non-limiting and non-exhaustive. Thus, the present invention is not limited by the description of the various non-limiting and non-exhaustive examples disclosed herein. Rather, the present invention is defined only by the claims. Features and characteristics described and / or illustrated in connection with the various examples may be combined with features and characteristics of other examples. Such modifications and variations are intended to be included within the scope of the present specification. Thus, the claims may be amended to recite any feature or characteristic explicitly or inherently described herein or explicitly or inherently supported herein. Furthermore, the applicant reserves the right to amend the claims to affirmatively disclaim any feature or characteristic that may exist in the prior art. The various examples disclosed and described herein may include, consist of, or consist essentially of the features and characteristics variously described herein.

[0071] Reference herein to "various examples," "several examples," "one example," "an example," or similar phrases means that a particular feature, structure, or characteristic described in connection with said example is included in at least one example. Thus, the appearance of "in various examples," "in several examples," "in one example," "in one example," or similar phrases in the specification does not necessarily refer to the same example. Furthermore, certain described features, structures, or characteristics can be combined in any suitable manner in one or more examples. Thus, a particular feature, structure, or characteristic described or illustrated in connection with one example can be combined, in whole or in part, without limitation, with features, structures, or characteristics of one or more other examples. Such modifications and variations are intended to be included within the scope of the present examples.

[0072] As used herein, unless otherwise indicated, all numerical parameters should be understood to be modified in all instances by the term "about," given the inherent variability characteristic of the underlying measuring technique used to determine the numerical value of the parameter. At the very least, and not as an attempt to limit the application of the doctrine of equivalents to the scope of the claims, each numerical parameter set forth herein should at least be construed in light of the number of reported significant digits and by applying ordinary rounding techniques.

[0073] Also, any numerical range recited herein includes all subranges subsumed within the recited range. For example, a range of "1 to 10" includes all subranges between the recited minimum of 1 and the recited maximum of 10 (inclusive), i.e., having a minimum of 1 or more and a maximum of 10 or less. Any maximum numerical limitation recited herein is intended to include all lower numerical limitations subsumed therein, and any minimum numerical limitation recited herein is intended to include all higher numerical limitations subsumed therein. Accordingly, applicants reserve the right to amend this specification, including the claims, to expressly recite any subranges subsumed within the expressly recited range. All such ranges are inherently recited herein.

[0074] Unless otherwise indicated, the grammatical articles "a," "an," and "the," as used herein, are intended to include "at least one" or "one or more," even if "at least one" or "one or more" is expressly used in a particular instance. Accordingly, the foregoing grammatical articles are used herein to refer to one or more (i.e., "at least one") of the specifically identified elements. Furthermore, unless the context of usage requires otherwise, the use of a singular noun includes the plural and the use of a plural noun includes the singular.

[0075] The wearable device can be coupled (e.g., attached) to a patient's body (e.g., skin) and can determine whether the patient has taken a digital medicine (e.g., an ingestible event marker (IEM) embedded in a pill or other pharmaceutical product) and / or the frequency of ingestion from ingestible sensor data generated by the IEM. The ingestible sensor data can be generated from the IEM after contact with the patient's bodily fluids, e.g., stomach acid. The wearable device can also determine physiological metrics, such as step count, body angle, heart rate, heart rate variability, rest, and resting heart rate. Although the wearable device may be battery powered and may have limited resources, such as memory, battery life, computing power, and communication bandwidth, the wearable device may need to detect all of the patient's intake of digital medicine, including IEM (e.g., high frequency, internal body electrical signals - 10 KHz and above), and also detect and / or receive various types of physiological data (e.g., high resolution sensor data, e.g., electrocardiogram (ECG) data and accelerometer data). Due to the high performance requirements but limited resources, various algorithms and other innovations are presented herein to optimize the performance and improve battery life of the wearable device and / or the system comprising the wearable device.

[0076] The various algorithms (e.g., step counting algorithm, body angle algorithm, heart rate algorithm, peak finder algorithm, adaptive thresholding algorithm, heart rate variability algorithm, RR cleaning algorithm, delta RR cleaning algorithm, merge twin interval algorithm, split tall interval algorithm, absorb short interval algorithm, bimodal detection algorithm, resting algorithm) and other innovations can be solo on the wearable device or can be distributed across the wearable device and the remote device (e.g., paired mobile device, back-end server, cloud). The various algorithms can be executed by the processor of the wearable device and / or the processor of the remote device. While the remote device may be less resource constrained, the remote device may receive lower resolution data that is post-processed by the patch, which may impact the accuracy of the physiological metrics. In this way, the various algorithms and other innovations can balance the limited resources of the wearable device with the need for high accuracy physiological metrics, such as ANSI EC-13.

[0077] A wearable device and / or a system including a wearable device can be configured to detect and / or receive discontinuous data including frames of ingestible sensor data and frames of patient physiological data interspersed in time gaps between the frames of ingestible sensor data. Different types of physiological data can be detected, received, and / or processed in parallel, while ingestible sensor data can be detected, received, and / or processed serially with the physiological data. That is, the wearable device can rapidly switch between detecting, receiving, and / or processing ingestible sensor data and detecting, receiving, and / or processing physiological data. The ingestible sensor data and physiological data can be detected, received, and / or processed sequentially and may not be parallel in time to one another. Stitching together and / or stitching together frames of physiological data to obtain accurate physiological metrics while detecting whether a patient has taken a digital medicine can be a challenge.

[0078] Thus, examples of the present disclosure may include various algorithms according to the present disclosure that may increase the accuracy of physiological metrics and / or improve the performance of a wearable device while detecting whether a patient has taken a digital medicine. Examples of the present disclosure may accurately process discontinuous data, which may allow for reduced memory requirements and reduced processing requirements.

[0079] The frames of data utilized may be prioritized based on a desired power consumption (e.g., battery life), a desired accuracy, and / or a desired data transfer size of the wearable device and / or a system including the wearable device. In various examples, the wearable device and / or a system including the wearable device may be configured to detect and / or receive a first continuous data including frames of ingestible sensor data and a second continuous data including frames of physiological data.

[0080] Wearable Device Structure

[0081] FIG. 1 shows a system diagram of an example of a wearable device 102. The wearable device can be configured to removably attach to the skin of a patient. The wearable device can be re-wearable or the wearable device can be disposable. The wearable device 102 can include at least two parts, including a disposable part 110 and an electronics module 120 (e.g., a reusable electronics module). Each of the disposable part 110 and the electronics module can include a printed circuit board assembly (PCBA). The electronics module 120 can include a computing platform 108, a processor 111 (e.g., a microcontroller unit (MCU)), a wireless communication circuit 106, a universal serial bus 134 (USB), an accelerometer (ACC) 122, a memory 112, an LED 136, a 32KHz crystal clock (X-Tal) 126, a user button 140 that can be used to initiate a communication connection with an external device, and a sensor interface 116. In various examples, the electronics module 120 may include a gyroscope, a body composition circuit, an SpO2 oximetry circuit, and circuits for processing ECG, temperature, and accelerometer signals. The SpO2 pulse oximetry circuit can monitor the functional oxygen saturation of arterial blood by calculating the ratio of oxyhemoglobin to hemoglobin capable of transporting oxygen. The SpO2 pulse oximetry circuit can be configured to provide a continuous non-invasive measurement of SpO2 and can display a plethysmographic waveform. A heart rate value can be derived from the SpO2 pulse oximetry signal. The electronics module 220 also includes a connection port for an external memory, a connection port for an external sensor, and a hardware accelerator.

[0082] The electronics module 120 may include an application specific integrated circuit (ASIC) based computing platform 108, which may include a hardware structure and a software framework for implementing various functions of the wearable device 102. The computing platform 108 may be disposed on and interfaced with a PCBA of the electronics module 120. The disposable components 110 may interface with the PCBA of the electronics module 120. The electronics module 120 and the disposable components 110 may each include additional modules that may be disposed on the PCBA of the respective components 110, 120 or that may be removed from the PCBA of the respective modules 110, 120.

[0083] The computing platform 108 may comprise circuitry designed to interface with a combination of various sensors and components of the wearable device 102. For example, the computing platform 108 may provide a combination of analog front-end, vector / digital signal processing, microprocessor and memory in a single low-power ASIC / chip that may include multiple functions, such as, for example, software defined radio for ingestible event marker detection, electrocardiogram (ECG) signal sensing and decoding, AC skin impedance measurement, temperature measurement (e.g., skin and / or ambient), DC skin impedance (e.g., galvanic skin response (GSR)) measurement, accelerometer measurement, and other biological / medical data sensors.

[0084] The processor 111 may be a central processing unit (CPU). The processor 111 may be implemented as a general-purpose processor, a chip multiprocessor (CMP), a special-purpose processor, an embedded processor, a digital signal processor (DSP), a network processor, a media processor, an input / output (I / O) processor, a media access control (MAC) processor, a wireless baseband processor, a vector coprocessor, a microprocessor, such as a multiple instruction set computer (CISC) microprocessor, a reduced instruction set computing (RISC) microprocessor, and / or a very long instruction word (VLIW) microprocessor, or other processing device. The processor may also be implemented by a controller, a microcontroller, an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), a programmable logic device (PLD), or the like.

[0085] The processor 111 may be configured to execute an operating system (OS) and various mobile applications. For example, the OS may include an operating system commonly known under the trade name Microsoft Windows OS, and any other proprietary or open source OS. The mobile applications may include, for example, a phone app, a camera (e.g., digital camera, video camera) app, a browser app, a multimedia player app, a game app, a messaging app (e.g., email, short message, multimedia), a viewer app, and the like. The processor 111 may be arranged to receive information through a communication interface. The communication interface may include any suitable hardware, software, or combination of hardware and software capable of coupling the wearable device 102 to one or more networks and / or devices.

[0086] The processor 111 may include, for example, an ARM Cortex™ M3 processor for real-time applications, a signal processing accelerator (e.g., vector co-processor), such as the Vector Math Accelerator, program memory, data memory, a serial interface, such as SPI, Universal Asynchronous Receiver Transmitter (UART), 2-wire multi-master serial single-ended bus interface (I2C), general purpose input / output (GPIO), a real-time clock, an analog-to-digital converter (ADC), gain and conditioning circuitry for biopotential signals, light-emitting diode (LED) drivers, etc. The processor 111 may receive signals from each of the sensors by operating an analog front end of the analog sensor or by receiving digital data from the sensor using an ADC converter. The processor 111 may process the data and store the results in the form of data records in the memory 112. In various examples, the processor 111 may have a very long instruction word (VLIW) processor architecture.

[0087] The wireless communication circuitry 106 may be a mobile chipset radio frequency (RF) wireless circuitry or simply a cellular radio. The wireless communication circuitry 106 may be a low power mobile chipset and may be configured to connect with cellular networks as well as other remote devices (e.g., wireless devices such as mobile phones, smart phones, tablet computers, laptops, gateway devices, among others). The wireless communication circuitry 106 may include an antenna, transmitter circuitry, receiver circuitry for receiving and transmitting wireless signals, and a link master controller including mechanisms for connecting (establishing a link) and transferring data with another external wireless device, as described in detail below. The link master controller may establish a connection to an external device, e.g., a mobile device. As the master of the link, the link master controller may implement control of data transmission on the link to the external device, including timing control and radio frequency control (channel hopping). The link master controller may signal the remote device with an instruction giving the number of data records stored in memory (total number of all data records and total number of records of each data type). The wireless communication circuitry 106 can be implemented using mobile chipsets available from various vendors, including, but not limited to, Tegra from Nvidia, Snapdragon from Qualcomm, OMAP from Texas Instruments, Exynos from Samsung, Ax from Apple, NovaThor from ST-Ericsson, Atom from Intel, i.MX from Freescale Semiconductor, RK3xxx from Rockchip, A31 from AllWinner, among others. Such mobile chipsets are used in mobile phones, otherwise known in the art as "mobile", "wireless", "cellular phone", "cell phone", "handphone (HP)", and "smart phone", among others. In various examples, the wearable device 102 can communicate via wired circuitry.In various examples, the wearable device 102 can communicate via Bluetooth.

[0088] After each connection, the processor 111 can continue to receive all sensor signals, process the data, and store new data records in the memory 112. Upon each subsequent connection, the link master controller can send a signal to the remote device (e.g., external to the wearable device 102) with the new data records since the last connection and can confirm that the data records were successfully transmitted. The link master controller can receive a signal from the remote device that establishes whether the remote device is ready to receive data records and can also receive a signal from the remote device that establishes which data records were not successfully transmitted. The link master controller can avoid repeating transmissions of data records that have already been transmitted, which can improve battery power consumption for long-term operation, and can retransmit data records that were not successfully transmitted. The link master controller can delete all or part of the successfully transmitted data records from the memory 112 at a later point in time (e.g., when the memory 112 becomes full).

[0089] Memory 112 may be a non-transitory memory and may include machine-executable instructions that, when executed by processor 111, cause processor 111 and / or processors on remote devices to perform the functionality of various algorithms and other innovations described herein. In various examples, at least a portion of the machine-executable instructions are stored in memory on the remote device.

[0090] The sensor interface 116 may be disposed between the electrodes 150 and the band pass filters or channels. The sensor interface 116 may provide an analog front end and may include programmable gain or fixed gain amplifiers, programmable low pass filters, and programmable high pass filters. The sensor interface 116 may include active signal conditioning circuitry, including, for example, strain gauge measurement circuitry. One channel may receive low frequency information related to physiological data of a patient (e.g., user, subject), and another channel may receive high frequency information related to an electronic device within the patient. The high frequency channel may receive DC data of the patient. The high frequency channel data may be conveyed to a digital signal processor (DSP) implemented in the computing platform 108 and then conveyed to the processor 111 for unpacking and decoding, or may be conveyed directly to the processor 111. The low frequency channel data may be conveyed to the DSP portion of the computing platform 108 and then conveyed to the processor 111, or may be conveyed directly to the processor 111. The DSP portion and the processor 111 may decode the data from the high frequency channel and the low frequency channel. The data may then be processed and prepared for transmission.

[0091] Signal processing may or may not be applied to the raw data collected from the channels. Signal processing may be performed in real space, complex space, or polar space. Signal processing functions include filters, e.g., finite impulse response (FIR) and infinite impulse response (IIR), mixers, fast Fourier transform (FFT), trigonometric functions, among others. The raw data may simply be stored in memory 112 and processed downstream later. Signal processing may be performed by the processor 111 or by a signal processing accelerator that may be incorporated in the computing platform 108. Physiological data from various sensors on the wearable device 102 may be processed by the processor 111 and may be transmitted in real time or as raw data, or may transmit derived quantities or parameters. Physiological data may include accelerometer data, ECG data, and other physiological data. The accelerometer data may be parallel in time to the ECG data.

[0092] The electronics module 120 may include two temperature sensors 124 that are the same but located at different positions, for example, one close to the skin and one extending into the ambient environment to measure additional data. The temperature sensor 124 may be configured to measure and record skin, ambient, and circuit board temperatures. The temperature sensor 124 may be used to measure heat flux between the skin and the ambient temperature sensor. The temperature sensor 124 may be a thermistor device with a negative temperature coefficient (NTC) or a positive temperature coefficient (PTC). The temperature sensor 124 may be an integrated semiconductor device. The temperature signal may be provided to and processed by the processor 111 and prepared for transmission by a transmitter portion of the wireless communication circuitry 106.

[0093] The accelerometer 122 may be a three-axis accelerometer with a resampling frequency correction processor. As shown in FIG. 2, an example of a wearable device is provided, showing the associated X, Y, and Z axes along which the embedded accelerometer of the wearable device may measure and output accelerometer data. The accelerometer 122 may include different recording modes, for example, the wearable device 102 may record only raw accelerometer X, Y, Z data, or the wearable device 102 may record raw accelerometer X, Y, Z data and regular accelerometer metrics.

[0094] Returning to Figure 1, the accelerometer 122 may be a digital accelerometer that includes a MEMS-based acceleration sensor element, a digitizer, and digital interface control logic. The accelerometer 122 may use a low-precision resistor-capacitor (RC) oscillator to strobe the digitizer sampling input. The electronics module 120 may include an accelerometer sampling frequency correction processor that receives the signal from the accelerometer 122 and performs resampling to offset the RC oscillator error.

[0095] The accelerometer 122 may include a sampling frequency correction processor that includes a reference clock (high precision oscillator), a fixed upsample block, a digital filter, a programmable downsample block, and a control circuit that selects a downsample factor based on a comparison of the timing of the signal from the accelerometer and the reference clock. The resampling function can maintain alignment to the reference clock during a sliding window to obtain an accurate sampling rate. A time algorithm can calibrate the real-time 32 kHz crystal clock (X-Tal) 126. The accelerometer 122 sampling frequency correction processor can set a downsampling factor for each frame of data from the accelerometer signal. The timing of the accelerometer signal can be continuously tracked and the downsampling factor can be selected to minimize the accumulated timing error. Thus, the accelerometer data from the accelerometer 122 can be aligned to a precise clock with high precision.

[0096] The electronics module 120 may employ a low power, low memory data storage and transfer scheme. For example, data storage and transfer in the memory 112 may be optimized for low power and low memory usage. Physiological data from sensor signals may be stored in the memory 112 as data records, each having a type identifier. The data records may be transferred to a remote device in a packet payload by the wireless communication circuitry 106. The data records may be stored sequentially with variable length to optimize space usage in the memory 112. A data directory may be provided in the memory 112, which may enable fast record read access from the memory 112. The data directory may also enable a quick count of data records by type.

[0097] The electronics module 120 can employ a reliable integrity data storage and transfer scheme. For example, the wearable device 102 memory storage and transfer scheme can be designed for reliable data integrity. For each data record stored in the memory 112 of the wearable device 102, there can be an error detection code that can be used to detect corruption of the data record. When the wearable device 102 reads the data record from the memory 112 prior to transferring the data packet to the remote device, the error detection code can be checked. If the wearable device 102 detects corruption of the stored data record, an error signal can be transmitted by the wireless communication circuitry 106 to the remote device. Each packet transferred from the wearable device 102 to the remote device can include an error detection code that can be used to detect packet corruption at the remote device.

[0098] The signal processing accelerator portion of the computing platform 108 may include computation engines optimized to implement highly efficient signal processing tasks. The signal processing functions may be hard coded with logic that may be 10 times more efficient compared to software-based algorithms implemented in software executed on the processor 111 or other microcontroller units. The efficiency may be reduced chip size, reduced power consumption, and / or reduced clock speed. The signal processing functions may utilize execution units that are computationally optimized while maintaining a level of programmability. For example, the signal processing functions may employ a Fast Fourier Transform (FFT)-Butterfly engine that may enable FFT calculations for data sets of various sizes while maintaining significant efficiency improvements over software executed on the processor 111. The execution units may also be multiply-accumulate units (MACs), which may be common DSP function blocks, or may be floating-point computation unit(s) or FIR filter primitives, etc. In these examples, the efficiency of a given integrated circuit process may be greater than the efficiency of software on the processor 111 but less than the efficiency of dedicated hardware, but may be much more flexible in terms of balancing limited resources with the accuracy of the physiological measurement.

[0099] The signal processing accelerator can maintain an interface with the processor 111. This interface may include first-in-first-out (FIFO) registers, dual-port memory, a direct memory access (DMA) engine of the processor 111, and / or registers. The interface may include some form of contention recognition or avoidance that may be handled at the register level or memory block level. The mechanisms involved may include a register flag set that can be polled by the processor 111 and the signal processing accelerator, and an interrupt to a signal can block or delay the ability to hold a read or write request until a higher priority device has completed its activity.

[0100] The disposable parts 110 can be coupled to the PCBA of the electronics module 120. The disposable parts can include sensors attached to what is being monitored (human, animal, machine, building, etc.) for interface, such as electrodermal activity (EDA) sensors, GSR sensors, temperature sensors (e.g., skin and / or ambient), body composition sensors (50Hz), SpO2 / pulse oximetry sensors, strain gauge sensors, accelerometers, and other biological / medical data sensors. Various algorithms executed by the computing platform 108 or processor 111 can generate metrics such as, for example, step count, body angle, heart rate, heart rate variability, rest, resting heart rate, heat flux, respiration rate, stress level, fall detection, and other physiological metrics.

[0101] The disposable part 110 may also include a battery 160, a cradle for holding the battery, a battery holder or housing (cover), an adhesive, and electrodes 150 (e.g., at least two electrodes). Power may be provided to the wearable device 102 from the battery 160. The battery 160 may be a disposable coin cell with a battery life approximately equal to the useful life of the adhesive of the disposable part 110. The adhesive may attach the wearable device 102 to the patient's skin. The adhesive may include a useful life of 3-10 days for most patients. The electrodes 150 may include hydrogel electrodes and separate stainless steel electrodes. The hydrogel electrodes may be used to detect high frequency internal electrical signals (10 KHz or higher) that may indicate that the patient has taken the digital medicine.

[0102] The memory 112 may include any machine-readable or computer-readable medium capable of storing data, including both volatile and non-volatile memory. For example, the memory 112 may include read-only memory (ROM), random-access memory (RAM), dynamic RAM (DRAM), double data rate DRAM (DDR-RAM), synchronous DRAM (SDRAM), static RAM (SRAM), programmable ROM (PROM), erasable programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), flash memory (e.g., NOR or NAND flash memory), content addressable memory (CAM), polymer memory (e.g., ferroelectric polymer memory), phase change memory (e.g., ovonic memory), ferroelectric memory, silicon oxide nitride oxide silicon (SONOS) memory, disk memory (e.g., floppy disk, hard drive, optical disk, magnetic disk), or card (e.g., magnetic card, optical card), or any other type of media suitable for storing information.

[0103] Step Counting

[0104] The wearable device 102 can be worn by the patient by attaching the wearable device to the patient using an adhesive on the disposable part 110 (e.g., an adhesive strip). As the patient moves, the accelerometer 112 can provide an accelerometer signal based on the acceleration forces experienced by the accelerometer 122. Variations in acceleration can indicate the patient's movement / activity. The accelerometer signal can be converted by the wearable device 102 into accelerometer data.

[0105] Walking may be a periodic / regular movement that may be interpreted as a strong peak in the accelerometer data and / or autocorrelation data obtained from the accelerometer signal. The accelerometer data may be analyzed and used to calculate the step count (e.g., step count) taken by the patient. For example, as shown in FIG. 3, accelerometer data 302 is provided that may include traces for each axis X, Y, Z individually. The accelerometer data 302 includes a 14 second block of acceleration data where the patient wearing the wearable device 102 took 24 steps. A count of the number of times the accelerometer data 302 exceeds a threshold value may be used to determine a physiological metric of the step count from the accelerometer data 302. The step count measured from the accelerometer data 302 is 103 steps / minute based on measuring 24 steps in a 14 second period.

[0106] The wearable device 102 can be used by patients who have difficulty moving (e.g., elderly patients) or who walk at a slow pace. As used herein, "slow walking" refers to a step rate in the range of 15-80 steps / min, and normal walking refers to a step rate in the range of 80-150 steps / min. Previous comparison algorithms may not be able to accurately calculate step counts from accelerometer data for patients who are slow-walking (e.g., shuffling and / or moving slowly) or who may be driving. For example, the accelerometer data may not look like normal walking steps, and the accelerometer data may not be easily analyzed to calculate step counts. For example, the top row of FIG. 4A shows example accelerometer data at a moving speed of 100 steps / min (e.g., normal walking), and the top row of FIG. 4C shows example accelerometer data at a moving speed of 50 steps / min (e.g., slow walking).

[0107] The comparison algorithm may rely solely on counting level crossings in the autocorrelation data (e.g., thresholds shown by dashed lines in Figures 4A-4E). As shown in the bottom row of Figure 4A, counting threshold crossings in autocorrelation data resulting from normal walking may result in accurate step counts (e.g., greater than + / - 10%) based solely on level crossings. However, as shown in the bottom row of Figure 4C, counting level crossings in autocorrelation data resulting from slow walking may result in inaccurate step counts based solely on level crossings.

[0108] Referring to Figure 4E, a plot of step count data points is provided, with each point representing a 7 second block of accelerometer data consisting of only each activity identified in Figure 4E analyzed from the comparison algorithm.Normal walking data at 100 steps / min was sampled over 4 minutes with an expected value of 400 steps for step count;Slow walking data at 50 steps / min was sampled over 4 minutes with an expected value of 200 for step count;Slow shuffling data at 60 steps / min was sampled over 4 minutes with an expected value of 240 for step count;Medium shuffling data at 80 steps / min was sampled over 4 minutes with an expected value of 320 for step count;Drive data (e.g., 0 steps / min) was sampled over various times with an expected value of 0 for step count.

[0109] In addition to inaccurate step counts for slow walking, driving can cause erroneous step counts, as shown in Figures 4B, 4E, and 5. Furthermore, as shown in Table 1, a comparison pedometer that includes a comparison algorithm can provide inaccurate step counts (e.g., detect erroneous step counts while driving). Additionally, a comparison pedometer receives accelerometer data continuously (e.g., not discontinuously).

[0110] [Table 1]

[0111] Thus, a step counting algorithm is provided that inaccurately counts steps during slow walking in discontinuous data, including accelerometer data generated by the wearable device 102. The step counting algorithm can determine step counts in a step rate range of 80-150 steps / minute using detected physiological data with an average error of ±3 percent measured over at least 1000 steps. Additionally, the step counting algorithm can limit, if not prevent, erroneous step counts while driving or other types of activity.

[0112] A step counting algorithm can save memory and power by estimating a continuous step rate from discrete data. For example, every minute, a wearable device can collect a 14-second frame of accelerometer data, calculate a step rate over this frame, and interpolate the step rate to derive the number of steps per minute. To optimize accuracy, the algorithm can take into account half steps at the boundaries of the 14-second frame.

[0113] In addition, the wearable device 102 can be configured to classify data based on activity levels. For example, the wearable device 102 can distinguish "intentional walking" involving faster, more defined steps (e.g., a first activity level) compared to spontaneous walking such as a simple walk from the bathroom to the kitchen (e.g., a second activity level lower than the first activity level). The types of walking can be distinguished by a step counting algorithm based on the accelerometer data.

[0114] A step counting algorithm can receive the accelerometer data and can be distributed across the wearable device 102 and the remote device for execution by the control circuitry. For example, the step counting algorithm can be stored in memory 112 and utilized by processor 111 to convert accelerometer data received from accelerometer 122 into a physiological metric, such as step counts.

[0115] For purposes of describing the configuration of algorithms herein, accelerometer values ​​are interpreted in units of "g", where "g" represents the acceleration due to the Earth's gravity (approximately 9.8 m / s), unless otherwise specified. 2 ) For performance optimization, the design implementation can operate on the raw accelerometer counts.

[0116] The step counting algorithm may include fixed parameters such as those listed in Table 2, which may be set to default values ​​in the source code, but which can be adjusted without a total or partial redesign of the step counting algorithm (with a complete recompilation of the software).

[0117] [Table 2]

[0118] The step counting algorithm may include programmable parameters as described in Table 3. The step counting algorithm may be set to default values ​​and may be reconfigured during manufacture and / or during use via the wireless / wired interface. Each programmable parameter may maintain its set value through all state transitions and complete removal of power from the wearable device 102 (e.g., battery disconnection).

[0119] [Table 3]

[0120] The step counting algorithm can process accelerometer data during a selected time window sampled at a selected frequency. In an example of a 14 second time window and a selected frequency of 12.5 GHz, the window is 175 samples. The step count can be derived with a sample buffer containing a single block as shown in FIG. 6, or the sample buffer can be divided into two blocks, Period 1 (P1) and Period 2 (P2), as shown in FIG. 7A-7B. In an example where the number of samples is odd, one point may be left out so that each period is equal. In an example where the number of samples is 175, the 175th sample can be left out so that each period is equal.

[0121] The step counting algorithm can perform the evaluations, calculations, and transformations described herein and can generate an Accelerometer Record (ACR) as described in Table 4. The ACR can be generated one or more times per measurement period, as desired.

[0122] [Table 4]

[0123] The accelerometer data is converted to "g" (or g if g is a measure of acceleration squared) using a fixed conversion value G, defined by its sensitivity as shown in Equation 1. 2 ) The default may be 2G sensitivity.

[0124]

number

[0125] 6 shows an example flow chart of a step counting algorithm that can accurately determine a patient's step count during slow walking. As shown, x-axis accelerometer data, y-axis accelerometer data, and z-axis accelerometer data, collectively the accelerometer data, can be processed by the step counting algorithm.

[0126] The raw acceleration data (eg, vectors) in each axis of the accelerometer data can be processed by a step counting algorithm using a boxcar filter to reduce noise and remove high frequency components of the signal according to Equation 2, 602.

[0127]

number

[0128] In the example with the default parameter values ​​AccFs=12.5 Hz and M=2, frequency components below 3.125 Hz can be accurately reproduced.

[0129] Accelerometer data sampled at 12.5 Hz may have a tap filter, such as a 2-tap filter, applied to the raw acceleration data. The more taps in the filter, the more the accelerometer data is averaged. The tap filter can determine the high frequencies that can be faithfully represented. Tap filters of various lengths can be applied to the raw acceleration data to characterize the sensitivity of step counting during an activity (e.g., gym workout). The sampling rate and the digital filter (e.g., tap filter) applied to the raw acceleration data can be configured for the desired application. In various examples, the hardware of the wearable device 102 can support different sampling rates (e.g., higher sampling rates).

[0130] Postboxcar filtering of the acceleration data in each axis of the accelerometer data is performed by calculating the squared L2 norm from each axis of the accelerometer data as shown in Equation 3, 604 to obtain the total acceleration (totAcc, Acctotal,i ) can be converted to

[0131]

number

[0132] The step counting algorithm may utilize the squared L2 norm instead of the L2 norm as a computational simplification. The scaling factor in Equation 3 (e.g., divide by 2) may prevent overflow / saturation of the buffer in memory. The scaling factor may be taken into account when determining and / or programming thresholds relative to total acceleration (e.g., totActThresh, totActThreshLo).

[0133] The total activity of all acceleration data (totActivity) can be calculated by taking the standard deviation of all acceleration data (std(totAcc)) as shown in Equation 4, 4606.

[0134]

number

[0135] Total activity can be calculated independently for blocks P1 and P2 in an example having two blocks of accelerometer data, resulting in two floating point values ​​as shown in Figures 7A-7B.

[0136] Returning to Figure 6, the total activity may be used by the step counting algorithm to evaluate whether a block of accelerometer data contains valid step activity 608. For example, the step counting algorithm may evaluate whether the total activity data meets or exceeds an activity threshold. If the total activity meets or exceeds the activity threshold, the step counting algorithm proceeds to step 624, average-adjusts the accelerometer data, and evaluates the acceleration data for step counts.

[0137] However, if the total activity does not meet or exceed the activity threshold, the step counting algorithm can evaluate whether the accelerometer data should be enhanced 610. For example, the step counting algorithm can evaluate whether the total activity meets or exceeds a lower activity threshold. If the total activity does not meet or exceed the lower activity threshold, it can be determined that the accelerometer data does not contain valid step activity, and no steps are counted in the block of accelerometer data.

[0138] However, if the total activity meets or exceeds a lower activity threshold (e.g., a measure of low amplitude activity), the block of accelerometer data can be enriched 612-622. For example, the entire accelerometer data can be enriched. The lower activity threshold can allow further differentiation between true steps (e.g., walking slowly) and false steps (e.g., driving) in the accelerometer data.

[0139] Accelerometer data enhancement can be performed based on total activity and, in various examples, energy expenditure. In various examples involving two blocks of accelerometer data as shown in Figures 7A-7B, enhancement can be performed independently for blocks P1 and P2. Accelerometer data enhancement can enhance the periodicity of the accelerometer data, where true steps may have introduced additional artifacts that can be distinguished from false steps based on this enhancement.

[0140] 6, the lower total activity threshold may be adjusted based on the blocks of evaluated accelerometer data 612. The acceleration data may then be adjusted for further calculation as shown in Equation 6, thereby obtaining the average adjusted acceleration data (inpZM0) 614.

[0141]

number

[0142] The mean adjustment may be performed independently for each block of accelerometer data (eg, P1 and P2 as shown in FIGS. 7A-7B). The absolute value of the mean adjusted accelerometer data may be calculated 616.

[0143] The absolute accelerometer data can be processed by a low pass filter (LPF), i.e., the absolute value can be determined 618 by a 5-point moving average filter as a means of envelope detection as shown in Equation 7.

[0144]

number

[0145] The low-pass filtered accelerometer data may then be processed by a high-pass filter (HPF) 620. For example, a fourth order non-recursive high-pass filter may be utilized on the accelerometer data to remove drift, as shown in Equation 8.

[0146]

number

[0147] The high-pass filtered accelerometer data can be scaled 4622 and used as input for the autocorrelation calculation.

[0148] FIG. 8 illustrates an example of enhancing accelerometer data to determine whether walking or other activity is indicative of the accelerometer data. That is, raw acceleration data 802 from an accelerometer can be converted into processed accelerometer data 804 by processing the raw acceleration data 802 through an absolute value filter and a low pass filter (e.g., envelope detection). The processed accelerometer data 804 can be further converted into enhanced accelerometer data 806 by processing the accelerometer data 804, such as high pass filtering (e.g., drift removal), mean normalization, and smoothing. The steps illustrated in FIG. 8 can be performed in any order. The step counting algorithm can then extract features from the enhanced signal.

[0149] Returning to FIG. 6, as shown, the mean adjusted accelerometer data at 624 (inpZM) or the signal enhanced data from 622 (inpZM) can be converted 626 into autocorrelation data (e.g., AC, aCorr). The autocorrelation data at lag t is described in Equation 9. The number of lags t of the computed autocorrelation can be governed by the parameter ACC_AC_LIM as described in Table 2.

[0150]

number

[0151] In various examples involving two blocks of acceleration data, the autocorrelation can be calculated independently for each block (e.g., blocks P1 and P2 in Figures 7A-7B). Mean adjustment of the inputs and normalization of the outputs may imply that AC(t) represents the autocovariance at lag t, although the term autocorrelation can be used to describe this quantity.

[0152] The step counting algorithm may calculate 628 the number of level crossings (numLC) in the autocorrelated data. A level crossing is when a signal in the data crosses a level crossing threshold. Upward and downward level crossings of the autocorrelated data may be counted independently. Level crossings in the autocorrelated data may be determined according to the state machine shown in FIG. 9. The level crossings may be used to determine whether a block of acceleration data contains valid step activity 630. For example, the step counting algorithm may evaluate whether the number of level crossings meets or exceeds a level crossing threshold (numLCThresh). If the number of level crossings in the acceleration data does not meet or exceed the level crossing threshold, it may be determined that the accelerometer data does not have valid step activity and no steps are counted.

[0153] If the number of level crossings meets or exceeds the level crossing threshold, the number of level crossings (numZC) is counted 632 in the average adjusted accelerometer data at 4624 (inpZM) or the signal enhancement data (inpZM) from 4622. In various examples, in step 632, the level crossings can be zero crossings (e.g., the threshold is 0) or the number of level crossings can be different from zero crossings (e.g., the threshold is a non-zero number). A zero crossing is when the sign of the signal in the data changes (e.g., positive becomes negative or vice versa). In acceleration data deemed to contain valid step activity, the step counting algorithm can calculate the number of steps based on the total number of level crossings in the average adjusted acceleration data (inpZM). The level crossings in the accelerometer data (inpZM) can be determined according to the state machine shown in FIG. 9. Upward and downward level crossings can be counted independently as shown by the state machine in FIG. 9, and thus the total step count can be divided by two to determine the actual step count. For example, each step of a patient involves physically lifting his / her foot (creating a downward crossing) followed by lowering his / her foot to the ground (creating an upward crossing). Thus, an upward / downward crossing pair constitutes one step.

[0154] The step counting algorithm can produce output data, including output values ​​derived from the accelerometer data (e.g., physiological metrics) and the raw acceleration data itself, as an accelerometer record (ACR). The ACR can be configured as shown in Table 4 herein. The ACR can be stored in the wearable device 102 (e.g., on-board flash memory) and / or in memory 112 of the remote device.

[0155] 7A-7B, the average of the acceleration data in each of the axes (X, Y, Z) can be calculated by a step counting algorithm and the average acceleration data can be reported as an output value in floating point according to Equation 10. The average acceleration data can be used as an input to the body angle algorithm and can also be used to calculate standard deviation metrics. These metrics can be calculated only once per measurement period of accelerometer data.

[0156]

number

[0157] The standard deviation of the acceleration data in each of the axes (X, Y, Z) can be calculated by a step counting algorithm and reported as an output metric in floating point as shown in Equation 11. The standard deviation of the acceleration data can be calculated once per measurement period for both the P1 and P2 blocks of accelerometer data.

[0158]

number

[0159] Energy expenditure (EE) can be calculated by the step counting algorithm as the sum of the absolute values ​​of all negative values ​​in the entire acceleration vector according to Equation 12. EE can be calculated independently for blocks P1 and P2, resulting in two floating point values. EE can be used to determine whether a block contains valid step activity or not, and also to determine whether signal enhancement of the accelerometer data should be performed.

[0160]

number

[0161] As shown in Figures 7A-7B, the total acceleration, total activity, energy expenditure, and autocorrelation information from blocks P1 and P2 can be combined to obtain a single step count (UINT16 value) for each measurement period. The step counting algorithm may include the following steps: (i) determining whether a block qualifies as a medium-high amplitude or low amplitude activity block, (ii) performing signal enhancement on the low amplitude activity block, (iii) determining whether the block contains valid step activity, and (iv) counting the number of steps in the valid block. The step counts from blocks P1 and P2 are simply summed to determine the number of steps in a given measurement period. Independent calculations for blocks P1 and P2 allow for finer precision in tracking the user's step counts.

[0162] A block (P1 or P2) is said to have valid step activity if the following conditions are met: (i) the total activity in the block exceeds a threshold "Accelerometer Total Activity Low Threshold", and (ii) the number of level crossings of the autocorrelation exceeds a threshold "Accelerometer Num Crossing.

[0163] For blocks that satisfy the above conditions, the number of steps is calculated as the total number of level crossings for all acceleration data. The step counts from blocks P1 and P2 are summed to obtain the total number of steps in the measurement period. This number is then appropriately scaled to determine an adjusted step count (i.e., AStepCount), which is an approximate measure of steps per minute. The adjusted step count can be used as an input to algorithms implemented in the wearable device and / or remote device.

[0164] The wearable device 102 may include a scheduler (e.g., a software module external to the step counting algorithm) that starts and stops acquiring accelerometer data according to accelerometer interval and / or accelerometer period parameters, which may be programmable parameters. The accelerometer may acquire data at a fixed sampling rate (e.g., 12.5 Hz) for the length of the accelerometer period parameter set.

[0165] In various examples, the step counting algorithm may include further evaluations, such as minimum and / or maximum values, time intervals between detected steps, and amplitude variation between detected step evaluations. The step counting algorithm may use at least one of the following optional features, may process each axis separately instead of combining into a total acceleration, may use a reference vector to determine patch orientation before determining which axis / axes to use, may adjust thresholds based on more physiological data, and may combine data from two axes. The step counting algorithm may be accurate to ±3% for normal walking (80-150 steps / min) and ±10% for slow walking (15-80 steps / min) measured over at least 1000 steps. In various examples, the step counting algorithm may be accurate to ±5% for slow walking (15-80 steps / min) measured over at least 1000 steps.

[0166] 10A-10E, the step counting algorithm can provide more accurate step counts than the comparative algorithm. The dashed lines in FIG. 10A-10E represent the activity threshold. As shown in the slow walking example in FIG. 10C, the step counting algorithm enhances the data such that level crossings in the autocorrelation data caused by slow walking can result in more accurate step counts.

[0167] 10E shows step count values ​​determined by the comparison algorithm and step count algorithm from accelerometer data from normal walking, slow walking, slow shuffling, and driving.Normal walking data of 100 steps / min was sampled over 4 minutes with an expected value of 400 steps for step count;Slow walking data of 50 steps / min was sampled over 4 minutes with an expected value of 200 for step count;Slow shuffling data of 60 steps / min was sampled over 4 minutes with an expected value of 240 for step count;Medium shuffling data of 80 steps / min was sampled over 4 minutes with an expected value of 320 for step count;Driving data (e.g., 0 steps / min) was sampled over various times with an expected value of 0 for step count.

[0168] Figure 10E is a plot of step data points, each point representing one 7 second block of accelerometer data consisting of only the activities identified in Figure 10E that were analyzed by the step counting algorithm. Figure 10E shows an activity threshold 4402 and a lower activity threshold 4404. As shown, the lower activity threshold 4404 allows for the detection of slow walking.

[0169] Additionally, the thresholds of the step counting algorithm can be adjusted as shown in Figures 11A-11C. The top right corner of each plot in Figures 11A-11C shows that by adjusting the thresholds, erroneous step counts during driving can be limited, if not prevented, by the step counting algorithm.

[0170] As shown in Figure 12A, acceleration data in the form of a periodic signal is generated from walking and the data is autocorrelated to generate the autocorrelated data shown in Figure 12B. Additionally, Figures 13A-13B show autocorrelated data for other activities, such as walking, driving, and sitting, generated using a step counting algorithm.

[0171] The step counting algorithms were tested and the results reported as shown in the following tables: Tables 5-8 show step counts from wearable devices placed on the patient, with accelerometer data processed utilizing the comparison algorithm and the step counting algorithm during different activities. Additionally, the results of Comparison Pedometer 1 are shown. Table 5 shows the results for the wearable device placed on the left side of the patient, Table 6 shows the results for the wearable device placed on the inside of the patient, Table 7 shows the results for the wearable device placed on the right side of the patient, and Table 8 shows the results for the wearable device placed on the outside of the patient.

[0172] [Table 5]

[0173] [Table 6]

[0174] [Table 7]

[0175] [Table 8]

[0176] A comparison of Tables 5 and 7 indicates that the step counts reported by the wearable device on the patient's left side and the patient's right side were comparable, implying that patch placement may not have an effect on step counts and that the step counting algorithm is able to count steps reproducibly. A comparison of Tables 6 and 8 indicates that the step counts reported by the wearable device on the patient's inside and the patient's outside were comparable, implying that patch placement may not have an effect on step counts and that the step counting algorithm is able to count steps reproducibly.

[0177] Tables 9-14 show the step count values ​​output from the Comparison Algorithm, Comparison Pedometer 1, and the Step Counting Algorithm for various patients.

[0178] [Table 9]

[0179] [Table 10] *Includes walking to and from the gym as well as 2-minute spurts of various gym activities separated by breaks.

[0180] [Table 11]

[0181] [Table 12] *Includes walking to and from the gym as well as 2-minute spurts of various gym activities separated by breaks.

[0182] [Table 13]

[0183] [Table 14] *Includes walking to and from the gym as well as 2-minute spurts of various gym activities separated by breaks.

[0184] Tables 5-14 show that the step counting algorithm according to the present disclosure can have improved accuracy in step counting while minimizing erroneous step counting during driving.

[0185] The step counting algorithm may have an accuracy of ±10% or ±12 steps / min, whichever is greater, for step counts compared to manual counting of steps. The step counting algorithm may have an accuracy of ±3% of steps compared to a known step standard over an input range of 80-150 steps / min or 80-180 steps / min, measured over 1,000 or more simulated steps. In various examples, the step counting algorithm may have an accuracy equal to or greater than the JIS S72000-1993 Japanese pedometer standard, which is incorporated herein by reference.

[0186] Table 15 shows the step count values ​​as output by the comparison algorithm analyzing the acceleration data at various step rates.

[0187] [Table 15]

[0188] Table 16 shows step count values ​​output from a step counting algorithm according to the present disclosure analyzing acceleration data at various step rates.

[0189] [Table 16]

[0190] Table 17 shows step count values ​​output from a step counting algorithm according to the present disclosure analyzing acceleration data at various step rates while oriented at 45 degrees during measurement.

[0191] [Table 17]

[0192] Tables 16 and 17 contain substantially similar results, indicating that patch orientation may have a minimal effect on step counts.

[0193] Table 18 shows a summary of the various metrics from Tables 15 to 17 calculated over the ranges of 80-150 steps / min or 80-180 steps / min. The bias, absolute error, and error variance are lower for the step counting algorithm according to the present disclosure than for the comparative algorithms. Furthermore, the step counting algorithm according to the present disclosure improves the overall performance of the wearable device.

[0194] [Table 18]

[0195] The step counting algorithm according to the present disclosure generally provides a more accurate step count as measured by the number of data points having an accuracy of ±3% or less.

[0196] FIG. 14 shows plots of various patients' reported step counting rates as output by various pedometers and wearable devices including the comparative algorithm and the step counting algorithm of the present disclosure. Patients 1-12 were wearing wearable devices. As shown, most devices performed well at 100 steps / min. However, the step counting algorithm of the present disclosure on the wearable device outperformed other devices including the comparative algorithm at 50 steps / min walking while minimizing false step counts from driving.

[0197] If the accelerometer does not have an external clock (X-Tal) and there is no trim setting, then variation in the sampling rate may occur. In various examples, there may be some variation in the sampling rate across different wearable devices. Variations across different wearable devices may lead to a perceived shift in the input frequency (e.g., step rate) and therefore may be reported as different step rates. The step counting algorithm may incorporate the sampling rate into the step rate calculation.

[0198] Boundary effect

[0199] A wearable device can handle discontinuous data such as, for example, discontinuous data 1500 as shown in FIG. 15 including frames 1504 of ingestible sensor data and frames 1502 of physiological data for a patient interspersed with time gaps 1506 between the frames 1504 of ingestible sensor data. For example, the wearable device can receive ingestible sensor data 1504 contiguously with physiological data 1502. Discontinuous data can create somewhat inaccurate readings due to boundary effects caused by switching from one type of data to another (e.g., from physiological data to ingestible sensor data and / or from ingestible sensor data to physiological data), which can result in inaccurate physiological metrics (e.g., step counts, heart rate, heart rate variability, body angle).

[0200] For example, Figure 16 shows a first subframe of acceleration data on the left and a second subframe of acceleration data on the right. The first and second subframes are part of a single frame received discontinuously by the wearable device. As shown, the single frame may be a 14 second frame of accelerometer data, and each frame may be divided into smaller subframes (e.g., 7 second portions of the 14 second frame), which may improve the accuracy of the accelerometer data and facilitate serial communication of different data types.

[0201] Since subframes may be received and processed disjointly, boundary effects may occur at the beginning and end of each frame. The circles in FIG. 16 indicate level crossings that are counted by the step counting algorithm to obtain half steps. Missed level crossings at subframe boundaries may lead to missed half steps (e.g., inaccurate step counts). As shown in FIG. 16, a level crossing was missed as a result of boundary effects and non-contiguous data configurations between the end 1602 of the first subblock (e.g., near sample index 90) and the start 1604 of the second subblock (e.g., near sample index 0). In various examples, the level crossing may be a zero crossing (e.g., the threshold level is zero) or the level crossing may be a crossing that is farther than a zero crossing (e.g., the threshold is a non-zero number).

[0202] To handle boundary effects, various measures can be taken. As discussed herein, step counting can be based on counting level crossings (e.g., one level crossing is counted as a half step), and heart rate determination and heart rate variability can be based on counting peaks. An upward level crossing can be defined as going from a negative value to a positive value on the Y-axis up to or beyond an upward threshold. A downward level crossing can be defined as going from a positive value to a negative value on the Y-axis up to or beyond a downward threshold. To handle boundary effects, one measure is that if the last level crossing of the first subframe and the initial level crossing of the second subframe are of the same type (i.e., both upward or both downward), the step counting algorithm can increase the step count by a half step. Additionally, the step counting algorithm can include an extended precision value for the step count, which factors in the half step in the step rate calculation.

[0203] FIG. 17 illustrates an example of boundary effects in a frame of accelerometer data that may affect step counting when discontinuous data is received by a wearable device. As illustrated, the first and second subframes are each a 7 second portion of a 14 second data block of total acceleration data. The circles in FIG. 17 indicate level crossings where half steps are counted and obtained. Not counting partial half steps 1706 at the start of the first subframe and / or the end 1708 of the second subframe can lead to inaccurate step counts (e.g., underestimation of step counts).

[0204] To handle boundary effects, the step counting algorithm can add a half step if there is a gradient change (e.g., a change in the sign of the gradient, calculated as x[n]-x[n-1]) of the physiological data before the first level crossing or after the last level crossing in a subframe or frame. Region 1810 in FIG. 18 shows the gradient change. In response to the gradient change, the step counting algorithm can add a half step. In general, the measures for handling boundary effects can be applied to other devices that similarly handle different types of data in a continuous manner, resulting in discontinuous data being collected. Furthermore, those collected to handle boundary effects in accelerometer data can also be applied to other types of physiological data, such as ECG data.

[0205] To demonstrate the data of the step counting algorithm, a wearable device containing the step counting algorithm was used to output step counts via firmware, and acceleration data from the wearable device was also post-processed in MATLAB to determine whether steps may have been missed. The wearable device collected output values ​​derived from accelerometer data (e.g., physiological metrics) and raw acceleration data. The MATLAB model analyzed the raw acceleration data. As shown in FIG. 19, there was a perfect match between the step count values ​​output from the step counting algorithm processed by the processor of the wearable device and the MATLAB model post-processing the raw acceleration data from the wearable device on the remote device.

[0206] Additionally, FIG. 20A shows the total activity output from the step counting algorithm over time (step rate is displayed above the steps per minute data (e.g., 30, 60, 120, 150, 180, 210). The total activity threshold can be set based on the lowest step rate that should be detected and measured by the wearable device. For example, a threshold in the range of 0.03 to 0.28 can be set based on the data shown in FIG. 20A to detect a step rate of 60 steps / min and ignore step rates below 30 steps. FIG. 20B shows the raw acceleration data from the accelerometer at various step rates on the left (step rate is Shown above the data are steps per minute (e.g., 30, 60, 120, 150, 180, 210) and boxcar filtered acceleration data on the right. The sampling frequency was 12.5 Hz, the Nyquist frequency was 6.25 Hz, and the boxcar filter length was 2 with a 3 dB cutoff at 3.2 Hz. As shown at the step rate of 210 steps / min, the boxcar filter may have smeared some of the steps in the data (e.g., counting 2 steps as 1) due to the length of the filter and the frequency of the steps measured. However, a sufficient amount of signal passes through the boxcar filter to be measured at 210 steps / min.

[0207] Body angle

[0208] The wearable device 102 may include functionality for utilizing the detected physiological data to automatically determine the orientation of the wearable device relative to the patient's body. The determination may not require the patient to initialize and / or calibrate the wearable device 102. In this manner, the wearable device 102 may be installed in a variety of orientations and thus may not require precise placement of the wearable device 102 on the patient's skin in a particular position and / or orientation. For example, the wearable device 102 may be right side up, upside down, or in other orientations.

[0209] The body angle algorithm can determine the patient's body angle without input from the patient that may typically be used to initialize a comparison pedometer. The body angle algorithm can further be used to determine whether the wearer is asleep and / or lying down, as described herein. Because the patient cannot walk while lying down, the body angle algorithm can enable the wearable device 102 to reduce power consumption while the patient is asleep and / or lying down. Additionally, the body angle algorithm can enable efficient body angle determination after a power outage in the wearable device 102.

[0210] A body angle algorithm can receive the accelerometer data and can be distributed across the wearable device 102 and the remote device for execution by the control circuitry. For example, the body angle algorithm can be stored in memory 112 and utilized by processor 111 to convert accelerometer data received from accelerometer 122 into a physiological metric, such as body angle. The body angle algorithm can enable orientation determination without active calibration of the wearable device.

[0211] In various examples, the body angle algorithm can be stored and calculated on the remote device, and the accelerometer data used to calculate the body angle can be stored for a longer period of time, which can provide improved accuracy due to the increased time frame over which potentially erroneous body angle values ​​can be filtered out.

[0212] The determination of the body angle may depend on a reference vector that may be derived from the average acceleration data per dimension from the accelerometer. The reference vector may correspond to the orientation of the wearable device when the patient is upright (e.g., walking, standing), while the body angle may be the projection of the instantaneous average acceleration vector from the acceleration data onto the reference vector. As used herein, "lying down" refers to the patient's position associated with a 0 degree body angle, while "standing up" refers to the patient's position associated with a -90 degree body angle.

[0213] The reference vector can be output as a floating point unitless quantity (one number for each X, Y, Z dimension) and the body angle can be output in degrees. The reference vector can be updated once per measurement period after the number of measurement periods exceeds the ACC BA Num Records parameter. The body angle can be calculated once per measurement period and may depend on the last updated reference vector.

[0214] The reference vector calculation may use as input the qualified ACRs that include step rates within a selected range (e.g., between parameters ACC_BA Min Step Thr and ACC_BA Max Step Thr). Thus, the reference vector calculation may assume that the patient is upright because they are stepping at a step rate within the selected range. The qualified ACRs are binned based on their average acceleration data. Binning may be performed independently for each axis of accelerometer data (e.g., X, Y, Z). The selected bin for each axis with the most accurate record (which may be greater than or equal to "ACC_MIN_MODE") may then be set as the reference vector.

[0215] If the wearable device does not store and / or receive enough qualified ACRs to set the reference vector, the wearable device may use a default vector (e.g., {-1,0,0}) under the nominal assumption that the x-axis of the accelerometer is perfectly aligned with gravity when the patient is upright. In an example where the patient places the wearable device upside down on the body and not enough qualified ACRs are collected (e.g., the wearable device is placed and the patient is lying down), the wearable device may invert the reference vector (e.g., {1,0,0}). If most of the ACRs have x-axis values ​​above a threshold, e.g., above 0.8g, and are at least 3 ACRs, the wearable device may invert the reference vector. For example, the wearable device may assume that the wearable device is placed upside down.

[0216] The reference vector updates can be frozen (e.g., no further updates) once the bin count reaches a bin count threshold (e.g., ACC_MAX_MODE) on any axis. Freezing the updates can optimize memory usage so that the bin counts can be stored as 8-bit integers. Assuming the orientation of the wearable device can be fixed relatively to the user's body (except for some possible variation due to skin deformation), freezing the reference vectors may not affect the accuracy of the reference vectors.

[0217] As described herein, the body angle algorithm can calculate a reference vector that does not include the patient's position and / or can orient the wearable device to a selected position and / or orientation. In this way, the wearable device is easier for the patient to use and can automatically continue to determine the body angle in the event of a power outage.

[0218] The body angle algorithm can be configured to balance memory and reference vector precision, as desired. For example, another parameter, ACC_NUM_BINS, can be used to trade off memory requirements for precision. In this manner, examples of the present disclosure can enable reduced chip size, reduced power consumption, and / or reduced clock speed.

[0219] 21A-21D show an example of generating a reference vector by filling bins with ACR. The wearable device can be configured to perform the reference vector calculation. At power-up (e.g., initialization) of the wearable device, the reference vector bins can be emptied. The number of bins can be based on default compile-time parameters. In various examples, there can be 40 reference vector bins.

[0220] Referring to FIG. 21A, an initial state for reference vector determination is shown where the reference vector bins are empty. Default 40 reference vector bins are shown for axes X, Y, and Z. Acceleration data (e.g., ACR) with step counts greater than "ACC BA Min Step Thr" and less than "ACC BA Max Step Thr" can be considered as eligible records for reference vector calculation and can be added to the reference vector bins. Upon receiving eligible records, the Body Angle algorithm can calculate the average result of the acceleration data (e.g., packet of data). That is, the Body Angle algorithm calculates the average result of X based on MeanX, MeanY, and MeanZ in Equation 13. Bin# Bin, Y. Bin# Bin, and Z Bin# The bins can be calculated. Bin# Bin and Z Bin# Bin is X Bin# It is calculated in the same way as the bin.

[0221]

number

[0222] The body angle algorithm is based on the average results of the acceleration data. Bin# Bin, Y. Bin# Bin and / or Z Bin#The counts in the bins can be increased. Referring to FIG. 21B, an implementation of the reference vector bins is shown. As shown, the counts of the qualified acceleration data in the reference vector bins are presented. To determine the reference vector, the body angle algorithm can evaluate the reference vector bins for each axis and determine which reference vector bin for each axis contains the most counts relative to the other reference vector bins. In FIG. 21B, since there is only one qualified record in the reference vector bin for each axis, the reference vector may not yet be calculated by the body angle algorithm. The body angle algorithm may only calculate the reference vector once a threshold number of records is reached (e.g., ACC BA Num Records). Waiting for the threshold number of records can increase the accuracy of the calculated reference vector. Additional qualified records received can be added to the reference vector bins.

[0223] Referring to FIG. 21C, a second qualifying record is received and implemented in the reference vector bin. There is a tie in the reference vector bin on the Y axis. In the example where the reference vector bin has a tie, the first reference vector bin that reaches the count is selected. However, the threshold number of records (e.g., ACC BA Num Record) has not yet been reached (e.g., less than 3 qualifying records). Therefore, the reference vector bin is not selected for the reference vector calculation.

[0224] Referring to FIG. 21D, a third qualifying record is received and implemented into a reference vector bin. The threshold number of records (ACC BA Num Records) has been reached. Thus, the Body Angle algorithm can select the reference vector bin (indicated by the shaded bin) with the highest count on each axis, and the Body Angle algorithm can calculate the reference vector from the selected bin. As shown, the Body Angle algorithm selected XBin=0, YBin=0, and ZBin=1. The Body Angle algorithm can then calculate the reference vector from Equation 14. The reference vector Y and the reference vector Z can be calculated in a similar manner as the reference vector X.

[0225]

number

[0226] The reference vector may be a combination of the reference vectors for each axis. For example, the reference vector may be output as {reference vector X, reference vector Y, reference vector Z}. As additional qualifying records are received and populated into the reference vector bins, the counts in the reference vector bins may change, resulting in a new maximum value within each axis. Thus, the reference vector may be recalculated (e.g., updated) after each qualifying record is received. After a threshold amount of qualifying records are received (ACC_MAX_MODE), the reference vector may be frozen and not recalculated.

[0227] After calculating the reference vector, or based on a default reference vector, to determine the patient's body angle, the body angle algorithm can calculate a normalized projection of the average acceleration vector onto the reference vector according to Equation 15.

[0228]

number

[0229] According to Equation 15, the acceleration vector aligned with the reference vector is -90 o The acceleration vector radially offset from the reference vector can be a body angle of 0 degrees (e.g., lying down) or a body angle of 90 degrees (e.g., upside down). The body angle can be quantified by a body angle algorithm or other software (embedded in the wearable device and / or the remote device) and mapped to one of the possible states. In various examples, there can be only four possible states: upright, tilted, lying down, and upside down. In this manner, the body angle algorithm can be used by the wearable device to reduce power consumption (e.g., frequency of accelerometer measurements) for a particular state (e.g., lying down) since the patient is likely not walking in that state.

[0230] Heart rate

[0231] A patient's heart rate can be determined by measuring the electrical activity of the heart caused by myocardial depolarization and repolarization during the cardiac cycle. The electrical activity can be detected by placing electrodes on the patient's body and detecting the ECG signal (voltage vs. time). The ECG signal typically includes, among other things, a P wave, a QRS complex, and a T wave. The P wave represents the depolarization of the atria and typically occurs in 80 milliseconds (ms) or less. The QRS complex is a combination of a Q wave (downward deflection after the P wave), an R wave (upward deflection after the Q wave), and an S wave (downward curvature after the R wave) and typically corresponds to the depolarization of the right and left ventricles of the human heart and the contraction of the great ventricular muscles. The QRS complex typically occurs between 80 ms and 100 ms and has the largest amplitude in the ECG signal, typically represented by the R wave peak. The T wave follows the QRS complex and typically represents the repolarization of the ventricles, which can occur for 160 ms.

[0232] Methods for determining heart rate can focus on R-wave peak detection in ECG data and can reliably assume periodic and continuous data. For example, a patient's heart rate metric can be calculated according to Equation 16. As used herein, the term "heart rate" refers to the median heart rate unless otherwise stated. Although an average heart rate can also be calculated, the median heart rate is the typical output.

[0233]

number

[0234] The RR interval refers to the time between two adjacent R wave peaks in an ECG signal. However, discontinuous data, including frames of ingestible sensor data and physiological data, can present challenges when determining a patient's heart rate from the ECG data. That is, dealing with burst data from a wearable device and accurately determining heart rate from the ECG data can present challenges.

[0235] A heart rate algorithm can receive the ECG data and can be distributed across the wearable device 102 and the remote device for execution by the control circuitry. For example, the heart rate algorithm can be stored in memory 112 and utilized by the processor 111 to convert the ECG data into a physiological metric, such as step counts. In various examples, a vector co-processor portion of the heart rate algorithm can be stored in memory 112 of the wearable device and executed on the wearable device 102, and a processor portion of the heart rate algorithm can be stored in memory of the remote device and executed on the remote device. Processing of the ECG data on the patch can reduce data transferred to the remote device for further processing.

[0236] FIG 22A shows example data of a comparison algorithm determining heart rate from ECG data where large blocks of data are missing because the patient is asleep or at rest during some time, as shown by the patient's body angle versus time in FIG 22B (0 degrees corresponds to the patient lying down). The missing large blocks of data were filtered out using a comparison quality filter. FIG 22C shows three frames of the raw ECG signal that have been filtered out with the comparison quality. However, as shown, the heart beat is still observable in the raw ECG signal.

[0237] To obtain ECG metrics, with reference to FIG. 15, physiological data 1502 may include ECG data for ECG event periods during time gaps 1506. Ingestible sensor data 1504 may be received between ECG data (e.g., during ECG measurement intervals). An ECG data frame may be a period of ECG signal acquisition, and a subframe may be a portion of a frame. In various examples, each frame includes four subframes.

[0238] A heart rate (HR) algorithm for processing ECG data may include the parameters in Table 19.

[0239] [Table 19]

[0240] A quality metric of the ECG data can be calculated and used to filter the ECG data that can be used for the heart rate metric that can improve the accuracy of the heart rate metric calculated from the noisy ECG data. With extensively corrupted ECG data, it may not be possible to accurately identify the R wave peaks and their locations within the ECG data, which can result in an inaccurate heart rate metric. Thus, extensively corrupted ECG data can be ignored and / or discarded rather than outputting and / or displaying an incorrect heart rate to the patient.

[0241] The HR algorithm may generate outputs for each ECG data frame, such as (i) a heart rate metric in beats per minute and (ii) a flag indicating whether the heart rate metric reported in the corresponding frame is valid (e.g., the flag is set to 1 if the measurement is valid and 0 otherwise, i.e., vice versa). The HR algorithm may also generate other auxiliary metrics that may be used by the wearable device and / or the remote device.

[0242] FIG. 23 shows a flow chart for receiving and processing ECG data. That is, an ECG signal is received from electrodes of a wearable device placed on a patient. The raw ECG signal can be processed in an analog processing block 2302 and can be output as raw ECG data. The raw ECG data can be input to a processing block 2304 for processing by a HR algorithm. The HR algorithm can process the ECG data in a vector coprocessor 2306 (e.g., a vector math coprocessor, such as a dual-core DSP processor) and a processor 2308 (e.g., an ARM Cortex™ M3 processor). The vector coprocessor 2306 and the processor 2308 can be co-located on the wearable device, or one can be on the wearable device and one can be on a remote device. The vector coprocessor can be a vector math coprocessor on an ASIC, and the processor can be a high-performance reduced instruction set computing machine processor on an ASIC. The processing block 2304 can extract features from the data and can output metrics, such as heart rate and / or other metrics.

[0243] In the comparison algorithm, the processing of the ECG data would not be performed in the vector coprocessor 2306, and the raw ECG data would have been input to the processor 2308. However, the HR algorithm according to the present disclosure processes the ECG data in the vector coprocessor 2306. That is, the vector coprocessor 2306 enhances the raw ECG data received from the analog processing block 2302 and inputs the enhanced ECG data to the processor 2308, where features can be extracted from the enhanced ECG data. That is, the processing of the raw ECG data can be split across the vector coprocessor 2306 and the processor 2308. That is, the vector coprocessor 2306 can denoise the raw ECG data by converting it into enhanced ECG data with enhanced R-wave peaks that may be more easily identified and / or located when calculating heart rate metrics. For example, the enhanced ECG data may require less processing by the processor 2308 and / or a different processor to identify and locate the R-wave peaks.

[0244] The vector coprocessor 2306 can reduce the sampling rate of the ECG data as desired, or can output enhanced ECG data at the same sampling rate as the raw ECG data. For example, the vector coprocessor 2306 can receive raw ECG data sampled at a first frequency (e.g., 256 Hz) and generate enhanced ECG data at the same first frequency (e.g., 256 Hz) or a different second frequency (e.g., 64 Hz) that is less than the first frequency. Utilizing the vector coprocessor 2306 to create the enhanced ECG data can increase efficiency in downstream filtering operations, reduce the amount of data moved, and increase efficiency in memory usage in the processor 2308. Utilizing the vector coprocessor 2306 and processor 2308 can allow for more flexibility in the hardware design of the wearable device and modification of the vector coprocessor 2306 or processor 2308 with minimal, if any, impact on the unmodified counterpart.

[0245] Various programmable parameters for use with the HR algorithm according to the present disclosure are presented in Table 20.

[0246] [Table 20]

[0247] Once ECG signal acquisition begins (e.g., controlled by a programmable parameter of ECG event interval), the vector co-processor 2306 may operate on a frame of ECG data (e.g., 512 samples at 256 Hz) while maintaining the state of the filtering operation across processing frame boundaries until ECG signal acquisition is complete (e.g., controlled by a programmable parameter of ECG event duration). The state of the filtering operation may be reset at the start of every acquisition of an ECG signal. For example, the vector co-processor 2306 may receive raw ECG data and enhance the ECG data through a series of linear and / or non-linear filtering operations, such as those illustrated in FIG. 24 and described herein.

[0248] As shown in Figure 24, to enhance the raw ECG data, the raw ECG data can be processed through a high pass filter by the vector co-processor, 2402. The high pass filter can suppress low frequency noise sources such as baseline drift and motion artifacts. The high pass filter can be implemented as an FIR filter (e.g., 31 taps) with degree of response as shown in Figure 25 and parameters summarized in Table 21.

[0249] [Table 21]

[0250] Returning to FIG. 24, the high-pass filtered ECG data may be processed through a low-pass filter to suppress high frequency noise sources, such as 60 Hz power line interference 2404. The low-pass filter may be implemented as an FIR filter (e.g., 31 taps) with degree of response as shown in FIG. 26, with parameters summarized in Table 22.

[0251] [Table 22] Table 22: Low-pass filter design parameters

[0252] Returning to FIG. 24 , the low pass filtered ECG data may be processed through a downsampling filter 2306. The downsampling filter may reduce the sampling rate of the ECG data, which may reduce the processing cycles required to process the ECG data and the size of the ECG data in memory. For example, the downsampling filter may remove one out of two samples, two out of three samples, three out of four samples, or may remove another amount of samples. In various examples, the low pass filtered ECG data is not processed through a downsampling filter.

[0253] The ECG data may be processed through a derivative filter to further enhance the R-wave peaks and to sharpen (increase the slope) features in the R-wave peaks of the ECG data 2408. The derivative filter may use an FIR filter (e.g., 5 taps) to process the ECG data. The coefficients of the derivative filter may be set to a reduced version of [0.5, 0, 0, 0, -0.5]. The derivative filter may be implemented with a degree of response as shown in FIG. 27. The stopband frequencies of the preceding high pass and low pass filters are shown in dashed lines in FIG. 27 for reference.

[0254] Returning again to FIG. 24, the derivatized ECG data may be processed through a calibration filter (i.e., the absolute value of the ECG data) to make the polarity of the R-wave peaks deterministic (i.e., always positive) 2410. The calibration filter may remove ambiguity associated with the polarity of the ECG data. The calibration filter may prepare the ECG data for a subsequent boxcar averaging step. In various examples, the calibration filter may be the only nonlinear filtering operation performed by the vector co-processor.

[0255] The calibrated ECG data may be processed through a boxcar filter 2412. For example, the calibrated ECG data may be averaged using a 24-tap boxcar filter with all coefficients set to a 1 / 24 scaled version. The boxcar filter may boost, localize, and / or isolate the QRS complex and further enhance the R-wave peaks. The data output from the boxcar filter may be the enhanced ECG data, which may be sent to a processor. The boxcar filter may be implemented with a degree of response as shown in FIG. 28.

[0256] In this manner, processing the ECG signal in the vector co-processor prior to the processor can reduce the processing cycles required in the processor, the processor clock speed, and / or the memory usage in the processor. Additionally, the ECG data enrichment can include a computation engine optimized to perform highly efficient signal processing tasks. These signal processing functions can be hard-coded with logic that can be 10 times more efficient compared to software-based algorithms implemented in software running on the processor 111 or other microcontroller units. The efficiency can be reduced chip size, reduced power consumption, and / or reduced clock speed. Additionally, the heart rate algorithm can utilize an execution unit that is computationally optimized while still maintaining a level of programmability. The HR algorithm allows the wearable device to be placed on the patient indiscriminately and still obtain accurate heart rate metrics. For example, depending on the location of the wearable device on the patient's body, the ECG signal detected by the wearable device can have a similar overall structure, but the amplitude of the ECG signal can vary between locations. The difference in the amplitude of the ECG signal can be accounted for by adjusting various thresholds in the HR algorithm.

[0257] With reference to Figures 29A-29G, an example of raw ECG data processed by a vector co-processor including downsampling is presented. Figures 29A-29G visually illustrate ECG data frames (1 frame = 14 sec) collected from a patient at rest wearing a wearable device on his torso. Figure 29A shows raw ECG data and Figure 29B shows high-pass filtered ECG data after processing the raw ECG data from Figure 29A through a high-pass filter. Figure 29C shows low-pass filtered ECG data after processing the high-pass filtered ECG data from Figure 29B through a low-pass filter. Figure 29D shows downsampled ECG data after processing the low-pass filtered data from Figure 29C through a downsampling filter. Figure 29E shows derivatized ECG data after processing the downsampled ECG data from Figure 29D through a derivative filter. Figure 29F shows the calibrated ECG data after processing the differential ECG data from Figure 29E through a calibration filter. Figure 29G shows the enhanced ECG data after processing the calibrated ECG data from Figure 29F through a boxcar filter.

[0258] With reference to Figs. 30A-30F, an example of raw ECG data processed by a vector co-processor without downsampling is presented. Figs. 30A-30G visually illustrate ECG data frames (1 frame = 14 sec) collected from a patient at rest wearing a wearable device on his torso. Fig. 30A illustrates raw ECG data and Fig. 30B illustrates high-pass filtered ECG data after processing the raw ECG data from Fig. 30A through a high-pass filter. Fig. 30C illustrates low-pass filtered ECG data after processing the high-pass filtered ECG data from Fig. 30B through a low-pass filter. Fig. 30D illustrates derivatized ECG data after processing the low-pass filtered ECG data from Fig. 30C through a derivative filter. Fig. 30E illustrates calibrated ECG data after processing the derivative ECG data from Fig. 30D through a calibration filter. FIG. 30F shows the enhanced ECG data after processing the corrected ECG data from FIG. 30E through a boxcar filter.

[0259] The enhanced ECG data output of the vector coprocessor may be output at 24-bit resolution. Due to memory constraints in some processors, each ECG data frame of ECG data may be normalized to fit at 16-bit resolution, and the resulting shift factor (e.g., NR_shift) may be stored for use in downstream processing. The shift factor may be calculated based on the maximum value (Max) observed within the frame, which may also be calculated by the vector coprocessor.

[0260] With reference to FIG. 31, an example of normalization of ECG data is presented. In various examples, the vector coprocessor can process the data as a first number of bits (e.g., a 24-bit number) and the processor can process the data as a second number of bits (e.g., a 16-bit number) that is smaller than the first number of bits to save memory. To normalize the data from the vector coprocessor to the processor, the number of bits shift (e.g., a shift factor) required to align to the least significant bit (e.g., bit 23) is determined with the enhanced ECG data. As shown, the shift factor for the ECG data frame is calculated to be 5 to normalize the maximum value observed in the ECG data frame. The instruction to calculate the shift factor may be "(INT32 EcgFileRead::Normp24(UINT32 inp32)". Then, a shift (e.g., shift left) is performed based on the shift factor and stored in memory. The number of least significant bits (e.g., 16 as shown in FIG. 31) is kept and passed to the processor. Normalization may be a method of bringing together various subframes of ECG data to result in a shift between subframes.

[0261] Returning to FIG. 23 , the enhanced ECG data from the vector co-processor 2306 can be input to the processor 2308. The processor 2308 can identify and locate the R-wave peaks in the enhanced ECG data and convert the locations of the R-wave peaks into a heart rate metric. The processor 2308 can also calculate a quality metric that can be used to determine the validity of the output heart rate metric. Determining the validity of the output heart rate metric can limit, if not prevent, the wearable device from outputting an inaccurate heart rate due to extensive corruption of the input raw ECG data. The validity determination can be used downstream by the wearable device and / or a remote device to filter out and discard inaccurate output heart rate metrics.

[0262] The processor 2308 may wait until a certain amount of enhanced ECG data has been stored in the buffer for a certain period of time, as determined by a programmable parameter (e.g., ECG event duration), before starting to process the enhanced ECG data from the vector co-processor 2306. For example, with an ECG sampling rate of 256 Hz and 3584 nominal ECG event duration of 14 sec, samples of enhanced ECG data must be stored in the buffer by the processor 2308 prior to processing the enhanced ECG data. The buffer of enhanced ECG data may be divided into subframes with partial overlap. For example, as shown in FIG. 32, the buffer may be divided into four subframes with partial overlap. The four subframes may be 3.5 seconds each of enhanced ECG data. The subframes may be overlapped to avoid missing peaks due to processing of boundary effects. The last subframe in a frame may not have overlap. For example, an overlap factor such as 0.125 may be used.

[0263] FIG. 33 shows a flow chart of processing of enhanced ECG data in a processor. That is, the processor may utilize a peak finder (PF) algorithm and an adaptive thresholding (AT) algorithm to find peaks in the buffered subframes 3302. Peak finding may be based on finding pairs of rising and falling edges given a level crossing of a peak threshold. The peak threshold may be defined according to the AT algorithm described herein. The processor may utilize a peak finding (PF) algorithm as shown in FIG. 34. The PF and AT algorithms may be subcomponents of the HR algorithm.

[0264] If the number of consecutive samples is found to exceed the peak detection threshold and the local derivative is positive, a rising edge can be declared. If the number of consecutive samples is found to be below the peak detection threshold, a falling edge can be declared. If found following a rising edge (e.g., a pair of falling and rising edges), a tentative peak can be declared. The PF algorithm may only look for level crossings and not local maxima, and therefore peak refinement may be required as described herein.

[0265] 35A, a rising edge 3502 is asserted after three consecutive samples are found after the threshold 3506. A falling edge 3504 is asserted after three consecutive samples are found after the threshold 3506, and a peak is asserted based on the falling edge 3504 and rising edge pair 3502.

[0266] The processor may also utilize an AT algorithm in conjunction with the PF algorithm to identify peaks within each subframe. The AT algorithm may include dynamically adapting (e.g., changing, adjusting) the peak thresholds (e.g., lower peak threshold L, upper peak threshold U) until they converge (i.e., result in a substantially equal or equal number of identified R-wave peaks) or fail to converge because one or more termination criteria are met. The AT algorithm may be initialized with data-dependent thresholds to account for signal amplitude variation across the subframe.

[0267] For each subframe, the AT algorithm can calculate Equation 17.

[0268]

number

[0269] Since the filter operation may need to be initialized at the beginning of ECG signal acquisition, a first amount of samples (referred to as a transient region) in a first subframe may be omitted to allow the filter operation in the vector co-processor to converge. In various examples, the first amount of samples is 60. The duration of the transient region may be selected based on the total step response of all the filter operations in the vector co-processor. The AT algorithm may then initialize a peak threshold. For example, the initial peak threshold may be based on statistics of the ECG data, such as maximum, average, and / or standard deviation. The PF algorithm may calculate the number of peaks based on threshold U (nU) and the number of peaks based on threshold L (nL) while satisfying the condition of Equation 18.

[0270]

number

[0271] The thresholds can be adjusted according to Equation 19, and the PF algorithm can recalculate nU and nL as long as the condition in Equation 18 is still satisfied.

[0272]

number

[0273] The AT algorithm can declare a subframe valid if the iterations converge (i.e., nU=nL if the loop terminates), and can declare the subframe invalid if they do not (e.g., the number of iterations>maximum number of iterations).

[0274] 36A-36E, an example of dynamically adapting thresholds in ECG data using an adaptive thresholding algorithm. The thresholding algorithm can be a subcomponent of the HR algorithm. In FIG. 36A, threshold L is initialized as 20% of the maximum value in the ECG data, and threshold U is initialized as 60% of the maximum value. The maximum number of iterations is defined as 10. Then, the first iteration of the number of peaks is calculated based on the initial peak thresholds U and L. That is, in FIG. 36A, based on threshold U, there are 6 peaks, and based on threshold L, there are 8 peaks. The AT algorithm evaluates Equation 18, verifies that the condition is met, and continues to dynamically adapt the peak thresholds U and L.

[0275] The thresholds U and L are dynamically adapted by the AT algorithm based on Equation 19. Then, a second iteration of peak numbers nU and nL is calculated based on the respective adapted peak thresholds U and L. That is, in FIG. 36B, based on threshold U, there are 6 peaks, and based on threshold L, there are 8 peaks. The AT algorithm evaluates Equation 18, confirms that the condition is met, and continues to dynamically adapt the peak thresholds U and L.

[0276] The peak thresholds U and L are dynamically adapted a second time based on Equation 19. Then, a third iteration of peak numbers nU and nL is calculated based on the respective twice adapted peak thresholds U and L. That is, in FIG. 36C, based on threshold U, there are 6 peaks, and based on threshold L, there are 7 peaks. The AT algorithm evaluates Equation 18, confirms that the condition is met, and continues to dynamically adapt the peak thresholds U and L.

[0277] The peak thresholds U and L are dynamically adapted for a third time based on Equation 19. Then, a fourth iteration of peak numbers nU and nL is calculated based on the respective three adapted peak thresholds U and L. Then, i.e., in FIG. 36D, based on threshold U, there are six peaks, and based on threshold L, there are seven peaks. The AT algorithm evaluates Equation 18, confirms that the condition is met, and continues to dynamically adapt the peak thresholds U and L.

[0278] The peak thresholds U and L are dynamically adapted for the fourth time based on Equation 19. Then, a fifth iteration of peaks nU and nL is calculated based on the respective four adapted peak thresholds U and L. That is, in FIG. 36E, based on threshold U, there are six peaks, and based on threshold L, there are six peaks. The AT algorithm evaluates Equation 18 and determines that the condition is no longer met because the number of peaks based on U (nU) equals the number of peaks based on L (nL). Thus, the AT algorithm stops dynamically applying the peak thresholds U and L, and the PF algorithm defines a tentative peak based on the adapted peak thresholds. Furthermore, since the number of iterations is less than the maximum number of iterations, the subframe is declared valid.

[0279] Returning to FIG. 33, the tentative peaks found from the PF algorithm may be integrated 3304. For example, peaks found in all subframes may be matched and peaks found in the transient region of the first subframe may be discarded. In various examples, peak integration may not occur. The peaks found by the PF algorithm may include additional peaks (e.g., T-wave peaks) rather than just R-wave peaks. Thus, the tentative peaks must be adjusted to confirm and / or ensure that the peaks found correspond to R-wave peaks.

[0280] The tentative peaks identified by the PF algorithm can be adjusted 3306 based on a maximum search. For example, a peak search window can be defined based on a rising edge based on a peak threshold, and a maximum in the search window can be determined to be the location of the peak. The peak search window can begin at the location of the rising edge and extend forward (e.g., toward the paired falling edge) for a number of samples (e.g., 40). The number of samples can be defined to accommodate substantially all of the QRS complex duration of interest (e.g., up to 120 ms). The PF algorithm cannot determine the location of a peak that actually occurs after a nearby peak, which would prevent the need for a backward search.

[0281] 35B, a search window 3510 can be defined based on the rising edge 3502. An adjusted peak 3508 window position can then be determined based on a maximum search within the peak search window 3510.

[0282] Returning to FIG. 33, once the location of the peaks has been determined and the location adjusted to correspond to a local maximum, the processor may eliminate false peaks 3308. For example, peaks that are closer to each other than a distance threshold (e.g., determined by the cardiac refractory period, which may be 170 ms or greater) may be eliminated. For example, the location of the peaks may be successively scanned, and if successive peaks are found to be within 44 samples of each other, the peak having the higher amplitude may be retained and the other peak(s) may be eliminated. Additionally, peaks in the transient region may be eliminated.

[0283] The processor may reject peaks based on amplitude variation rejection 3310. For example, in the case of a high amplitude T-wave peak, the PF algorithm may identify the T-wave peak as a provisional peak that may occur as a bimodal amplitude distribution in the enhanced ECG data. To avoid concluding that a T-wave peak from a provisional peak is a valid R-wave peak, a bimodal amplitude detector may be activated by the processor. If a bimodal amplitude distribution is detected, the peak distribution may be analyzed and only peaks corresponding to R-waves may be considered for the heart rate metric.

[0284] To determine whether bimodal amplitudes are present in the enhanced ECG data, the bimodal amplitude detector adjusts the amplitudes of the interim peaks of the shift coefficients to a minimum peak amplitude A min Calculate the maximum peak amplitude A max The peak amplitude can be calculated as N b The bin range can be determined by the range of peak amplitudes (e.g., 0.8 minimum amplitude (A min )1.2 Maximum amplitude (A max )) can be determined to dynamically cover. The bimodal amplitude detector can determine the bin n1 of the largest entry and the bin n2 of the second entry. The amplitude A1 of bin n1 and the amplitude A2 of bin n2 can be calculated. The processor can then determine whether conditions (i)-(v) in Equation 20 are valid.

[0285]

number

[0286] If all of conditions (i)-(v) of Equation 20 are valid, the bimodal amplitude detector may determine that the enhanced ECG data includes a bimodal amplitude distribution. In response to determining a bimodal amplitude distribution, the processor may retain peaks corresponding to valid R waves and may remove peaks corresponding to T waves from the provisional peaks. For example, if A1 is greater than A2, the processor may retain peaks in the enhanced ECG data having amplitudes within a first range (e.g., 0.8A1-1.2A1) corresponding to bin n1 with the most entries. However, if A2 is greater than A1, the processor may retain peaks in the enhanced ECG data having amplitudes within a second range (e.g., 0.8A2-1.2A2) corresponding to bin n2 with the second most entries. The determination of condition (v) may ensure that there are sufficient peaks available for binning to create a reliable histogram. In various examples, N b =10, thresh1=0.25, thresh2=1.3, thresh3=0.8, thresh4=15.

[0287] Additionally, the bimodal amplitude detector can determine whether at least one of the following conditions is met: the number of entries in bin n2 is greater than or equal to a bin threshold; the difference between A1 and A2 is greater than or equal to a difference threshold; the number of entries in bins n1 and n2 is greater than a threshold fraction of the total number of peaks; and n1 and n2 are not adjacent bins. In various examples, the bimodal amplitude detector can determine whether all of the conditions are met.

[0288] Referring to FIG. 37A, a tentative peak is asserted at a position marked by a circle in the ECG data 3702. The tentative peak includes both an R-wave peak and a T-wave peak. The amplitude of the tentative peak in FIG. 37A is then binned into 10 bins, with the bin range covering the range of the peak amplitude. The amplitude histogram output of the binned peak amplitude is shown in FIG. 37B. The detected bimodal amplitude then determines that conditions (i)-(v) in Equation 20 are valid, and asserts that the enhanced ECG data includes a bimodal amplitude distribution. In response to asserting the bimodal amplitude assertion, peaks having amplitudes within the range of 80%-120% of the peak in bin 8 are retained, and other peaks are removed (e.g., peaks in bins 2 and 3 are removed). The remaining peaks from FIG. 37A that were not removed by the bimodal amplitude detector are marked by circles in the ECG data 3902 in FIG. 37C.

[0289] Peaks that have not been removed by peak integration in step 3304, false peak removal in step 3308, and amplitude variation peak removal in step 3310 are declared to be valid R-wave peaks. Valid R-wave peaks can be used for heart rate metrics.

[0290] Example ECG data was modeled in MATLAB. Each example included a T wave, with the amplitude of the T wave varying between examples. Heart rate (based on the RR interval) was held constant at 80 beats per minute. The examples were processed with the comparative algorithm and a bimodal amplitude detector according to the present disclosure, and heart rate metrics were calculated based on the valid R wave determination output. Table 23 shows the results of the comparative algorithm for determining heart rate based on example ECG data, and Table 24 shows the results of the HR algorithm according to the present disclosure with bimodal amplitude removal.

[0291] [Table 23]

[0292] [Table 24]

[0293] As shown, the comparison algorithm was not reliably successful above a T-wave amplitude of 0.6 mV, however the bimodal amplitude detector according to the present disclosure rejected T-waves such that accurate heart rate metrics could be calculated at T-wave amplitudes greater than 0.6 mV.

[0294] Further, referring to Figure 30G, an example of the enhanced ECG data from Figure 30F processed by a processor shows the peak thresholds as solid horizontal lines, the boundaries of each frame as dashed vertical lines, and R-wave peaks determined to be valid are marked with circles.

[0295] 33, once the interim peak is determined to be valid R-wave data, the HR algorithm may calculate the RR interval of the enhanced ECG data 3312. The RR interval may be calculated according to Equation 21.

[0296]

number

[0297] Based on the RR vector interval calculation, the HR algorithm can calculate the average and median heart rate 3314. The average heart rate can be determined from the RR interval according to Equation 22, and the median heart rate can be determined from the RR interval according to Equation 23.

[0298]

number

[0299]

number

[0300] The enhanced ECG data obtained from the discontinuous data by the wearable device may be susceptible to noise that may not be suppressed using the vector co-processor and signal processing associated with the processor. Therefore, a quality metric of the enhanced ECG data may be calculated and used to determine whether the enhanced ECG data is valid 3316. The quality metric calculation may be performed in parallel with the heart rate calculation in step 3314. The quality metric may include at least one of a peak spread, a median absolute deviation, and a quality score.

[0301] The quality metric can be used to determine (i) which R-wave peaks, if any, in the ECG data frame should be used in the heart rate calculation, and (ii) whether or not the heart rate metric value should be presented to the patient. Valid R-wave data present in a valid frame of enhanced ECG data can be used in the heart rate calculation, and the heart rate metric value can be presented to the user based on the valid frame. Invalid frames of enhanced ECG data may not be used in the heart rate calculation, while heart rate values ​​calculated from the invalid frames may not be presented to the user. The quality metric can be used to determine whether a frame of enhanced ECG data is valid based on a comparison of the quality metric to a quality threshold as described herein. The HR algorithm can ignore the frame or frames of physiological data based on the comparison. In this way, the HR algorithm can accurately determine physiological metrics, e.g., heart rate, from discrete data, and can reduce power consumption by not processing invalid frames during the calculation of the physiological metric.

[0302] The number of peak spreads (PS) is n during the i-th subframe. i Given the identified peaks, it can be calculated according to Equation 24.

[0303]

number

[0304] The median absolute deviation (MAD) can be calculated according to Equation 25, given the RR interval (RR) and the median absolute deviation metric (Median (RR)). MAD can be a measure of the variation around the median.

[0305]

number

[0306] A quality score (QS) may be calculated as the total number of subframes considered valid (e.g., a value in the range of 0 to 4 in an example including four subframes). As described herein, subframes may be considered invalid due to (i) non-convergence of adaptive thresholding and / or (ii) peak rejection due to bimodal amplitude determination.

[0307] A frame may be considered valid if the following conditions (i)-(iii) in Equation 26 hold (eg, comparison of the quality metric to a quality threshold):

[0308]

number

[0309] The ECG MAD threshold, ECG peak spread threshold and ECG quality threshold are shown in Table 19. In various examples, the MAD quality filter can be disabled by setting the programmable parameter ECG MAD threshold to zero.

[0310] As shown in Figure 38, five frames of raw ECG data 3802-3810 were provided and processed by the vector co-processor and the processor. That is, each frame of raw ECG data 3802-3810 was processed by the vector co-processor to enhance the ECG data, and the enhanced ECG data was processed by the processor to calculate the median heart rate metric and the quality metric. The ECG MAD threshold was set to 12, the ECG peak spread threshold was set to 4, and the ECG quality threshold was set to 3. The validity of each frame was determined according to Equation 26. The median heart rate metric and the quality metric are shown in Table 25.

[0311] [Table 25]

[0312] As shown, raw ECG data 3806 is invalid and may not be used in heart rate metric calculations, and heart rate metric values ​​based on raw ECG data 3806 may not be displayed to the patient. Raw ECG data 3802, 3804, 3808, and 3810 are valid and may be used in heart rate calculations, and heart rate values ​​based on raw ECG data 3802, 3804, 3808, and 3810 may be displayed to the patient.

[0313] Additionally, the HR algorithm may utilize features extracted from the raw ECG data and / or the enhanced ECG data to determine whether electrodes from the wearable device are in contact with the patient's skin or are not in contact with the patient's skin. If the HR algorithm determines that electrodes are not attached to the patient's skin, the HR algorithm may declare the ECG data invalid; otherwise, the HR algorithm may declare the ECG data valid. Further example descriptions of how ECG data may be used in this case are described in Attorney Docket No. PRTS-220PRV, which is hereby incorporated by reference.

[0314] The HR algorithm according to the present disclosure can reduce the number of processing cycles during the execution of the HR algorithm and the size of the HR algorithm (e.g., code space). Thus, the HR algorithm according to the present disclosure may require less power and memory to execute. For example, the HR algorithm according to the present disclosure can result in an 85% reduction in processing cycles during the execution of the HR algorithm (e.g., from 3.9 million to 590,000) and a 46% reduction in code space (e.g., from 4.78 kB to 2.6 kB). The reduction in processing cycles and / or memory usage can enable additional features / algorithms to operate in a memory-constrained environment. The additional features and / or algorithms can be HRV measurement, respiration measurement, and / or IEM dual decode operations. The reduction in processing cycles can reduce the power required to process the HR algorithm and can enable faster processing of the HR algorithm. In various examples, the reduction in processing cycles can enable the processor to operate at a lower clock speed, which can further reduce the power required to process the HR algorithm.

[0315] An emulation of the processor employed in the wearable device's firmware was compared to a MATLAB model of the processor, both of which analyzed the enhanced ECG data from the MATLAB model of the vector coprocessor. The MATLAB model and the emulation yielded substantially identical heart rate calculations.

[0316] An emulation of the vector coprocessor and processor employed in firmware of a wearable device that received ECG data in binary format was compared to a MATLAB model of the vector coprocessor and processor that analyzed the raw ECG data. The MATLAB model and emulation of the processor yielded substantially identical heart rate metric values.

[0317] The HR algorithm was evaluated on ECG data from the MIT-BIH arrhythmia database (available at http: / / www.physionet.org / physiobank / database / mitdb / ) using the comparison algorithm and the HR algorithm according to the present disclosure. The MIT-BIH arrhythmia database contained 48 ECG data records (47 patients) of 30 minutes each from clinical sites. The MIT-BIH arrhythmia database is commonly used to evaluate QRS detection algorithms. Separate noise traces are available to evaluate performance in noisy environments.

[0318] Raw ECG data from the MIT-BIH arrhythmia database was processed with the Waveform Database (WFDB) tool (available at http: / / physionet.org / physiotools / matlab / wfdb-app-matlab / ). The WFDB tool processed ECG data is input into the MATLAB model of the HR algorithm according to the present disclosure and evaluated for sensitivity and positive predictability based on the annotated results of ECG data processed only with the WFDB tool. Sensitivity was evaluated based on the number of true positives (TP) and the number of false negatives (FN) according to Equation 27.

[0319]

number

[0320] Positive predictability was evaluated based on the number of true positives (TP) and the number of false positives (FP) according to Equation 28.

[0321]

number

[0322] The results of evaluation of the records in the noise-free MIT-BIH arrhythmia database and the quality metrics turned off in the HR algorithm are shown in Figures 41 and 42. That is, the sensitivity results of the comparative algorithm and the HR algorithm according to the present disclosure are shown in Figure 41. The overall sensitivity mean averaged over all 48 records in the MIT-BIH arrhythmia database for the comparative algorithm was 93.6%, and for the HR algorithm according to the present disclosure it was 97.9%. The sensitivity of the HR algorithm may be limited to 98% due to the processing of ECG data within a frame.

[0323] The results of the positive predictability of the comparative algorithm and the HR algorithm according to the present disclosure are shown in Figure 42. The overall mean positive predictability averaged across all 48 records in the MIT-BIH arrhythmia database for the comparative algorithm was 90.1%, and for the HR algorithm according to the present disclosure it was 99.5%.

[0324] The results of the sensitivity average averaged over all 48 records in the MIT-BIH arrhythmia database with added noise and quality filter turned on in the HR algorithm are shown in Figures 43A-C. To add noise to the 48 records, noise traces were added separately with different scaling to vary the signal-to-noise ratio (SNR) as described at http: / / www.physionet.org / physiobank / database / nstdb / . Figure 43A shows a valid frame detected with added noise based on electrode motion, Figure 43B shows a valid frame detected with added noise based on baseline fluctuation, and Figure 43C shows a valid frame detected with added noise based on muscle artifacts.

[0325] The HR algorithm can be validated in clinical practice: the performance of the HR algorithm was validated in the field after implementation on 10 patients who wore a wearable device around their torso for 24–48 h, resulting in 13.7 days of ECG data collection. The wearable device performed ECG measurements every 19 seconds, from which the ECG data were acquired.

[0326] Patients also wore a comparative heart rate monitor (CHRM) attached to the torso with standard ECG electrodes. RR intervals were recorded on the CHRM with 1 ms resolution and ECG data was provided continuously (e.g., not discontinuously) from the CHRM. Data obtained from the CHRM was post-processed offline (14 second blocks) to calculate median heart rate. Median heart rate metric values ​​from the CHRM data were compared to median heart rate metric values ​​from the wearable device after timing synchronization (based on cross-correlation) as shown in Table 26.

[0327] [Table 26]

[0328] As shown, the HR algorithm according to the present disclosure performed well compared to CHRM ECG data, even though the HR algorithm utilizes discontinuous data.

[0329] The top diagrams of each of Figs. 44A-44E show examples of ECG data collected using the HR algorithm and CHRM of the wearable device for various patients. That is, Fig. 44A shows the results of patient 2, Fig. 44B shows the results of patient 3, Fig. 44C shows the results of patient 4, Fig. 44D shows the results of patient 8, and Fig. 44E shows the results of patient 7. As shown in Figs. 44A-44E, the heart rate metric values ​​output by the HR algorithm can be predictable and reliable during different activities. Furthermore, the bottom diagrams of each of Figs. 44A-44E show the step rate metric values ​​output from the step counting algorithm of the wearable device.

[0330] A wearable device coupled with a HR algorithm can determine heart rate metric values ​​from ECG data with an accuracy of ±10% or ±beats per minute, whichever is higher, within a heart rate range of 30 to 250 beats per minute. Accuracy is based on ANSI / AAMI EC13:2002 Cardiac Monitors,Cardiac Monitors,heart rate The wearable device may be tested for test waveforms with QRS duration of 40ms to 120ms and QRS amplitude of 0.2mV to 2mV from ANSI / AAMI EC13:2002. The wearable device may be configured to meet the line frequency voltage tolerance requirements (Section 4.2.6.2 of ANSI / AAMI EC13:2002) and drift tolerance requirements (Section 4.2.6.3 of ANSI / AAMI EC13:2002). Additionally, during accuracy testing, greater than 95% of the ECG data should be marked as valid.

[0331] FIG. 45A-D show examples of how heart rate monitoring can be performed in additional settings, such as during active periods. The HR algorithm can be accurate during rest / sleep and limited mobility, with limited missed measurements. As shown, the HR algorithm can detect heart rate while the patient is performing some activity, and the patient may not need to be completely still. For example, FIG. 45A shows heart rate versus step rate as the step rate increases. FIG. 45B shows minimal, if any, data loss while the patient is active. FIG. 45C shows the ECG while the patient is active, and FIG. 45D shows ECG data while the patient is inactive.

[0332] The raw ECG data, the enhanced ECG data, and the metrics can be stored in an ECG data record in a memory, such as, for example, the memory of the wearable device and / or the memory of a remote device. An example of ECG data is provided in Table 27.

[0333] [Table 27]

[0334] The wearable device may include a scheduler (e.g., a software module external to the algorithms described herein) that can start and stop ECG data acquisition according to ECG event interval and ECG event duration programmable parameters. Specifically, the ECG signal can be acquired periodically (e.g., at a fixed sampling rate of 256 Hz) every ECG event interval seconds for duration determination of the number of seconds of the ECG event duration.

[0335] Heart rate variability

[0336] Heart rate variability (HRV) is the variability in the time intervals between heartbeats as measured by the variation in the R-R interval. HRV has been shown to have clinical significance in both cardiac and psychiatric use cases. For example, abnormal HRV has been shown to be a predictor of mortality after myocardial infarction, depression, anxiety, bipolar disorder, and schizophrenia. HRV can also be used for stress quantification, sleep stage identification, and respiration rate estimation.

[0337] To determine the HRV metric, it may be necessary to collect a large amount of ECG data, typically over a period of several minutes. The extended amount of ECG data can be smoothed and averaged, after which the HRV metric can be determined.

[0338] The HRV algorithm can receive the ECG data and can be distributed across the wearable device 102 and the remote device for execution by the control circuitry. For example, the HRV algorithm can be stored in memory 112 and utilized by the processor 111 to convert the received ECG data into a physiological metric, such as an HRV metric. The HRV algorithm can be stored in memory on the remote device and can process the ECG data on the remote device to convert the ECG data into a physiological metric. In various examples, the HR algorithm can be implemented on the ECG data on the wearable device, and the wearable device can output the resulting data to the remote device for the HRV algorithm to determine the HRV metric from the resulting data.

[0339] The wearable device and / or the remote device can calculate HRV from the ECG data. For example, the wearable device and / or the remote device can calculate HRV when HRV mode is enabled via a programmable parameter of the ECG HRV segment. When HRV mode is enabled, the wearable device can measure an ECG signal and obtain ECG data from the wearable device as described herein.

[0340] Returning to Figure 15, while in HRV mode, the wearable device can perform an IEM (ingestible event marker) sniff operation after each ECG frame in the physiological data 1506. If no IEM activity is detected, the wearable device moves to the next ECG frame after each ECG HRV gap. If IEM activity is detected by the sniff operation, the wearable device can bail out of HRV mode and enter IEM detection mode instead.

[0341] The HRV metric may be a time domain metric, a frequency domain metric, a non-linear metric, or other type of metric. For example, the time domain metric may include the interval between normal R-peaks (mean NN interval), the standard deviation of the NN interval (SDNN), the root mean square of the difference between consecutive RR intervals (RMSSD), the percentage of consecutive NN intervals that differ by more than a threshold (e.g., 50 ms) (pNN50:P), the HRV triangle index, and the baseline width of the TT interval histogram (TINN). The frequency domain metric may include the power of the low frequency band (LF power), the power of the high frequency band (HF power), and the ratio of LF power to HF power (LF / HF ratio). The non-linear metric may include approximate entropy (ApEn), which may measure the regularity and complexity of a time series. The HRV metric may be calculated over a short time period (minutes) and / or a long time period (24 hours).

[0342] However, in a discontinuous data environment, gaps between ECG data can present challenges when calculating HRV metrics. Frame boundaries of ECG data may not begin or end at the same point in the myocardial cycle, so it can be difficult to stitch together ECG data frames to accurately calculate HRV metrics. Furthermore, in instances where HRV metrics are calculated at least in part on a wearable device, it may be desirable to create power-efficient algorithms to conserve battery (e.g., simple calculations, no complex operations such as FFTs, and using integers instead of floating point operations).

[0343] The HRV mode may include the following parameters: HRV_Event_Interval (default 30 minutes); HRV_Num_Blocks (default 9); and HRV_Block_Gap (default 4 seconds).

[0344] Every HRV_Event_Interval seconds, the wearable device may enter HRV mode, where a discontinuous ECG signal may be acquired (e.g., 14 second frames) of HRV_Num_Blocks time with ECG signal separated by HRV_Block_Gap seconds. If after every frame of ECG signal the IEM is successful, the wearable device may exit HRV mode. Upon exiting HRV mode, the ECG data from the acquired ECG signal is collected and processed to extract relevant HRV metrics. This step may be offloaded to a backend (e.g., a remote device).

[0345] Referring to FIG. 46, to determine an HRV metric, the HRV algorithm receives discontinuous data including frames of ingestible sensor data and frames of physiological data. The HRV algorithm analyzes 4602 the physiological data, including the analyzed ECG data, the RWV of any detected R-peaks in the ECG data, and impedance (IMP) data (e.g., another measurement). The ECG data can be processed by the HR algorithm according to FIG. 23. Then, returning to FIG. 46, the frames of ECG data can be grouped into blocks 4604. For example, the number of frames grouped together into a block can be set with the parameter HRV_Num_Blocks. The number of frames grouped together can be at least 2, and the default value can be 9 frames. The frames in the block can be arranged contiguously.

[0346] The HRV algorithm may then determine whether the number of frames in the block having valid heart rate metric values ​​is greater than or equal to a validity threshold 4606. The validity of each frame may be determined by the processor and according to Equation 26. In various examples, the validity threshold may be 8 (e.g., 90% of all blocks). If the number of frames in a block having valid heart rate metric values ​​is less than the validity threshold, the block may be skipped and an HRV metric may not be determined from the block. In this manner, the HRV algorithm may reduce power consumption of the wearable device by not processing invalid blocks of ECG data.

[0347] However, if the number of frames in the block with valid cardiac metric values ​​is equal to or greater than the validity threshold, the HRV algorithm may proceed to determine whether the impedance data before and / or after the block is valid 4608. If the nearest impedance data before and / or after the block is not valid, the block may be ignored and no HRV metrics may be determined from the block. For example, if the median of a moving window of consecutive impedance values ​​(e.g., 5) is greater than the impedance threshold (e.g., 10 kOhm), the block may be considered invalid and no HRV metrics may be determined from the block. Then, after one impedance measurement below the impedance threshold, the block may be used for HRV metrics. In this way, the HRV algorithm may conserve power when a high impedance is measured (e.g., electrodes come off the skin) and quickly return to calculating HRV metrics after the high impedance event ends (e.g., return to the skin).

[0348] However, if the closest impedance data before and / or after the block is valid, the HRV algorithm can process the block and reject frames in the block of ECG data that contain heart rate outliers 4610. Outlier hearts may be based on data with misidentified R-peaks, or irregularly spaced R-peaks (e.g., arrhythmia). Heart rate outliers may be determined based on median absolute deviation. The HRV algorithm may then determine whether a number of frames in the block are good (e.g., do not contain heart rate outliers) 4612. In various examples, the good threshold may be 8. If the number of good frames in a block is less than the good threshold, the block may be ignored and an HRV metric may not be determined from the block.

[0349] However, if the number of good frames in the block is greater than or equal to a good threshold, the HRV algorithm may aggregate R-wave data from all good frames in the block of ECG data 4614. The aggregated R-wave data may then be processed 4616 through a RR cleaning algorithm.

[0350] The RR cleaning algorithms may include a merge twin interval algorithm, a split tall interval algorithm, an absorb short interval algorithm, and a bimodal detection algorithm (e.g., a bimodal amplitude detector as described herein). The RR cleaning algorithms can be applied to the aggregated R-wave data on a processor on the wearable device and / or a processor on the remote device. Additionally, the RR cleaning algorithms can be applied at a frame level to reduce the number of outliers in the heart rate reports.

[0351] The merge twin interval algorithm can merge two short RR intervals sandwiched between two long RR-intervals. For example, if Equation 29 is valid, then two long RR intervals (Xn -1 , Xn +2) between two short RR sections (Xn, Xn +1 ) are integrated into one RR section (Xn+Xn +1 ) can be used.

[0352]

number

[0353] The split toll interval algorithm can split a toll RR interval between two short intervals into two intervals. For example, if Equation 30 is valid, and there are two short RR intervals (Xn -1 , Xn +1 ) can be divided into two (Xn / 2 = 2).

[0354]

number

[0355] The absorb short interval algorithm can absorb a short interval between two long RR intervals. For example, if two long RR intervals (Xn -1 , Xn +1 One short RR interval (Xn) sandwiched between Xn and Xn can be absorbed into a second longer interval (e.g., if Equation 31 is valid, remove Xn and replace Xn +1 (Xn +1 +Xn).

[0356]

number

[0357] HRV metrics can then be calculated from the cleaned R-wave data. For example, the mean RR interval and SDNN can be calculated 4618. However, to calculate the RMSSD, delta RR cleaning of the cleaned R-wave data may be required to reject outliers based on median / MAD. Additionally, the cleaned R-wave data can be interpolated with respect to spectral frequency estimates and frequency domain measurements. In various examples, the HRV metric can be a back-end step (e.g., on a remote device) that may not be performed in real time, thus conserving battery power.

[0358] Furthermore, the HRV algorithm can utilize discontinuous data, including frames of ingestible sensor data and frames of physiological data, in an efficient manner that may not require a large amount of processing power, i.e., the HRV algorithm can summarize and / or stitch together the discontinuous data and output accurate physiological metrics, such as HRV metrics.

[0359] HRV metrics were measured from eight different patients (e.g., subjects) wearing the wearable device attached to the torso and CHRM for approximately 24 hours under free living conditions. The wearable device was programmed to acquire ECG signals every 20 seconds. Accelerometer data was acquired every minute. Impedance measurements were taken every 20 minutes. IEM measurements were disabled during the study. Metric data was extracted from the CHRM using comparison software. Data from the wearable device and CHRM were post-processed in Python and compared following the data flow shown in Figure 47.

[0360] Table 28 shows Spearman correlation coefficients comparing HRV metrics from CHRM data utilizing continuous ECG data to wearable devices utilizing discontinuous ECG data from wearable devices using algorithms according to the present disclosure without subjecting the discontinuous ECG data to the RR or delta RR cleaning algorithms. The RR and / or delta RR cleaning algorithms may be subcomponents of the HRV algorithm.

[0361] [Table 28]

[0362] As shown, the average RR data shows a strong linear correlation between the discrete data and the continuous data because the Spearman correlation coefficient of the average RR is high (e.g., close to 1). Therefore, the average or median heart rate can be accurately determined from the discrete data without further HRV cleaning. However, the linear correlation of SDNN and RMSSD between the continuous data and the discrete data was poor because the Spearman correlation coefficient of SDNN and RMSSD was close to 0.

[0363] Table 29 shows the Spearman correlation coefficients comparing HRV metrics from CHRM data utilizing continuous ECG data with a wearable device utilizing discontinuous ECG data where the discontinuous ECG data was subjected to the RR cleaning algorithm only.

[0364] [Table 29]

[0365] As shown, the RR cleaning algorithm has minimal impact on the mean RR Spearman correlation coefficient. However, it significantly improves the SDNN and RMSSD correlation coefficients (e.g., closer to 1).

[0366] Table 30 shows the Spearman correlation coefficients comparing HRV metrics from CHRM data utilizing continuous ECG data with a wearable device utilizing discontinuous ECG data where the discontinuous ECG data is subjected to only the delta RR cleaning algorithm.

[0367] [Table 30]

[0368] As shown, the delta RR cleaning algorithm has minimal impact on the mean RR and Spearman correlation coefficients for SDNN, however, the Spearman correlation coefficients are significantly improved (e.g., closer to 1) for RMSSD compared to no cleaning and for some patients compared to RR cleaning alone.

[0369] Table 31 shows Spearman correlation coefficients comparing HRV metrics from CHRM data utilizing continuous ECG data with a wearable device utilizing discontinuous ECG data and subjecting the discontinuous ECG data to the RR cleaning algorithm and the delta RR cleaning algorithm.

[0370] [Table 31]

[0371] As shown, utilizing both algorithms (i.e., RR and delta RR) has minimal impact on the Spearman correlation coefficients of mean RR and SDNN compared to RR cleaning alone. However, for some patients, the Spearman correlation coefficient of RMSSD was improved (e.g., closer to 1) compared to the delta RR cleaning algorithm alone. The delta RR cleaning algorithm may have a larger impact on the RMSSD calculation than RR cleaning.

[0372] Table 32 shows Spearman correlation coefficients comparing HRV metrics from CHRM data utilizing continuous ECG data with a wearable device utilizing discontinuous ECG data subjected to the RR cleaning algorithm and the delta RR cleaning algorithm, where the data includes gaps (e.g., gaps were added to the data from the CHRM to match at the same time as data from ECG data from a wearable device according to the present disclosure).

[0373] [Table 32]

[0374] Table 33 shows the mean and median absolute error percentages when comparing the RMSSD calculated from the wearable device to the RMSSD reported by CHRM.

[0375] [Table 33]

[0376] FIG. 48 shows an example HRV metric plot for patient 5, illustrating how an algorithm according to the present disclosure utilizing discrete data matches a comparative algorithm utilizing continuous data.

[0377] rest

[0378] A processor of the wearable device and / or remote device can process the accelerometer data and ECG data to determine resting and / or resting heart rate. A resting algorithm can receive the accelerometer data and ECG data and can be distributed across the wearable device 102 and the remote device for execution by the control circuitry. For example, the resting algorithm can be stored in memory 112 and utilized by the processor 111 to convert the accelerometer data and ECG data into physiological metrics, such as resting metrics. In various examples, the resting algorithm can be stored on the remote device and used in combination with other metrics. For example, the resting algorithm can be used to clean other metric outputs, such as discarding steps detected at rest or determining resting heart rate from a heart rate metric.

[0379] Based on the acceleration data, the patient may be determined to be at rest. That is, the patient may be determined to be at rest based on the patient's body angle and total activity. For example, if the patient is lying down based on the body angle and inactive based on the total activity, the patient and associated physiological data may be classified as at rest by the resting algorithm. In this manner, the resting metric may be used to reduce the power consumption (e.g., measurement frequency) of the wearable device during resting periods and / or selectively use or ignore data obtained during resting periods.

[0380] Referring to Figure 49, the resting algorithm can receive accelerometer data. The resting algorithm can determine the patient's body angle based on the accelerometer data and a reference vector 4902. The body angle can be averaged (e.g., box car filtered) over an averaging period and average body angle data (ba_avg) can be output 4904. The averaging period can be a sliding time window, with the window length parameterized according to a programmable variable body_angle_smoothing_size_mins. The average body window data in step 4904 can be time stamped at the center time of the window length.

[0381] The average body angle data may then be added to the aggregation window 4906. The resting algorithm may then determine an aggregation period covered by the aggregation window body angle data. The resting algorithm may determine whether the aggregation period is greater than or equal to an aggregation threshold 4908. The aggregation threshold may be defined according to a programmable parameter aggregation_period_mins. If the aggregation period is less than the aggregation threshold, the resting algorithm may acquire more acceleration data.

[0382] Otherwise, if the aggregation period is greater than or equal to the aggregation threshold, the at-rest algorithm can calculate a data ratio of the actual number of data points in the aggregation window to the expected number of data points. The at-rest algorithm can compare the data ratio to a programmable data threshold (e.g., data_missing_frac) to determine whether data in the aggregation window is reliably available 4910. If the data ratio is less than the data threshold, the at-rest algorithm can acquire more acceleration data.

[0383] However, if the data ratio is equal to or greater than the data threshold, the resting algorithm can classify the average body angle data within the aggregation window based on the acceleration data. For example, the average body angle data (ba_avg) can be classified as lying down if the average body angle is greater than a first angle threshold (e.g., recumbent_angle_min, -30°) and less than a second angle threshold (e.g., recumbent_angle_max, 30°). Otherwise, the data can be classified as not lying down. The resting algorithm can then determine whether the number of average body angle data within the aggregation window classified as lying down is equal to or greater than a recumbent threshold 4912. The recumbent threshold can be a programmable parameter ("minimum_recumbent_frac"). If the number of average body angle data within the aggregation window classified as lying down is less than the recumbent threshold, it can be determined that the data within the aggregation window does not correspond to a recumbent position of the patient 4914. Otherwise, the resting algorithm can proceed to step 4926.

[0384] In addition to body angle, the resting algorithm can account for total activity in the accelerometer data. That is, the resting algorithm can calculate total activity from the accelerometer data 4916. The resting algorithm can calculate intermittent inactivity data from the total activity data 4918. That is, as shown in FIG. 50, the resting algorithm calculates 5002 a standard deviation over an SD period. The SD period can be a sliding time window, with the window length parameterized according to the programmable variable acc_std_win_size_mins. The standard deviation for each axis of the total activity data can be taken separately, and the standard deviations for each axis can be summed.

[0385] The resting algorithm can remove values ​​above an SD threshold from the summed standard deviation data 5004. The SD threshold can be parameterized according to a programmable parameter std_thresh. Removing values ​​above the SD threshold can limit the effect of accidental shifts in orientation (e.g., rotation) by the patient during resting periods that can cause spikes in the standard deviation. The removed values ​​can be replaced with the most recent measurement.

[0386] The standard deviation data may then be averaged over a summation period 5006. The summation period may be parameterized according to a programmable parameter activity_smoothing_size_mins. The standard deviation data may then be added to an aggregation window 5008.

[0387] Returning to FIG. 49, after adding the standard deviation data to the aggregation window, the at-rest algorithm can determine the aggregation period covered by the standard deviation data in the aggregation window if the aggregation period is greater than or equal to the aggregation threshold 4920. If the aggregation period is less than the aggregation threshold, the at-rest algorithm can obtain more acceleration data.

[0388] Otherwise, if the aggregation period is equal to or greater than the aggregation threshold, the at-rest algorithm can calculate a data ratio of the actual number of data points in the aggregation window to the expected number of data points. The at-rest algorithm can compare the data ratio to a programmable data threshold to determine whether data in the aggregation window can be used reliably 4922. If the data ratio is less than the data threshold, the at-rest algorithm can acquire more acceleration data.

[0389] However, if the data ratio is equal to or greater than the data threshold, the at-rest algorithm may classify the standard deviation data within the aggregation window. For example, the standard deviation data may be classified as inactive if the average body angle is equal to or less than the SD threshold (e.g., smoothed_acc_std_max, 0.065). Otherwise, the standard deviation data may be classified as active. The at-rest algorithm may then determine whether the number of standard deviation data within the aggregation window classified as inactive is equal to or greater than the inactive threshold 4924. The inactive threshold may be a programmable parameter ("minimum_inactive_frac"). If the number of standard deviation data within the aggregation window classified as inactive is less than the inactive threshold, the data within the aggregation window may be determined to be active 4914. If the number of standard deviation data within the aggregation window classified as inactive is equal to or greater than the inactive threshold, the data within the aggregation window may be determined to be inactive and the at-rest algorithm may proceed to step 4926.

[0390] After classifying the acceleration data as lying down and inactive, the acceleration data may be further classified as resting data 4926. The resting data classification may be stored in memory 4928. In this manner, the resting algorithm may utilize discrete data including ingestible sensor data and physiological data.

[0391] The resting algorithm may have programmable parameters as shown in Table 34.

[0392] [Table 34]

[0393] The wearable device can determine whether the accelerometer data should be classified as resting data at regular intervals, such as every 10 minutes. The resting data can be further defined as sleep. In various examples, the primary rest can be calculated as the largest block of data classified as resting data in a 24-hour period (e.g., between 3:00 p.m. and 3:00 p.m.). Non-adjacent resting segments can be added on either side of the primary rest if they are separated by less than a non-resting separation threshold (e.g., 30 minutes) and the gap is not larger than the new resting block being added.

[0394] The resting heart rate may be, for example, a heart rate metric calculated during a period of minimal physical activity, such as sleep. That is, the resting heart rate may be calculated (e.g., based on a time stamp) from ECG data that corresponds to accelerometer data classified as resting data. In various examples, the ECG data may be classified as resting data based on the associated accelerometer data (e.g., based on a time stamp).

[0395] The resting heart rate can be calculated from a sliding window of medians of resting heart rate metric values. The resting heart rate can be defined as the lowest local median. Other parameters that can be used to define the resting heart rate include the time to define a new period (e.g., a 24-hour period); the length of the window to average the heart rate metric values ​​over the resting period; the time (in minutes) to slide the window for the next calculation; and the minimum heart rate value to consider the window valid.

[0396] Additionally, since the heart rate and resting values ​​may not be equal, the resting values ​​may be stored in a separate queue from the heart rate metric values.

[0397] U.S. Provisional Patent Application No. 62 / 685,855, filed June 15, 2018, entitled MONITORING A SENSOR ASSEMBLY FOR A REPLACEMENT STRIP; U.S. PCT Application No. ___, Attorney Docket No. PRTS-220WO, filed concurrently therewith, entitled MONITORING A SENSOR ASSEMBLY FOR A REPLACEMENT STRIP; U.S. Provisional Patent Application No. 62 / 685,784, filed June 15, 2018, entitled RE-WEARABLE PHYSIOLOGICAL MONITORING DEVICE; and U.S. PCT Application No. ___, Attorney Docket No. PRTS-228WO, filed concurrently therewith, entitled RE-WEARABLE PHYSIOLOGICAL MONITORING DEVICE, each of which is incorporated herein by reference in its entirety.

[0398] Although several embodiments have been illustrated and described, it is not the intention of the applicant to restrict or limit the scope of the appended claims to such details. Numerous modifications, variations, changes, substitutions, combinations, and equivalents may be made to these embodiments and will occur to those skilled in the art without departing from the scope of the present disclosure. Furthermore, the structure of each element associated with the described embodiments may be described in another alternative manner as a means for providing the function performed by that element. Also, where materials are disclosed for certain components, other materials may be used. Therefore, it should be understood that the foregoing description and the appended claims are intended to cover all such numerous modifications, combinations, and variations that are within the scope of the disclosed embodiments. The appended claims are intended to cover all such modifications, variations, changes, substitutions, modifications, and equivalents.

[0399] The foregoing detailed description has described various forms of devices and / or processes through the use of block diagrams, flow charts, and / or examples. To the extent that such block diagrams, flow charts, and / or examples include functions and / or operations, those skilled in the art will appreciate that each function and / or operation within such block diagrams, flow charts, and / or examples can be implemented individually and / or collectively by a wide range of hardware, software, firmware, or substantially any combination thereof. Those skilled in the art will appreciate that some examples of the forms disclosed herein can be equivalently implemented, in whole or in part, in an integrated circuit, as a computer program executed on a computer (e.g., as a program executed on a computer system), as a program executed on a processor (e.g., as a program executed on a microprocessor), as firmware, or substantially any combination thereof, and that designing electrical circuits and / or writing software and / or firmware code is well within the skill of those skilled in the art in view of the present disclosure. In addition, those skilled in the art will appreciate that the mechanisms of the subject matter described herein can be distributed as a program product in various forms, and that the subject matter described herein applies regardless of the particular type of signaling medium used to actually effect the distribution.

[0400] The instructions used to program the logic to execute the various disclosed embodiments may be stored in memory within the system, such as dynamic random access memory (DRAM), cache, flash memory, or other storage. Additionally, the instructions may be distributed over a network or by other computer readable media. Thus, a machine readable medium may include any mechanism for storing or transmitting information in a form readable by a machine (e.g., a computer), including, but not limited to, a floppy diskette, an optical disk, a compact disk read only memory (CD-ROM), a magneto-optical disk, a read only memory (ROM), a random access memory (RAM), an erasable programmable read only memory (EPROM), an electrically erasable programmable read only memory (EEPROM), a magnetic or optical card, flash memory, or any tangible machine readable storage used in the transmission of information via the Internet via electrical, optical, acoustical, or other forms of propagated signals (e.g., carrier waves, infrared signals, digital signals, etc.). Accordingly, non-transitory computer-readable media includes any type of tangible machine-readable medium suitable for storing or transmitting electronic instructions or information in a form readable by a machine (eg, a computer).

[0401] As used herein, the term "control circuitry" may refer to, for example, hardwired circuitry, programmable circuitry (e.g., a computer processor including one or more individual instruction processing cores, processing units, processors, microcontrollers, microcontroller units, controllers, digital signal processors (DSPs), programmable logic devices (PLDs), programmable logic arrays (PLAs), or FPGAs), state machine circuitry, firmware that stores instructions that can be executed by programmable circuitry, and any combination thereof. The control circuitry may be embodied as circuitry that, together or individually, constitutes part of a larger system, such as, for example, an IC, an ASIC, an SoC, a desktop computer, a laptop, a tablet computer, a server, a smart phone, etc. Thus, as used herein, a "control circuit" includes, but is not limited to, at least one discrete electrical circuit, an electrical circuit having at least one IC, an electrical circuit having at least one application specific IC, an electrical circuit forming a general purpose computing device configured by a computer program (e.g., a general purpose computer configured by a computer program that at least partially executes the processes and / or devices described herein or a microprocessor configured by a computer program that at least partially executes the processes and / or devices described herein), an electrical circuit forming a memory device (e.g., in the form of RAM), and / or an electrical circuit forming a communication device (e.g., a modem, a communication switch, or an opto-electrical device). Those skilled in the art will appreciate that the subject matter described herein may be implemented in an analog or digital manner or some combination thereof.

[0402] As used herein, the term "logic" may refer to apps, software, firmware, and / or circuitry configured to perform any of the operations described above. Software may be embodied as a software package, code, instructions, instruction sets, and / or data recorded on a non-transitory computer-readable storage medium. Firmware may be embodied as hard-coded (e.g., non-volatile) code, instructions or instruction sets, and / or data in a memory device.

[0403] As used herein, the terms "component," "system," "module," and the like may refer to a computer-related entity, either hardware, a combination of hardware and software, software, or software in execution.

[0404] As used herein, the term "algorithm" refers to a self-consistent sequence of steps leading to a desired result, where the "steps" refer to manipulations of physical quantities and / or logical states, which may, but need not, take the form of electrical or magnetic signals capable of being stored, transferred, combined, compared, and otherwise manipulated. It is common usage to refer to these signals as bits, values, elements, symbols, characters, terms, numbers, or the like. These and similar terms may be associated with the appropriate physical quantities and are merely convenient labels applied to these quantities and / or states.

[0405] The network may include a packet-switched network. The communication devices may be capable of communicating with each other using a selected packet-switched network communication protocol. An example of a communication protocol may include an Ethernet communication protocol, which may enable communication using Transmission Control Protocol / Internet Protocol (TCP / IP). The Ethernet protocol may conform to or be compatible with the Ethernet standard published by the Institute of Electrical and Electronics Engineers (IEEE), entitled "IEEE 802.3 Standard," December 2008 edition, and / or any subsequent editions of this standard. Alternatively or additionally, the communication devices may be capable of communicating with each other using an X.25 communication protocol. The X.25 communication protocol may conform to or be compatible with standards coordinated by the International Telecommunications Union-Telecommunication Standardization Sector (ITU-T). Alternatively or additionally, the communication devices may be capable of communicating with each other using a Frame Relay communication protocol. The Frame Relay communication protocol may conform to or be compatible with standards promulgated by the Consultative Committee for International Telegraph and Telephone (CCITT) and / or the American National Standards Institute (ANSI). Alternatively or additionally, the transceivers may be capable of communicating with each other using an Asynchronous Transfer Mode (ATM) communications protocol that may conform to or be compatible with the ATM standard published by the ATM Forum, August 2001 edition entitled "ATM-MPLS Network Interworking 2.0," and / or any subsequent editions of this standard. Of course, different and / or post-deployment connection-type network communications protocols are equally contemplated herein.

[0406] As is apparent from the foregoing disclosure, unless specifically stated otherwise, discussions throughout the foregoing disclosure using the words "processing," "computing," "calculating," "determining," "displaying," and the like are understood to refer to the operations and processes of a computer system, or similar electronic computing device, that manipulates and converts data represented as physical (electronic) quantities in the computer system's registers and memory into other data that is similarly represented as physical quantities in the computer system's memory or registers, or other such information storage, transmission, or display device.

[0407] Components may be referred to herein as being "configured to," "configurable to," "operable to," "adapted to," "capable," "suitable," etc. Those skilled in the art will recognize that "configured to" may generally encompass active components, inactive components, and / or standby components, unless the context specifically requires otherwise.

[0408] Those skilled in the art will generally understand that the terms used herein, and particularly in the appended claims (e.g., the characterizing portion of the appended claims), are intended to be "open" terms (e.g., the word "including" should be interpreted as "including, but not limited to," the word "having" should be interpreted as "having at least," and the word "includes" should be interpreted as "including, but not limited to"). Those skilled in the art will further understand that where a specific number of introduced claim recitations are intended, such intention will be explicitly set forth in the claim, and in the absence of such recitation, no such intention exists. For example, to aid in understanding, the following appended claims may include the use of the preambles "at least one" and "one or more" to introduce the claim recitations. However, the use of such phrases should not be construed as meaning that the introduction of a claim recitation with the indefinite article "a" or "an" limits any particular claim that includes such an introduced claim recitation to claims that include only one of such recitations, even if the same claim includes the prepositional phrase "one or more" or "at least one" and an indefinite article such as "a" or "an" (e.g., "a" and / or "an" should typically be construed to mean "at least one" or "one or more"); the same is true for the use of definite articles used to introduce claim recitations.

[0409] In addition, even when a particular number of introduced claim recitations is explicitly recited, those skilled in the art will understand that such recitations should typically be interpreted to mean at least the recited number (e.g., a minimum recitation of "two recitations" without other modifiers typically means at least two recitations, or more than two recitations). Furthermore, in instances where a convention similar to "at least one of A, B, and C, etc." is used, such a configuration is generally intended in the sense that those skilled in the art would understand the convention (e.g., "a system having at least one of A, B, and C" includes, but is not limited to, systems having A alone, B alone, C alone, A and B together, A and C together, B and C together, and / or A, B, and C together). Those skilled in the art will further understand that, whether in the specification, claims, or drawings, phrases typically presenting adjacent words and / or more than two separate words should be understood to contemplate the possibility of including one of the multiple terms, either term, or both terms, unless the context dictates otherwise. For example, the phrase "A or B" will typically be understood to include the possibilities of "A," "B," or "A and B."

[0410] With respect to the appended claims, those skilled in the art will understand that the operations described therein may generally be performed in any order. Also, while various operational flow diagrams are presented in a sequence, it will be understood that various operations may be performed in an order different from that shown, or may be performed simultaneously. Examples of such sequences may include overlapping, alternating, interrupting, reordering, incremental, priming, capturing, simultaneous, reverse, or other variant sequences, unless the context dictates otherwise. Moreover, words such as "responsive to," "related to," or other past tense adjectives are generally not intended to exclude such variants, unless the context dictates otherwise.

[0411] Any patent application, patent, non-patent application, or other disclosure material mentioned herein is incorporated herein by reference to the extent that the incorporated material is not inconsistent with this specification. Thus, to the extent necessary, the disclosure expressly set forth herein takes precedence over any conflicting material incorporated herein by reference. Any material, or portion thereof, that is said to be incorporated herein by reference but that conflicts with existing definitions, descriptions, or other disclosure material set forth herein, is incorporated only to the extent that no conflict occurs between the incorporated material and the existing disclosure material.

[0412] In summary, many advantages have been described that derive from employing the concepts described herein. The foregoing description has been presented for purposes of illustration and description. It is not intended to be exhaustive or to be limited to the precise examples disclosed. Modifications or variations are possible in light of the above teachings. The examples have been selected and described in order to explain the principles and practical applications that will enable those skilled in the art to utilize the various examples, with various modifications suited to the particular use envisaged. The claims submitted herein are intended to define the full scope. The following items are elements that are claimed in the international application: (Item 1) 1. A system for measuring a patient's step count, comprising: a wearable device comprising an accelerometer configured to be coupled to a body of the patient and configured to utilize at least the accelerometer to detect discontinuous data, the discontinuous data including frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data; A processor of at least one of the wearable device and a remote device communicatively connected to the wearable device, the processor configured to measure the step count at a speed range of 80 to 150 steps / min using the detected physiological data with an average error of ±3% measured over at least 1000 steps; A system comprising: (Item 2) Item 1 . The system of item 1 , wherein the physiological data includes accelerometer data from the accelerometer. (Item 3) The processor, Augmenting the accelerometer data; calculating a number of level crossings of the augmented accelerometer data, thereby generating the step count; 3. The system according to item 2, further comprising: (Item 4) 4. The system of claim 3, wherein the processor is configured to augment the accelerometer data in response to a measurement of total activity in the accelerometer data being less than a first threshold and greater than or equal to a second threshold. (Item 5) The processor configured to augment the accelerometer data includes: Box Car Filter, Absolute value filter, Low pass filter, High-pass filter, and Average adjustment, 5. The system of claim 3, further comprising the processor configured to process the accelerometer data through at least one of the following: (Item 6) 6. The system of any one of claims 2 to 5, wherein the processor is further configured to process boundary effects within the frame of accelerometer data. (Item 7) The system of any one of items 1 to 6, further comprising a remote device, the remote device configured to receive discontinuous data from the wearable device. (Item 8) 8. The system of any one of items 1 to 7, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 9) 9. The system of any one of items 1 to 8, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 10) 1. A wearable device comprising a processor coupled to a non-transitory memory, the non-transitory memory, when executed by the processor, causing the processor to: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data of the patient interspersed within time gaps between the frames of ingestible sensor data; Measure step counts at speeds ranging from 80 to 150 steps / min using the detected physiological data having an average error of ±3% measured over at least 1000 steps; A wearable device that contains machine-executable instructions. (Item 11) Item 11. The wearable device of item 10, wherein the physiological data includes accelerometer data from the accelerometer. (Item 12) The machine executable instructions include: When executed by the processor, the processor further augmenting the accelerometer data; and calculating a number of level crossings of the augmented accelerometer data, thereby generating the step count; Item 12. The wearable device according to item 11. (Item 13) Item 13. The wearable device of item 12, wherein the machine executable instructions, when executed by the processor, cause the processor to augment the accelerometer data in response to a measurement where total activity in the accelerometer data is less than a first threshold and greater than or equal to a second threshold. (Item 14) The machine executable instructions, which when executed by the processor, cause the processor to augment the accelerometer data, further cause the processor to: Box Car Filter, Absolute value filter, Low pass filter, High-pass filter, and Average adjustment, 14. The wearable device of claim 12 or 13, further comprising machine-executable instructions for processing the accelerometer data through at least one of the following: (Item 15) The wearable device of any one of items 11 to 14, wherein the machine-executable instructions, when executed by the processor, cause the processor to further process boundary effects within the frame of acceleration data. (Item 16) 16. The wearable device of any one of claims 10 to 15, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 17) 17. The wearable device of any one of items 10 to 16, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 18) 1. A method for determining a patient's step count from discrete data, comprising: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data interspersed in time gaps between the frames of ingestible sensor data, the physiological data including accelerometer data from an accelerometer; augmenting the accelerometer data; and calculating a number of level crossings in the augmented accelerometer data, thereby generating the step count; A method comprising: (Item 19) Item 19. The method according to item 18, wherein calculating the step count is performed at a speed range of 80 to 150 steps / min using the detected physiological data with an average error of ±3% measured over at least 1000 steps. (Item 20) 20. The method of any one of claims 18 or 19, wherein augmenting the accelerometer data is in response to a measurement of total activity in the accelerometer data being below a first threshold and above a second threshold. (Item 21) Augmenting the accelerometer data includes: Box Car Filter, Absolute value filter, Low pass filter, High-pass filter, and Average adjustment, 21. The method of any one of items 18 to 20, comprising processing the accelerometer data through at least one of the following: (Item 22) 22. The method of any one of claims 18 to 21, further comprising processing boundary effects within the frames of acceleration data. (Item 23) 23. The method of any one of items 18 to 22, further comprising generating the ingestible sensor data by contacting an ingestible event marker with a bodily fluid of the patient. (Item 24) 24. The method of any one of items 18 to 23, further comprising removably attaching a wearable device to the patient's skin, and receiving the discontinuous data comprises receiving the discontinuous data by the wearable device. (Item 25) 1. A system for automatically determining orientation, comprising: a wearable device comprising an accelerometer configured to be coupled to a body of the patient and configured to utilize at least the accelerometer to detect discontinuous data, the discontinuous data including frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data; a processor of at least one of the wearable device and a remote device communicatively connected to the wearable device, the processor configured to utilize the detected physiological data to automatically determine an orientation of the wearable device relative to the patient's body; A system comprising: (Item 26) 26. The system of claim 25, wherein the physiological data includes accelerometer data from the accelerometer. (Item 27) 27. The system of claim 26, wherein the processor is further configured to determine the patient's orientation based on the accelerometer data. (Item 28) the processor is configured to automatically determine an orientation of the wearable device; measuring a reference vector, said measurement comprising: determining that the patient is taking steps based on the accelerometer data; binning an accelerometer record including the accelerometer data independently about at least two axes based on the acceleration data in response to the determining that the patient is taking steps; Calculating a reference vector based on the bin for each of the at least two axes having a maximum accelerometer recording; calculating the orientation of the patient's body based on the reference vector and the accelerometer data; 28. The system of any one of claims 26 or 27, further comprising the processor configured to include the processor configured to: (Item 29) 30. The system of claim 28, wherein the processor is configured to populate the bins with accelerometer recordings independently for three axes. (Item 30) Loading a new accelerometer record into said bin; 30. The system of claim 28 or 29, further comprising the processor configured to recalculate the reference vector based on the new accelerometer recording. (Item 31) 31. The system of claim 30, further comprising the processor configured to freeze further updates of the reference vector after a number of accelerometer recordings in the bin are equal to or greater than a bin count threshold. (Item 32) 32. The system according to any one of items 28 to 31, wherein the orientation of the body is a normalized convexity of a mean acceleration vector on the reference vector. (Item 33) 33. The system of any one of claims 28 to 32, wherein the accelerometer recording further comprises at least one of step count, body angle, total activity, level crossings, average acceleration, reference vector, energy expenditure, signal enhancement flags, and standard deviation of the acceleration data. (Item 34) 34. The system of any one of items 25 to 33, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 35) 35. The system of any one of claims 25 to 34, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 36) 1. A wearable device comprising a processor coupled to a non-transitory memory, the non-transitory memory, when executed by the processor, causing the processor to: receiving discontinuous data comprising frames of ingestible sensor data and frames of physiological data interspersed in time gaps between the frames of ingestible sensor data, the physiological data comprising accelerometer data; utilizing the accelerometer data to automatically determine the orientation of the wearable device relative to the patient's body; A wearable device that contains machine-executable instructions. (Item 37) Item 37. The wearable device of item 36, wherein the machine-executable instructions, when executed by the processor, cause the processor to determine the patient's orientation based on the accelerometer data. (Item 38) The machine-executable instructions, when executed by the processor, The processor, a reference vector is measured, said measurement comprising: determining that the patient is taking a step based on the accelerometer data; binning an accelerometer record including the accelerometer data independently about at least two axes based on the acceleration data in response to the determining that the patient is taking steps; calculating a reference vector based on a bin for each of said at least two axes having a maximum accelerometer recording; Including, Item 38. A wearable device according to item 36 or 37, adapted to calculate the orientation of the patient's body based on the reference vector and the accelerometer data. (Item 39) Item 39. The wearable device of item 38, wherein the machine executable instructions, when executed by the processor, cause the processor to capture accelerometer recordings into the bins independently for three axes. (Item 40) The machine-executable instructions, when executed by the processor, cause the processor to Loading new accelerometer records into said bins; recalculating the reference vector based on the new accelerometer recording. Item 39. A wearable device according to item 38 or 39. (Item 41) Item 41. The wearable device of item 40, wherein the machine executable instructions, when executed by the processor, cause the processor to freeze further updates of the reference vector after some accelerometer recordings in the bin are equal to or greater than a bin count threshold. (Item 42) 42. The wearable device according to any one of items 38 to 41, wherein the orientation of the body is a normalized convexity of a mean acceleration vector on the reference vector. (Item 43) 43. The wearable device of any one of items 38 to 42, wherein the accelerometer recording further includes at least one of step count, body angle, total activity, level crossing, average acceleration, reference vector, energy expenditure, signal enhancement flag, and standard deviation of the acceleration data. (Item 44) 44. The wearable device of any one of claims 36 to 43, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 45) 1. A method for automatically determining orientation, comprising: receiving discontinuous data comprising frames of ingestible sensor data and frames of physiological data interspersed in time gaps between the frames of ingestible sensor data, the physiological data comprising accelerometer data from a wearable device; automatically determining an orientation of the wearable device relative to a patient's body using the accelerometer data; A method comprising: (Item 46) 46. ​​The method of claim 45, further comprising determining the patient's orientation based on the accelerometer data. (Item 47) measuring a reference vector, said measurement comprising: determining that the patient is taking a step based on the accelerometer data; binning an accelerometer record including the accelerometer data independently about at least two axes based on the acceleration data in response to the determining that the patient is taking steps; calculating the reference vector based on a bin for each of the at least two axes having a maximum accelerometer recording; measuring the calculating the orientation of the patient's body based on the reference vector and the accelerometer data; 47. The method according to claim 45 or 46, further comprising: (Item 48) Item 48. The method of item 47, further comprising binning accelerometer recordings independently for three axes. (Item 49) populating said bin with new accelerometer records; recalculating the reference vector based on the new accelerometer recording; and 49. The method according to item 47 or 48, further comprising: (Item 50) 51. The method of claim 49, further comprising freezing further updates of the reference vector after a number of accelerometer recordings in the bin are equal to or greater than a bin count threshold. 51. The method according to any one of items 47 to 50, wherein the orientation of the body is a normalized convexity of a mean acceleration vector on the reference vector. (Item 52) 52. The method of any one of items 47 to 51, wherein the accelerometer recording further comprises at least one of step count, body angle, total activity, level crossing, average acceleration, reference vector, energy expenditure, signal enhancement flag, and standard deviation of the acceleration data. (Item 53) 53. The method of any one of items 45 to 52, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 54) 54. The method of any one of items 45 to 53, further comprising removably attaching a wearable device to the patient's skin, and receiving the discontinuous data comprises receiving the discontinuous data by the wearable device. (Item 55) 1. A system for measuring a heart rate of a patient, comprising: a wearable device comprising electrodes configured to be coupled to a body of the patient and configured to detect discontinuous data utilizing at least the electrodes, the discontinuous data including frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data; At least one vector co-processor of the wearable device and a remote device communicatively connected to the wearable device, the vector co-processor configured to augment the frame of physiological data; and at least one processor of the wearable device and the remote device configured to measure a heart rate of the patient using the augmented frames of physiological data; A system comprising: (Item 56) The vector co-processor configured to augment the frames of physiological data comprises: High pass filter, Low pass filter, Downsampling filters, Dielectric filters, Calibration filter, and Boxcar averaging filter, Item 56. The system of item 55, comprising the vector co-processor configured to process the physiological data through at least one of: (Item 57) The processor configured to process the physiological data includes: Peak Finder, Adaptive threshold, Peak purification, Spurious peak rejection, and Amplitude fluctuation elimination, 57. The system of claim 55 or 56, configured to measure heart rate with at least one technique selected from the group consisting of: (Item 58) Item 58. The system of item 57, wherein the processor is configured to process the physiological data using the peak finder, the processor comprising: the processor configured to detect rising edges and falling edges based on the physiological data crossing a first threshold. (Item 59) The processor, Detecting a first number of peaks in the physiological data based on the first threshold; detecting a second number of peaks in the physiological data based on a second threshold different from the first threshold; Item 59. The system of item 58, configured to process the physiological data with the adaptive thresholds, comprising the processor configured to adjust the first and second thresholds until the first number of peaks is equal to the second number of peaks or until a threshold number of adjustment iterations is reached or exceeded. (Item 60) 61. The system of claim 57, wherein the processor is configured to process the physiological data with spurious peaks removal, the spurious peaks removal including removing peaks of the physiological data that are closer together than a distance threshold. 61. The system of any one of claims 57 to 60, wherein the processor is configured to process the physiological data with the amplitude variation removal, comprising calculating an interval between peaks in the physiological data and merging two peaks in a frame of the physiological data into one peak or splitting a peak into two peaks in the physiological data based on the calculated interval. (Item 62) 62. The system of any one of items 57 to 61, wherein the processor is configured to ignore frames of physiological data that include invalid data while measuring the heart rate. (Item 63) The processor further comprises: Item 63. The system of item 62, configured to measure at least one quality metric selected from the group consisting of peak spread, median absolute deviation, and quality score for each frame of physiological data, and wherein the processor is configured to ignore the frame of physiological data based on a comparison of the at least one quality metric to a quality threshold. (Item 64) 64. The system of any one of claims 55 to 63, wherein the vector coprocessor is a vector operation coprocessor on an application specific integrated circuit (ASIC). (Item 65) 65. The system of claim 55, wherein the processor is an advanced reduced instruction set computer processor on the ASIC. (Item 66) 65. The system of any one of claims 55 to 64, wherein the wearable device includes an electrocardiogram (ECG) circuit operably coupled to the electrodes. (Item 67) Item 67. The system of item 66, wherein the physiological data includes ECG data from the ECG circuit. (Item 68) Item 68. The system of any one of items 55 to 67, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 69) 69. The system of any one of claims 55 to 68, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 70) 1. A wearable device comprising a processor coupled to a non-transitory memory, the non-transitory memory, when executed by the processor and / or a vector co-processor, providing to the processor and / or co-processor: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data; augmenting said frame of physiological data by said co-processor; causing the processor to use the augmented frames of physiological data to measure a heart rate of the patient. A wearable device that contains machine-executable instructions. (Item 71) The machine executable instructions, when executed by the vector coprocessor, cause the vector coprocessor to: High pass filter, Low pass filter, Downsampling filters, Dielectric filters, Calibration filter, and Boxcar averaging filter, 71. The wearable device of item 70, wherein the physiological data is processed through at least one of the following: (Item 72) The machine-executable instructions, when executed by the processor, cause the processor to: Peak Finder, Adaptive threshold, Peak purification, Spurious peak rejection, and Amplitude fluctuation elimination, 72. The wearable device of item 70 or 71, wherein the physiological data is processed by at least one technique selected from the group consisting of: (Item 73) Item 73. The wearable device of item 72, wherein the machine-executable instructions, when executed by the processor, cause the processor to process the physiological data using the peak finder to detect rising edges and falling edges based on the physiological data crossing a first threshold. (Item 74) The machine-executable instructions, when executed by the processor, cause the processor to: detecting a first number of peaks in the physiological data based on the first threshold; detecting a second number of peaks in the physiological data based on a second threshold different from the first threshold; adjusting the first and second thresholds until the first number of peaks is equal to the second number of peaks or until a threshold number of adjustment iterations is reached or exceeded. Item 72 or 73. A wearable device according to item 72 or 73. (Item 75) 75. The wearable device of any one of items 72 to 74, wherein the machine-executable instructions, when executed by the processor, cause the processor to process the physiological data with spurious peak removal, including the processor configured to remove peaks of the physiological data that are closer to each other than a distance threshold. (Item 76) 76. The wearable device of any one of items 72 to 75, wherein the machine-executable instructions, when executed by the processor, cause the processor to process the physiological data with the amplitude variation removal to calculate an interval between peaks in the physiological data, and based on the calculated interval, merge two peaks into one peak in the frame of physiological data, or split a peak into two peaks in the physiological data. (Item 77) A wearable device as described in any one of items 72 to 75, wherein the machine-executable instructions, when executed by the processor, cause the processor to ignore frames of physiological data that include invalid data while measuring the heart rate. (Item 78) The machine executable instructions, when executed by the processor, cause the processor to measure at least one quality metric selected from the group consisting of a peak spread, a median absolute deviation, and a quality score for each frame of physiological data, and the processor is configured to ignore the frame of physiological data based on a comparison of the at least one quality metric to a quality threshold. Item 77: Wearable devices. (Item 79) 79. The wearable device of any one of claims 70 to 78, wherein the physiological data includes electrocardiogram (ECG) data from an ECG circuit. (Item 80) The wearable device of any one of items 70 to 79, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 81) 81. The wearable device of any one of items 70 to 80, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 82) 1. A method for measuring heart rate, comprising: receiving discontinuous data utilizing at least the electrodes, the discontinuous data including frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data; augmenting said frame of physiological data by a co-processor; and determining, by a processor, a heart rate of the patient using the augmented frames of the physiological data. (Item 83) Augmenting the frame of physiological data comprises: High pass filter, Low pass filter, Downsampling filters, Dielectric filters, Calibration filter, and Boxcar averaging filter, 83. The method of claim 82, further comprising processing the physiological data through at least one of: (Item 84) Measuring the heart rate of the patient includes: Peak Finder, Adaptive threshold, Peak purification, Spurious peak rejection, and Amplitude fluctuation elimination, 84. The method according to claim 82 or 83, comprising processing the physiological data with at least one technique selected from the group consisting of: (Item 85) 85. The method of claim 84, wherein measuring the heart rate includes processing the physiological data via the peak finder to detect rising and falling edges based on the physiological data that cross a first threshold. (Item 86) detecting a first number of peaks in the physiological data based on the first threshold; detecting a second number of peaks in the physiological data based on a second threshold different from the first threshold; adjusting the first and second thresholds until the first number of peaks is equal to the second number of peaks or until a threshold number of adjustment iterations is reached or exceeded. Item 86. The method of item 85, further comprising: (Item 87) 87. The method of claim 85 or 86, wherein measuring the heart rate includes processing the physiological data through spurious peak removal, including removing peaks in the physiological data that are closer to each other than a distance threshold. (Item 88) 88. The method of any one of items 85 to 87, wherein measuring the heart rate comprises processing the physiological data with the amplitude variation removal, comprising calculating an interval between peaks in the physiological data and merging two peaks into one peak in the frame of physiological data or splitting a peak into two peaks in the physiological data based on the calculated interval. (Item 89) 89. The method of any one of items 82 to 88, further comprising ignoring frames of physiological data that include invalid data while measuring the heart rate. (Item 90) Measuring at least one quality metric selected from the group consisting of peak broadening, median absolute deviation, and a quality score for each frame of physiological data; 90. The method of claim 89, further comprising comparing the quality metric to a quality threshold, wherein discarding the frame of physiological data is based on the comparison. (Item 91) 91. The method of any one of items 82 to 90, wherein the physiological data includes electrocardiogram (ECG) data from an ECG circuit. (Item 92) 92. The method of any one of claims 82 to 91, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 93) 93. The method of any one of items 82 to 92, further comprising removably attaching a wearable device to the patient's skin, and receiving the discontinuous data comprises receiving the discontinuous data by the wearable device. (Item 94) 1. A system for measuring level crossings in discrete data, comprising: a wearable device configured to be coupled to a patient's body and configured to detect discontinuous data, the discontinuous data including frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data; a processor of at least one of the wearable device and a remote device communicatively connected to the wearable device, the processor configured to process boundary effects in the frames of physiological data and calculate a number of level crossings; A system comprising: (Item 95) 95. The system of claim 94, wherein the physiological data includes at least one of accelerometer data from an accelerometer and electrocardiogram (ECG) data from an ECG circuit. (Item 96) Item 96. The system of item 94 or 95, wherein the processor is configured to measure a direction of each level crossing. (Item 97) 97. The system of any one of items 94 to 96, wherein the processor is configured to increase the number of level crossings in response to determining that a level crossing at an end of a first frame of physiological data is in the same direction as a level crossing at a beginning of a second frame of physiological data, the first and second frames being sequentially positioned within the physiological data. (Item 98) 98. The system of any one of claims 94 to 97, wherein the processor is configured to detect a change in slope of the frames of physiological data and increase the number of level crossings in response to the change in slope. (Item 99) Item 99. The system of item 98, wherein the change in slope is prior to a level crossing at the beginning of a frame of physiological data. (Item 100) 100. The system of claim 98 or 99, wherein the change in slope is after a level crossing at the end of a frame of physiological data. (Item 101) The system of any one of items 94 to 100, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 102) 102. The system of any one of claims 94 to 101, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 103) 1. A wearable device comprising a processor coupled to a non-transitory memory, the non-transitory memory, when executed by the processor, causing the processor to: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data; processing boundary effects in the frames of physiological data to determine a number of level crossings in the physiological data; A wearable device that contains machine-executable instructions. (Item 104) Item 104. The wearable device of item 103, wherein the physiological data includes at least one of accelerometer data from an accelerometer and electrocardiogram (ECG) data from an ECG circuit. (Item 105) Item 105. A wearable device according to item 103 or 104, wherein the machine-executable instructions, when executed by the processor, cause the processor to measure a direction of each level crossing. (Item 106) A wearable device as described in any one of items 103 to 105, wherein the machine-executable instructions, when executed by the processor, cause the processor to increase a number of level crossings in response to determining that a level crossing at an end of a first frame of physiological data is in the same direction as a level crossing at a beginning of a second frame of physiological data, such that the first and second frames are arranged sequentially within the physiological data. (Item 107) A wearable device described in any one of items 103 to 106, wherein the machine-executable instructions, when executed by the processor, cause the processor to detect a change in slope of the frames of physiological data and increase the number of level crossings in response to the change in slope. (Item 108) Item 108. The wearable device of item 107, wherein the change in slope is prior to a level crossing at the beginning of a frame of physiological data. (Item 109) Item 109. A wearable device as described in item 107 or 108, wherein the change in slope is after a level crossing at the end of a frame of physiological data. (Item 110) 109. A wearable device according to any one of claims 103 to 109, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 111) 1. A method for measuring the number of level crossings in discrete data, comprising: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data; processing boundary effects in said frames of physiological data and calculating a number of level crossings in said discrete data; A method comprising: (Item 112) Item 112. The method of item 111, wherein the physiological data includes at least one of accelerometer data from an accelerometer and electrocardiogram (ECG) data from an ECG circuit. (Item 113) 13. The method of claim 111 or 112, further comprising determining a direction of each level crossing. (Item 114) 114. The method of any one of items 111 to 113, further comprising increasing a number of level crossings in response to determining that a level crossing at an end of a first frame of physiological data is in the same direction as a level crossing at a beginning of a second frame of physiological data, the first and second frames being sequentially positioned within the physiological data. (Item 115) 115. The method of any one of claims 111 to 114, further comprising detecting a change in slope of the frames of physiological data and increasing the number of level crossings in response to the change in slope. (Item 116) 116. The method of any one of claims 111 to 115, wherein the change in slope is prior to a level crossing at the beginning of a frame of physiological data. (Item 117) 117. The method of any one of items 111 to 116, wherein the change in slope is after a level crossing at the end of a frame of physiological data. (Item 118) 118. The method of any one of claims 111 to 117, wherein the ingestible sensor data is generated by an ingestible event marker after contact with a bodily fluid of the patient. (Item 119) The method of any one of items 111 to 118, further comprising removably attaching a wearable device to the patient's skin, and receiving the discontinuous data comprises receiving the discontinuous data by the wearable device. (Item 120) 1. A system for measuring heart rate variability in a patient, comprising: a wearable device configured to be coupled to a body of the patient, the wearable device comprising electrodes, and configured to detect discrete data utilizing at least the electrodes, the discrete data including frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data; a processor of at least one of the wearable device and a remote device communicatively connected to the wearable device, the processor being configured to group at least two of the frames of physiological data together into blocks and measure the patient's heart rate variability using the blocks; A system comprising: (Item 121) Item 121. The system of item 120, further comprising the processor measuring validity of heart rate data in each frame of physiological data in the block. (Item 122) Item 122. The system of item 121, further comprising the processor configured to determine that the number of frames containing valid heart rate data in the block is greater than or equal to a threshold. (Item 123) Item 123. The system of item 122, further comprising the processor configured to determine that the number of frames containing valid heart rate data in a second block is less than the threshold, and to ignore the second block while calculating the heart rate variability for the patient. (Item 124) The system of any one of items 121 to 123, further comprising the processor configured to aggregate the frames determined to contain valid heart rate data, the processor configured to measure the heart rate variability based on the aggregated frames. (Item 125) The system of any one of items 120 to 124, further comprising the processor configured to determine that an impedance measurement value placed proximal to the block is below an impedance threshold value. (Item 126) Item 126. The system of item 125, further comprising the processor configured to determine that a second impedance measurement placed proximal to a second block is greater than the impedance threshold, and to ignore the second block while measuring the heart rate variability of the patient. (Item 127) The system of any one of items 120 to 126, further comprising the processor configured to process the blocks to remove frames containing outlier heart rates from the heart rate variability measurement. (Item 128) Item 128. The system of any one of items 120 to 127, further comprising the processor configured to process the blocks through a cleaning algorithm selected from a merge twin interval algorithm, a split tall interval algorithm, an absorb short interval algorithm, and a bimodal detection algorithm. (Item 129) The system of any one of items 120 to 128, wherein the wearable device includes an electrocardiogram (ECG) circuit operably coupled to the electrodes. (Item 130) Item 130. The system of item 129, wherein the physiological data includes ECG data from the ECG circuit. (Item 131) The system of any one of items 120 to 130, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 132) 1. A wearable device comprising a processor coupled to a non-transitory memory, the non-transitory memory, when executed by the processor, causing the processor to: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data; and grouping at least two of the frames of the physiological data together into blocks and measuring heart rate variability of the patient using the blocks. (Item 133) Item 133. The wearable device of item 132, wherein the machine-executable instructions, when executed by the processor, cause the processor to measure the validity of heart rate data in each frame of physiological data in the block. (Item 134) Item 134. The wearable device of item 133, wherein the machine-executable instructions, when executed by the processor, cause the processor to determine that the number of frames in the block containing valid heart rate data is greater than or equal to a threshold. (Item 35) Item 135. The wearable device of item 134, wherein the machine-executable instructions, when executed by the processor, cause the processor to determine that the number of frames containing valid heart rate data in a second block is less than the threshold and to ignore the second block while calculating the heart rate variability of the patient. (Item 136) A wearable device described in any one of items 133 to 135, wherein the machine-executable instructions, when executed by the processor, cause the processor to aggregate the frames determined to contain valid heart rate data and measure the heart rate variability based on the aggregated frames. (Item 137) A wearable device described in any one of items 132 to 135, wherein the machine-executable instructions, when executed by the processor, cause the processor to determine that an impedance measurement value placed proximal to the block is below an impedance threshold value. (Item 138) Item 138. The wearable device of item 137, wherein the machine-executable instructions, when executed by the processor, cause the processor to determine that a second impedance measurement placed proximal to a second block is greater than the impedance threshold and to ignore the second block while measuring the heart rate variability of the patient. (Item 139) A wearable device described in any one of items 132 to 138, wherein the machine-executable instructions, when executed by the processor, cause the processor to process the block to remove frames containing outlier heart rates from the heart rate variability measurement. (Item 140) A wearable device described in any one of items 132 to 139, wherein the machine-executable instructions, when executed by the processor, cause the processor to process the blocks through a cleaning algorithm selected from a merge twin interval algorithm, a split tall interval algorithm, an absorb short interval algorithm, and a bimodal detection algorithm. (Item 141) The wearable device of any one of items 132 to 140, wherein the wearable device includes an electrocardiogram (ECG) circuit operably connected to the electrodes. (Item 142) Item 142. The wearable device of item 141, wherein the physiological data includes ECG data from the ECG circuit. (Item 143) The wearable device of any one of items 132 to 147, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 144) 1. A method for measuring heart rate variability in a patient, comprising: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data; grouping at least two of the frames of physiological data together into blocks and measuring heart rate variability of the patient utilizing the blocks; and (Item 145) Item 145. The method of item 144, further comprising measuring the validity of the heart rate data in each frame of physiological data in the block. (Item 146) Item 146. The method of item 145, further comprising determining that the number of frames containing valid heart rate data in the block is greater than or equal to a threshold. (Item 147) Item 147. The method of item 146, further comprising determining that a number of frames containing valid heart rate data in a second block is less than the threshold, and ignoring the second block while calculating the heart rate variability for the patient. (Item 148) Item 148. The method of item 146 or 147, further comprising aggregating the frames determined to contain valid heart rate data and measuring the heart rate variability based on the aggregated frames. (Item 149) 149. The method of any one of items 144 to 148, further comprising determining that an impedance measurement placed proximal to the block is below an impedance threshold. (Item 150) Item 149. The method of item 149, further comprising determining that a second impedance measurement placed proximal to a second block is greater than the impedance threshold and ignoring the second block while measuring the heart rate variability of the patient. (Item 151) Item 151. The method of any one of items 144 to 150, further comprising processing the blocks to remove frames containing outlier heart rates from the heart rate variability measurements. (Item 152) 152. The method of any one of items 144 to 151, further comprising processing the block through a cleaning algorithm selected from a merge twin interval algorithm, a split tall interval algorithm, an absorb short interval algorithm, and a bimodal detection algorithm. (Item 153) 153. The method of any one of claims 144 to 152, wherein the physiological data includes ECG data from an ECG circuit. (Item 154) The method of any one of items 144 to 153, further comprising removably attaching a wearable device to the patient's skin, and receiving the discontinuous data comprises receiving the discontinuous data by the wearable device. (Item 155) 1. A system for measuring patient serenity, comprising: a wearable device comprising an accelerometer configured to be coupled to a body of the patient and configured to detect discontinuous data utilizing at least the accelerometer and the electrodes, the discontinuous data including frames of ingestible sensor data and frames of physiological data of the patient interspersed in time gaps between the frames of ingestible sensor data, the physiological data including accelerometer data from the accelerometer; a processor of at least one of the wearable device and a remote device communicatively connected to the wearable device, the processor configured to determine that the patient is at rest based on accelerometer data; and A system comprising: (Item 156) Item 156. The system of item 155, further comprising the processor configured to measure body angle data of the patient and total activity data from the accelerometer data, and determine that the patient is at rest based on the body angle data and total activity data. (Item 157) Item 157. The system of item 156, further comprising the processor configured to add body angle data to a body angle aggregation window until a threshold time period is covered by body angle data and measure aggregate body angle data based on the body angle aggregation window, wherein determining that the patient is at rest is based on the aggregate body angle data. (Item 158) Item 158. The system of item 156 or 157, further comprising the processor configured to add total activity data to a total activity aggregation window until a threshold period is covered by the total activity data and measure aggregated total activity data based on the total activity aggregation window, wherein the patient is determined to be at rest based on the aggregated total activity data. (Item 159) 159. The system of any one of items 156 to 158, further comprising the processor configured to remove values ​​of the total activity data that are equal to or greater than a threshold value. (Item 160) Item 159. The system of any one of items 156 to 159, further comprising the processor configured to determine that the body angle data within the body angle aggregation window is valid. (Item 161) Item 161. The system of any one of items 156 to 160, further comprising the processor configured to ignore second body angle data within the body angle aggregation window that is not valid. (Item 162) 162. The system of any one of items 156 to 161, further comprising the processor configured to determine that total activity data within the total activity aggregation window is valid. (Item 163) 163. The system of any one of items 156 to 162, further comprising the processor configured to ignore second total activity data within the total activity aggregation window that is not valid. (Item 164) Item 164. The system of any one of items 155 to 163, further comprising the processor configured to classify the physiological data as resting data or as non-resting data based on the determination that the patient is at rest. (Item 165) Item 165. The system of item 164, wherein the physiological data further includes electrocardiogram (ECG) data, and the processor is configured to measure a resting heart rate from the ECG data from the physiological data while the patient is determined to be at rest. (Item 166) Item 166. The system of item 165, wherein the processor is configured to measure the resting heart rate from the largest segment of physiological data within a 24-hour period classified as resting data. (Item 167) The system of any one of items 155 to 166, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 168) 1. A wearable device comprising a processor coupled to a non-transitory memory, the non-transitory memory, when executed by the processor, causing the processor to: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data; determining that the patient is at rest based on the accelerometer data; A wearable device that contains machine-executable instructions. (Item 169) The wearable device of item 168, wherein the machine-executable instructions, when executed by the processor, cause the processor to measure body angle data and total activity data of the patient from the accelerometer data and determine that the patient is at rest based on the body angle data and total activity data. (Item 170) Item 170. The wearable device of item 169, wherein the machine-executable instructions, when executed by the processor, cause the processor to add body angle data to a body angle aggregation window until a threshold period is covered by the body angle data, measure aggregate body angle data based on the body angle aggregation window, and determine that the patient is at rest based on the aggregate body angle data. (Item 171) The wearable device of item 169 or 170, wherein the machine-executable instructions, when executed by the processor, cause the processor to add total activity data to a total activity aggregation window until a threshold period is covered by the total activity data, measure aggregated total activity data based on the total activity aggregation window, and the patient is determined to be at rest based on the aggregated total activity data. (Item 172) A wearable device described in any one of items 169 to 171, wherein the machine-executable instructions, when executed by the processor, cause the processor to remove values ​​of the total activity data that are equal to or greater than a threshold value. (Item 173) A wearable device described in any one of items 169 to 172, wherein the machine-executable instructions, when executed by the processor, cause the processor to determine that body angle data within the body angle aggregation window is valid. (Item 174) A wearable device described in any one of items 169 to 173, wherein the machine-executable instructions, when executed by the processor, cause the processor to ignore second body angle data within the body angle aggregation window that is invalid. (Item 175) A wearable device described in any one of items 169 to 174, wherein the machine-executable instructions, when executed by the processor, cause the processor to determine that total activity data within the total activity aggregation window is valid. (Item 176) A wearable device described in any one of items 169 to 175, wherein the machine-executable instructions, when executed by the processor, cause the processor to ignore second total activity data within the total activity aggregation window that is not valid. (Item 177) The wearable device of any one of items 169 to 176, wherein the machine-executable instructions, when executed by the processor, cause the processor to classify the physiological data as resting data or as non-resting data based on the determination that the patient is at rest. (Item 178) Item 178. The wearable device of item 177, wherein the physiological data further includes electrocardiogram (ECG) data, and the machine-executable instructions, when executed by the processor, cause the processor to measure a resting heart rate from the ECG data from the physiological data while the patient is determined to be at rest. (Item 179) Item 179. The wearable device of item 178, wherein the machine executable instructions, when executed by the processor, cause the processor to measure the resting heart rate from the largest segment of physiological data within a 24-hour period classified as resting data. (Item 180) The wearable device of any one of items 168 to 179, wherein the wearable device is configured to be removably attached to the patient's skin. (Item 181) 1. A method for measuring the serenity of a patient, comprising: receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data; determining that the patient is at rest based on the accelerometer data. method. (Item 182) 182. The method of claim 181, further comprising measuring body angle data and total activity data of the patient from the accelerometer data, and determining that the patient is at rest based on the body angle data and total activity data. (Item 183) 183. The method of claim 182, further comprising adding body angle data to a body angle aggregation window until a threshold time period is covered by the body angle data and measuring aggregate body angle data based on the body angle aggregation window, wherein determining that the patient is at rest is based on the aggregate body angle data. (Item 184) 184. The method of claim 182 or 183, further comprising: adding total activity data to a total activity aggregation window until a threshold time period is covered by the total activity data; and measuring aggregated total activity data based on the total activity aggregation window, wherein determining that the patient is resting is based on the aggregated total activity data. (Item 185) 185. The method of any one of items 182 to 184, further comprising removing values ​​in the total activity data that are equal to or greater than a threshold value. (Item 186) Item 186. The method of any one of items 182 to 185, further comprising determining that the body angle data within the body angle aggregation window is valid. (Item 187) Item 187. The method of any one of items 182 to 186, further comprising ignoring second body angle data within the body angle aggregation window that is not valid. (Item 188) Item 188. The method of any one of items 182 to 187, further comprising determining that the total activity data within the total activity aggregation window is valid. (Item 189) Item 189. The method of any one of items 182 to 188, further comprising ignoring second total activity data within the total activity aggregation window that is not valid. (Item 190) 190. The method of any one of claims 181 to 189, further comprising classifying the physiological data as resting data or non-resting data based on the determination that the patient is at rest. (Item 191) Item 191. The method of item 190, wherein the physiological data further comprises electrocardiogram (ECG) data, and further comprising measuring a resting heart rate from the ECG data from the physiological data while the patient is determined to be at rest. (Item 192) Item 192. The method of item 191, further comprising measuring the resting heart rate from the largest segment of physiological data within a 24-hour period classified as resting data. (Item 193) The method of any one of items 181 to 192, further comprising removably attaching a wearable device to the patient's skin, and receiving the discontinuous data comprises receiving the discontinuous data by the wearable device.

Claims

1. A system for determining patient rest, comprising: a wearable device comprising an accelerometer, the wearable device configured to be coupled to a body of the patient and configured to detect discontinuous data utilizing at least the accelerometer and electrodes, the discontinuous data including frames of ingestible sensor data and frames of physiological data from the patient interspersed in time gaps between the frames of ingestible sensor data, the physiological data including accelerometer data from the accelerometer; A processor of at least one of the wearable device and a remote device communicatively connected to the wearable device, the processor comprising: receiving the discontinuous data from the wearable device; generating average body angle data using the accelerometer data within the discrete data; determining that an amount of generated average body angle data above an aggregation threshold has been collected; calculating a data ratio of a total number of collected data points in said average body angle data to an expected number of data points in an aggregation window period; determining that the amount of generated average body angle data can be used reliably based on the calculated data ratio exceeding a data ratio threshold; classifying the average body angle data into at least one of a plurality of classifications including "lying down" and "not lying down"; a processor configured to determine that the patient is at rest by A system comprising:

2. The system of claim 1, further comprising the processor configured to determine total activity data from the accelerometer data and determine that the patient is at rest based further on the body angle data and the total activity data.

3. The system of claim 2, further comprising the processor configured to add the total activity data to a total activity aggregation window until a threshold period is covered by the total activity data, and determine aggregated total activity data based on the total activity aggregation window, wherein the patient is determined to be at rest further based on the aggregated total activity data.

4. The system of claim 3, further comprising the processor configured to remove values ​​of the total activity data that are greater than or equal to a total activity data threshold.

5. The system of claim 1, further comprising the processor configured to determine that the body angle data within a body angle aggregation window is valid.

6. The system of claim 5, further comprising the processor configured to ignore second body angle data within the body angle aggregation window that is not valid.

7. The system of claim 3, further comprising the processor configured to determine that the total activity data within a total activity aggregation window is valid.

8. The system of claim 7, further comprising the processor configured to ignore second total activity data within the total activity aggregation window that is not valid.

9. The system of claim 1, further comprising the processor configured to classify the physiological data as resting data or non-resting data based on a determination that the patient is at rest.

10. The system of claim 1, wherein the physiological data further includes electrocardiogram (ECG) data, and the processor is configured to determine a resting heart rate from the ECG data in the physiological data during a period during which the patient is determined to be at rest.

11. The system of claim 1, wherein the processor is configured to determine a resting heart rate from the largest segment of the physiological data within a 24-hour period classified as resting data.

12. The system of claim 1, wherein the wearable device is configured to be removably attached to the patient's skin.

13. A wearable device including a processor coupled to a non-transitory memory, the non-transitory memory including machine-executable instructions that, when executed by the processor, receiving discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data; generating average body angle data using the accelerometer data within the discrete data; determining that an amount of generated average body angle data above an aggregation threshold has been collected; calculating a data ratio of a total number of collected data points in said average body angle data to an expected number of data points in an aggregation window period; determining that the amount of generated average body angle data can be used reliably based on the calculated data ratio exceeding a data ratio threshold; classifying the average body angle data into at least one of a plurality of classifications including "lying down" and "not lying down"; A wearable device comprising:

14. A method for determining patient rest, comprising: receiving discontinuous data, the discontinuous data including frames of ingestible sensor data and frames of physiological data from a patient interspersed in time gaps between the frames of ingestible sensor data; generating average body angle data using the accelerometer data within the discrete data; determining that an amount of generated average body angle data above an aggregation threshold has been collected; calculating a data ratio of a total number of collected data points in said average body angle data to an expected number of data points in an aggregation window period; determining that the amount of generated average body angle data can be used reliably based on the calculated data ratio exceeding a data ratio threshold; classifying the average body angle data into at least one of a plurality of classifications including "lying down" and "not lying down"; The method includes:

Citation Information

Patent Citations

  • Body motion monitoring system in radiotherapy

    JP2009279019A

  • Body-associated receiver and method

    JP2014208301A

  • Posture estimation device, posture estimation system, posture estimation method, and program

    JP2016150034A

  • System and Method for Body and In-Vivo Device, Motion and Orientation Sensing and Analysis

    US20130261410A1