Thanks for your interest in contributing to biopeaks
! Please have a look at the code of conduct.
Please report bugs or ask questions by opening an issue
in the biopeaks
repository.
If you plan to contribute relatively large changes, please open an issue
in the biopeaks
repository before
you start working on your contribution. This way we can discuss your plans before you start writing/coding.
You can follow these steps to contribute documentation, tests, or code:
biopeaks
repository.topic
branch with a descriptive name to your fork. For example, if you want to contribute an improvement to the documentation you could call the topic
branch improve-docs
.biopeaks
in development mode:
topic
branch, following the conventions.topic
branch on your fork to the dev
branch of the biopeaks
repository.The GUI is structured according to a variant of the
model-view-controller architecture.
To understand the relationship of the model
, view
, and controller
have a look
at how each of them is instantiated in __main__.py
.
For example, the view
has references to the model
as well as the
controller
, whereas the model
has no reference to any of the other
components of the architecture (i.e., the model
is agnostic to the view
and
controller
).
The documentation is hosted on GitHub pages, a static website associated
with the biopeaks
repository: https://jancbrammer.github.io/biopeaks/. It
is automatically build from the /docs
folder in the root of the biopeaks
repository.
The website is re-build every very time the content of /docs
changes on the
main branch (pushes, merged pull requests). /docs
includes an index.md
file
that constitutes the “landing page”. It contains links to all other parts of the
documentation. The layout of the website is defined in /docs/layouts
. For
additional information, head over to the GitHub pages documentation.
The OpenSignals test data have been recorded with
software: opensignals v2.0.0, 20190805
hardware: BITalino (r)evolution (firmware 1281)
The EDF test data have been downloaded from https://www.teuniz.net/edf_bdf_testfiles/
All test data are part of the biopeaks installation and do not have to be downloaded.
Please make sure to have pytest as well as pytest-qt installed before running the tests.
The tests can then be run in the test directory with pytest:
pytest -v
To validate the performance of the ECG peak detector heart.ecg_peaks()
, please install the wfdb and aiohttp.
You can then run the benchmark_ECG_stream
script in the benchmarks
folder. The script streams ECG and annotation files from the Glasgow University Database (GUDB).
You can select an experiment, ECG channel, and annotation file.
Alternatively, you can download the GUDB and run the benchmark_ECG_local
script in the benchmarks
folder. In the script, replace the data_dir
with your local directory (see comments in the script).
To validate the performance of the PPG peak detector heart.ppg_peaks()
please download the Capnobase IEEE TBME benchmark dataset and install wfdb and h5py.
You can then run the benchmark_PPG_local
script in the benchmarks
folder. In the script, replace the data_dir
with your local directory (see comments in the script).
Use the project’s devcontainer (e.g., in Visual Studio Code) to set up your local development environment.