Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tutorial ppg #106

Merged
merged 72 commits into from
Jan 14, 2025
Merged

Tutorial ppg #106

merged 72 commits into from
Jan 14, 2025

Conversation

KarsVeldkamp
Copy link
Contributor

@KarsVeldkamp KarsVeldkamp commented Jan 13, 2025

In this PR I created the tutorial for PPG but also did the following:

  1. Changed the PPG preprocessing function (within preprocessing.py) to have a seperate io wrapper so I could load the tsdf data in memory before preprocessing. I did not include the loading function in the util.py while the other tsdf loading function is. Now I call it directly from tsdf --> what do you think of this?
  2. Changed the ppg_analysis.ipynb accordingly
  3. Changed from os.path.join to Path

KarsVeldkamp and others added 30 commits December 3, 2024 08:36
"cell_type": "markdown",
"metadata": {},
"source": [
"For heart rate estimation, we extract segments of `config.tfd_length`. Using a 2-step approach, we calculate the smoothed-pseudo Wigner-Ville Distribution to obtain the frequency content of the PPG signal over time. For every 2-second window, we identified the frequency with the highest power for each data point and assigned the average of these frequency as the heart rate in that 2-second window. "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also print the tsdf_length here.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the 2-step approach? Does it add value to mention it here?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check the tense of your language: present vs past.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With data point you mean each timestamp constituting the 2-second window, right? How does each timestamp have a frequency spectrum? Does that have to do with the WVD?

And perhaps, could you explain what the relation is between "the average of these frequencies" and "the heart rate in that 2-second window"? I can't fully make that equation, might be useful to clarify how A represents B.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To comment on your last questions:

  1. Yes WVD returns a frequency spectrum for every data point (because it uses every lag in the autocorrelation function)
  2. We extract for every timestamp in that 2s window the frequency with the most power. This results in an array of "dominant" frequencies which I average.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have tried to make this more self-explaining

" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>rel_time</th>\n",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's relative time? Could you explain why this changed from time to rel_time?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing, I'll adjust it to time ;)

"cell_type": "markdown",
"metadata": {},
"source": [
"The final step is to aggregate all 2-second heart rate estimates. In the current example, the mode and 99th percentile are calculated. The mode represent the resting heart rate while the 99th percentile indicates the maximum heart rate. In Parkinson's disease, we expect that these two measures could reflect autonomic (dys)functioning."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How is the mode representing the resting heart rate? Is this because the most prevalent heart rate is when we are resting?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

"text": [
"{'hr_aggregates': {'99p_heart_rate': 86.62868369351669,\n",
" 'mode_heart_rate': 84.8722986247544},\n",
" 'metadata': {'nr_hr_est': 6}}\n"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nr_hr_est is difficult for me to interpret, could you explain?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If people collect both accelerometer and PPG data, longitudinally, this function actually might make sense to have as a utility in the toolbox. I would move it to util.py therefore. I would leave all "necessary" functionalities in preprocessing.py.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do think this functionality is tsdf-specific, so we should think about how a user using csv or other formats could do this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure where you exactly referring to but I assume this is to scan_and_sync_segments? This is on my list to remove it from preprocessing and set it to util or another place and it is tsdf-specific indeed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then also the extract_meta_from_tsdf_files will be removed in the preprocessing.py

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes apologies, it's about scan_and_sync_segments. Check.

@@ -245,6 +245,21 @@ def preprocess_imu_data_io(path_to_input: str | Path, path_to_output: str | Path


def scan_and_sync_segments(input_path_ppg, input_path_imu):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please set strict data types for the input parameters.

Metadata for the IMU data.
output_path : Union[str, Path]
Path to store the preprocessed data.
ppg_config : PPGPreprocessingConfig
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PPGConfig

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

THis is very old documentation ;)

output_path : Union[str, Path]
Path to store the preprocessed data.
ppg_config : PPGPreprocessingConfig
Configuration object for PPG preprocessing.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMUConfig

Configuration object for PPG preprocessing.
imu_config : IMUPreprocessingConfig
Configuration object for IMU preprocessing.
sensor: str
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This parameter is removed.

Copy link
Contributor

@Erikpostt Erikpostt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have raised some questions and made some suggestions. Let me know what you think.

@KarsVeldkamp
Copy link
Contributor Author

@Erikpostt I have made changes based on your feedback (visible in commit 40e768a. Let me know what you think of this

"The first step after loading the data is to preprocess the data. Preprocessing starts by extracting the data where there is both PPG and IMU data. In this way, we discard the the first or last part of the segment when e.g. the PPG segment is recorded longer than the accelerometer. After this step, the preprocess_ppg_data function resamples the values of both PPG and accelerometer data using uniformly distributed timestamps, since the sampling rate of both sensors is fixed but not uniform. After this, a bandpass filter (butterworth, 4th-order, cut-off frequencies: [0.4, 3.5]) is applied to the PPG signal and a high-pass (butterworth, 4th-order, cut-off: 0.2 Hz) filter is applied to the accelerometer. "
"The first step after loading the data is preprocessing. This begins by isolating segments containing both PPG and IMU data, discarding portions where one modality (e.g., PPG) extends beyond the other, such as when the PPG recording is longer than the accelerometer data. After this step, the preprocess_ppg_data function resamples the PPG and accelerometer data to uniformly distributed timestamps, addressing the fixed but non-uniform sampling rates of the sensors. After this, a bandpass Butterworth filter (4th-order, bandpass frequencies: 0.4--3.5 Hz) is applied to the PPG signal, while a high-pass Butterworth filter (4th-order, cut-off frequency: 0.2 Hz) is applied to the accelerometer data.\n",
"\n",
"Note: the printed shapes are the data points (rows) and the data columns (rows x columns). The number of rows of the overlapping segments of PPG and accelerometer are not exactly the same due to sampling differences (other sensors and possibly other sampling frequencies). "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you meant to say (rows, columns), with each row corresponding to a single data points? Now it looks like rows are data points, and rows x columns are data columns.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I made slight adjustments in this sentence

@@ -953,7 +968,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"A trained logistic classifier is used to classify PPG signal quality and returns the `pred_sqa_proba`, which is the posterior probability of a PPG window to look like the typical PPG morphology (higher probability indicates toward the typical PPG morphology). The relative power feature from the accelerometer is compared to a threshold for periodic artifacts and therefore `pred_sqa_acc_label` returns a label indicating probably periodic motion artifacts (label 0) or no periodic motion artifacts (label 1). "
"A trained logistic classifier is used to predicts PPG signal quality and returns the `pred_sqa_proba`, which is the posterior probability of a PPG window to look like the typical PPG morphology (higher probability indicates toward the typical PPG morphology). The relative power feature from the accelerometer is compared to a threshold for periodic artifacts and therefore `pred_sqa_acc_label` returns a label indicating predicted periodic motion artifacts (label 0) or no periodic motion artifacts (label 1). "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

predicts = predict
returns = return (as in, "is used to return", but could also be "returns" as in "and it returns")

@@ -1090,14 +1105,21 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"For heart rate estimation, we extract segments of `config.tfd_length`. Using a 2-step approach, we calculate the smoothed-pseudo Wigner-Ville Distribution to obtain the frequency content of the PPG signal over time. For every 2-second window, we identified the frequency with the highest power for each data point and assigned the average of these frequency as the heart rate in that 2-second window. "
"For heart rate estimation, we extract segments of `config.tfd_length`. We calculate the smoothed-pseudo Wigner-Ville Distribution (SPWVD) to obtain the frequency content of the PPG signal over time. We extract for every timestamp in the SPWVD for the frequency with the highest power. For every non-overlapping 2-second window we average the corresponding frequencies to obtain a heart rate per window. "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"... SPWVD for the ..." should be "... SPWVD the ..."

@@ -1193,7 +1216,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"The final step is to aggregate all 2-second heart rate estimates. In the current example, the mode and 99th percentile are calculated. The mode represent the resting heart rate while the 99th percentile indicates the maximum heart rate. In Parkinson's disease, we expect that these two measures could reflect autonomic (dys)functioning."
"The final step is to aggregate all 2-second heart rate estimates. In the current example, the mode and 99th percentile are calculated. We hypothesize that the mode gives representation of the resting heart rate while the 99th percentile indicates the maximum heart rate. In Parkinson's disease, we expect that these two measures could reflect autonomic (dys)functioning. The `nr_hr_est` in the metadata indicates on how many 2-second windows these aggregates are determined."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure, but should "... indicates on how many ..." be "... indicates based on how many ..."?

Also try to be consistent in using "2-second" or "2 s". I think I saw "2 s" somewhere.

"ppg_config = SignalQualityFeatureExtractionConfig()\n",
"acc_config = SignalQualityFeatureExtractionAccConfig()\n",
"print(\"The default window length for the signal quality feature extraction is set to\", ppg_config.window_length_s, \"seconds.\")\n",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This cell is a bit cluttered. Try to add some whitespaces

  • imports
  • configs
  • prints
  • function
  • print

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This also applies to some other cells.

Copy link
Contributor

@Erikpostt Erikpostt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've made some small suggestions, otherwise ready to merge.

@KarsVeldkamp
Copy link
Contributor Author

@Erikpostt Thanks for your feedback, I have made the last adjustments and will merge it now!

@KarsVeldkamp KarsVeldkamp merged commit 3eafaf7 into main Jan 14, 2025
1 check passed
@KarsVeldkamp KarsVeldkamp deleted the tutorial-ppg branch January 14, 2025 06:33
KarsVeldkamp added a commit that referenced this pull request Jan 17, 2025
* change test output

* Update tremor_analysis.ipynb

* add documentation

* fix bug

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* Simplify

* Updating Poetry

* clear execution count

* Remove angle and velocity from preprocessing

* import heart_rate_estimation

* Change rotation axes

* Adjust parameters segmentation

* Add flexibility for pathing

* Return a Series instead of df

* ensure features dont scale when storing

* Update tabulate windows

* Heart rate estimation (#85)

* Start heart rate estimation including tfd

* stash updates

* update based on merge conflicts

* update hr main function

* update minor stuff matlab files

* change tfd parameters to dict

* Finalizing heart rate pipeline plus renaming preprocessing to acc instead of imu

* setting execution count to null

* fix output types

* fixing pytype due to old configs

* fix min_hr_samples pytype error

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* clear execution count

* clear execution counts

* execution counts + indentation + short documentation

* update final comments + small matlab changes

* merge updates

* Solve pytype issue

* Solve pytype issue

* added suggestions

* remove execution counts

* update ppg_analysis

* test update notebook

* execution counts

* Vectorize merging of predictions with timestamps

* Add flexibility to filtering gait parameters

* Remove redundant cells in notebooks

* Solve bugs

* Solve conflict

* Continue process when dataframe is empty

* Modify quantification

* Modify quantification

* Typo

* Add flexibility for pred proba to merging

* Add flexibility for pred proba to merging

* Add flexibility for pred proba to merging

* Solve numpy/list bug

* Solve numpy/list bug

* Solve numpy/list bug

* Solve numpy/list bug

* Start catching errors

* Start catching errors

* Fix np.nan issue

* Fix np.nan issue

* Reduce memory reqs

* Temp for debugging

* Temp for debugging

* Typo

* replace df to numpy arrays

* fix notebook

* adding accelerometer feature

* fix type error list vs float

* Expand feature extraction docs

* change notebook accordingly

* Update notebooks

* Add '1' to MFCC filter points

* implement accelerometer feature

* update matlab file based on refactoring

* fixing types, docstrings and readibility

* adding documentation acc feature

* add documentation of autocorrelation

* Pandas to numpy ppg (#93)

* Start heart rate estimation including tfd

* stash updates

* update based on merge conflicts

* update hr main function

* update minor stuff matlab files

* change tfd parameters to dict

* First steps to refactoring to numpy

* Finalizing heart rate pipeline plus renaming preprocessing to acc instead of imu

* setting execution count to null

* fix output types

* fixing pytype due to old configs

* fix min_hr_samples pytype error

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* clear execution count

* import heart_rate_estimation

* merge updates

* update ppg_analysis

* replace df to numpy arrays

* fix notebook

* fix type error list vs float

* fixing types, docstrings and readibility

* add documentation of autocorrelation

---------

Co-authored-by: Erikpostt <erik_post_6@hotmail.com>

* Modify test data

* Change mfcc param

* Change mfcc param

* Structure

* Reset legacy for the time being

* Adjust test scripts to changes

* Adjust tremor to changes

* structure docstrings

* Improve consistency of docstrings

* Structure testing

* Update test data

* Resolve pytype error

* Adjust tabulate_windows to new version

* Ensure first column is returned for PPG

* modify mfcc calculation and update classifier

* Made requested changes

* fix config

* modify test data

* Adding accelerometer to ppg (#95)

* Start heart rate estimation including tfd

* stash updates

* update based on merge conflicts

* update hr main function

* update minor stuff matlab files

* change tfd parameters to dict

* First steps to refactoring to numpy

* Finalizing heart rate pipeline plus renaming preprocessing to acc instead of imu

* setting execution count to null

* fix output types

* fixing pytype due to old configs

* fix min_hr_samples pytype error

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* clear execution count

* import heart_rate_estimation

* merge updates

* update ppg_analysis

* replace df to numpy arrays

* fix notebook

* adding accelerometer feature

* fix type error list vs float

* implement accelerometer feature

* update matlab file based on refactoring

* fixing types, docstrings and readibility

* adding documentation acc feature

* add documentation of autocorrelation

* Made requested changes

* fix config

---------

Co-authored-by: Erikpostt <erik_post_6@hotmail.com>

* add tutorial

* Solve issues raised by reviewer

* Rerun notebooks ppg

* Change scalers, classifiers and thresholds

* Update test files

* Add aggregation of quantification

* modified tutorial

* update tutorial

* remove execution counts

* Add ability to create classifier objects

* Test to remove rom features

* Test to remove rom features

* adding aggregation heart rate

* Adjust functions to classification package

* Update package loading

* Adjust gait pipeline to classifier packages

* added suggestions

* Change test data with new classifier

* Adjust tests and ensure Path used in notebooks

* Change pathing to fix poetry pytest

* restructure functions

* update test data

* update tutorial

* fixed typo's

* Merge with main

* update aggregates

* remove config

* Add files via upload

* add start tutorial

* aggregation implementation with dictionary

* add lines for consistency

* Add user guides for coordinate system and update index of docs

* moved windoweddataextractor to segmenting

* Displays outputs of data preparation tutorial

* Heart rate aggregation (#102)

* Start heart rate estimation including tfd

* stash updates

* update based on merge conflicts

* update hr main function

* update minor stuff matlab files

* change tfd parameters to dict

* First steps to refactoring to numpy

* Finalizing heart rate pipeline plus renaming preprocessing to acc instead of imu

* setting execution count to null

* fix output types

* fixing pytype due to old configs

* fix min_hr_samples pytype error

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* clear execution count

* import heart_rate_estimation

* merge updates

* update ppg_analysis

* replace df to numpy arrays

* fix notebook

* adding accelerometer feature

* fix type error list vs float

* implement accelerometer feature

* update matlab file based on refactoring

* fixing types, docstrings and readibility

* adding documentation acc feature

* add documentation of autocorrelation

* Made requested changes

* fix config

* adding aggregation heart rate

* update aggregates

* remove config

* aggregation implementation with dictionary

* add lines for consistency

* moved windoweddataextractor to segmenting

* updates based on review

---------

Co-authored-by: Erikpostt <erik_post_6@hotmail.com>

* resolve merge conflict

* add tremor classifier package

* update notebook

* remove execution counts

* Modify according to feedback of reviewer

* update test function

* Concat forward & backward pav to allow for dataframes

* Renaming functions

* Add error messages when df is empty

* Print -> Raise eerror messages when df is empty

* Also raise when no gait without other arm activity

* Remove irrelevant test files and raise valuerrors

* Reset to io wrappers

* Update docstrings

* update loading + preprocessing with seperate functionality

* update tutorial notebook and corresponding notebook

* change path usage

* Update test to io function

* Update README.md

* print notebook output

* change total psd

* add function links

* Faster computation using any()

* Remove unnecessary improts

* Tutorial ppg (#106)

* Start heart rate estimation including tfd

* stash updates

* update based on merge conflicts

* update hr main function

* update minor stuff matlab files

* change tfd parameters to dict

* First steps to refactoring to numpy

* Finalizing heart rate pipeline plus renaming preprocessing to acc instead of imu

* setting execution count to null

* fix output types

* fixing pytype due to old configs

* fix min_hr_samples pytype error

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* clear execution count

* import heart_rate_estimation

* merge updates

* update ppg_analysis

* replace df to numpy arrays

* fix notebook

* adding accelerometer feature

* fix type error list vs float

* implement accelerometer feature

* update matlab file based on refactoring

* fixing types, docstrings and readibility

* adding documentation acc feature

* add documentation of autocorrelation

* Made requested changes

* fix config

* adding aggregation heart rate

* update aggregates

* remove config

* add start tutorial

* aggregation implementation with dictionary

* add lines for consistency

* moved windoweddataextractor to segmenting

* resolve merge conflict

* update loading + preprocessing with seperate functionality

* update tutorial notebook and corresponding notebook

* Update test to io function

* update tutorial and notebook with simplified loading of the data

* Reset execution counts in notebook cells

* update execution_counts and output

* Updates from PR feedback

* fix type error

* made final feedback

---------

Co-authored-by: Erikpostt <erik_post_6@hotmail.com>
Co-authored-by: Erik Post <57133568+Erikpostt@users.noreply.github.com>

* Resolve merge conflict

* add suggestions

* Move notebooks to parent directory and remove subdirectories

* change total_psd_calculation again

* Modify structure of files

* Update classifier, update test data, update dependencies, update testing gait pipeline

* Update dtypes heart rate pipeline

* Reset scikit version, update tremor values

* Remove notebook temporarily to pass tests

* Reduce no. of configs and change notebooks accordingly

* Update test data

* Remove redundant files

* final suggestions

* Modify tremor low freq power and slightly adjust tutorial

* Change git attributes to ensure output in tutorials

* Test displaying output tutorials

* Test displaying output tutorials

* Test II

* Update config and remove nbstripout from gitattributes

* Add tutorial outputs other domains

* Merge conflict heart rate pipeline

* Merge conflicts gait pipeline

* Merge conflicts gait pipeline

* Update notebooks

* Revert time to first binary file

* Add suggestions

* Iterate on tutorial gait

* Complete gait pipeline

* Classifier package ppg (#109)

* Start heart rate estimation including tfd

* stash updates

* update based on merge conflicts

* update hr main function

* update minor stuff matlab files

* change tfd parameters to dict

* First steps to refactoring to numpy

* Finalizing heart rate pipeline plus renaming preprocessing to acc instead of imu

* setting execution count to null

* fix output types

* fixing pytype due to old configs

* fix min_hr_samples pytype error

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* clear execution count

* import heart_rate_estimation

* merge updates

* update ppg_analysis

* replace df to numpy arrays

* fix notebook

* adding accelerometer feature

* fix type error list vs float

* implement accelerometer feature

* update matlab file based on refactoring

* fixing types, docstrings and readibility

* adding documentation acc feature

* add documentation of autocorrelation

* Made requested changes

* fix config

* adding aggregation heart rate

* update aggregates

* remove config

* add start tutorial

* aggregation implementation with dictionary

* add lines for consistency

* moved windoweddataextractor to segmenting

* resolve merge conflict

* update loading + preprocessing with seperate functionality

* update tutorial notebook and corresponding notebook

* Update test to io function

* update tutorial and notebook with simplified loading of the data

* Reset execution counts in notebook cells

* update execution_counts and output

* Updates from PR feedback

* fix type error

* remove unneccessary matlab files

* update merge conflicts

* update using classifier package

* fix pkl feature names in scaler and delete old classifier files

* renaming ppg to heart rate

* rename files ppg to heart_rate

* remove legacy classification

* renaming clf_package

* modify tutorial

* update abs stats

* update tutorial based on abs stats output

* Remove redundant stuff from notebook

* remove tremor txt files

* update tutorial based on right config settings

* type error fix

* fix type error

* update based on suggestions

---------

Co-authored-by: Erikpostt <erik_post_6@hotmail.com>
Co-authored-by: Erik Post <57133568+Erikpostt@users.noreply.github.com>

* Add tutorial data

* Update tutorial per reviewers remarks

* Remove output notebooks

* Update docs

* DRAFT: Update sync functions (#115)

* Start heart rate estimation including tfd

* stash updates

* update based on merge conflicts

* update hr main function

* update minor stuff matlab files

* change tfd parameters to dict

* First steps to refactoring to numpy

* Finalizing heart rate pipeline plus renaming preprocessing to acc instead of imu

* setting execution count to null

* fix output types

* fixing pytype due to old configs

* fix min_hr_samples pytype error

* remove irrelevant config

* resolved comments PR reviewer

* remove data type since it causes pytype error

* clear execution count

* import heart_rate_estimation

* merge updates

* update ppg_analysis

* replace df to numpy arrays

* fix notebook

* adding accelerometer feature

* fix type error list vs float

* implement accelerometer feature

* update matlab file based on refactoring

* fixing types, docstrings and readibility

* adding documentation acc feature

* add documentation of autocorrelation

* Made requested changes

* fix config

* adding aggregation heart rate

* update aggregates

* remove config

* add start tutorial

* aggregation implementation with dictionary

* add lines for consistency

* moved windoweddataextractor to segmenting

* resolve merge conflict

* update loading + preprocessing with seperate functionality

* update tutorial notebook and corresponding notebook

* Update test to io function

* Update notebook with functional links

* move scan_and_sync_segments to util with corresponding functions

* remove ppp functionalities from util

* Correct implementation of the extract_overlapping_segments

* update tests without scan_and_sync_segments

* updates based on suggestions

* fix type error

---------

Co-authored-by: Erikpostt <erik_post_6@hotmail.com>

* Major reshuffling of files and directories

* Adding nbsphinx

* update tutorials functional links + preprocessing

* Update readme contact (#119)

---------

Co-authored-by: nienketimmermans <65012819+nienketimmermans@users.noreply.github.com>
Co-authored-by: KarsVeldkamp <veldkampkars@gmail.com>
Co-authored-by: KarsVeldkamp <105375796+KarsVeldkamp@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants