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

0.2.11 #1022

Open
wants to merge 36 commits into
base: master
Choose a base branch
from
Open

0.2.11 #1022

wants to merge 36 commits into from

Conversation

DominiqueMakowski
Copy link
Member

Roadmap

RSP

  • Add rsp_segment() (similar to ppg_segment())
  • Add the cycle overlay plots to RSP
  • Streamline rsp_plot() (same as ppg_plot())

PPG

  • Detect PPG diastolic peaks? (between each peak and the next trough)
  • Add PPG amplitude calculation (reduction can be indicative of vasoconstriction in stress, cold)
  • Document peak-extraction methods (PPG)
  • add more PPG detectors (@peterhcharlton)
  • hrv_rsa(): Add method argument to compute only one RSA signal. Do something with warning that will be thrown when using bio_process() on signals < 32 sec where it will complain that the signal is too short to compute RSA with one of these methods.

Misc

danibene and others added 8 commits August 16, 2024 17:41
Fix: Lightmode now shows text correctly for the codebook
Addressing issue #1043
Change 'templatematch' implementation to use interpolation method 'previous' rather than 'quadratic'. This aligns it with the 'disimilarity' implementation and is a better representation of the beat-by-beat nature of the quality measure.
[docs] Fix the docstring in eda_process for SCR_RiseTime
[Docs] Add a note about the units used for the time-based HRV metrics.
JonasEmrich and others added 6 commits November 27, 2024 10:09
Co-authored-by: Dominique Makowski <dom.mak19@gmail.com>
Co-authored-by: Dominique Makowski <dom.mak19@gmail.com>
[Feature] Add new ECG delineator method: Peak-Prominence (Emrich et al., 2024)
@pull-request-size pull-request-size bot added size/L and removed size/S labels Nov 27, 2024
cgastaud and others added 10 commits November 30, 2024 11:54
…-y-as-series

[Fix] Squeeze y_values in signal_interpolate
…g_quality

[Change] Update ppg_quality.py to use consistent interpolation method ('previous')
[Change] ecg_quality interpolation from quadratic to "previous"
Co-authored-by: Johannes Herforth  <DerAndereJohannes+25019880@users.noreply.github.com>
[Fix] update data/database.py to use urllib methods. fixes #1061
@DominiqueMakowski
Copy link
Member Author

DominiqueMakowski commented Feb 11, 2025

Docs failed at one file in particular

reading sources... [ 25%] examples/eeg_microstates/eeg_microstates
D:\a\NeuroKit\NeuroKit\docs\examples\eeg_microstates\eeg_microstates.ipynb: Executing notebook using local CWD [mystnb]

But tests fail systematically for unclear reasons

@DominiqueMakowski
Copy link
Member Author

@DerAndereJohannes I know this is a lot to ask you given the help you've already provided but do you have some wild guess as to why?

@DerAndereJohannes
Copy link
Collaborator

I am currently looking into it. On my local runner there seems to be a problem with getting data from mne. Ill keep you updated!

On a side note, I should also update to workflow such that the log files become accessible for us to view the more verbose error

@DominiqueMakowski
Copy link
Member Author

at least I think there's a different error now 🥲

- Changes due to removal of wavelets from scipy in 1.15
@DerAndereJohannes
Copy link
Collaborator

DerAndereJohannes commented Feb 12, 2025

The error is due to scipy removing support for wavelets in 1.15 which the pipeline now uses. I have updated this in #1074 .

Looking at the logs however, there is another issue. You updated the python version to 3.13 which the package ts2vg does not seem to support yet (it installs correctly on 3.12) as it resulted in an installation error (although this somehow did not stop the pipeline?

Collecting ts2vg
  Downloading ts2vg-1.2.4.tar.gz (774 kB)
     ------------------------------------- 775.0/775.0 kB 14.1 MB/s eta 0:00:00
  Installing build dependencies: started
  Installing build dependencies: finished with status 'done'
  Getting requirements to build wheel: started
  Getting requirements to build wheel: finished with status 'error'
  error: subprocess-exited-with-error
  
  Getting requirements to build wheel did not run successfully.
  exit code: 1
  
  [36 lines of output]
  Traceback (most recent call last):
    File "C:\hostedtoolcache\windows\Python\3.13.1\x64\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 389, in <module>
      main()
      ~~~~^^
    File "C:\hostedtoolcache\windows\Python\3.13.1\x64\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 373, in main
      json_out["return_val"] = hook(**hook_input["kwargs"])
                               ~~~~^^^^^^^^^^^^^^^^^^^^^^^^
    File "C:\hostedtoolcache\windows\Python\3.13.1\x64\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 143, in get_requires_for_build_wheel
      return hook(config_settings)
    File "C:\Users\runneradmin\AppData\Local\Temp\pip-build-env-75mgcoi7\overlay\Lib\site-packages\setuptools\build_meta.py", line 334, in get_requires_for_build_wheel
      return self._get_build_requires(config_settings, requirements=[])
             ~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "C:\Users\runneradmin\AppData\Local\Temp\pip-build-env-75mgcoi7\overlay\Lib\site-packages\setuptools\build_meta.py", line 304, in _get_build_requires
      self.run_setup()
      ~~~~~~~~~~~~~~^^
    File "C:\Users\runneradmin\AppData\Local\Temp\pip-build-env-75mgcoi7\overlay\Lib\site-packages\setuptools\build_meta.py", line 320, in run_setup
      exec(code, locals())
      ~~~~^^^^^^^^^^^^^^^^
    File "<string>", line 45, in <module>
    File "<string>", line 39, in main
    File "C:\Users\runneradmin\AppData\Local\Temp\pip-build-env-75mgcoi7\overlay\Lib\site-packages\Cython\Build\Dependencies.py", line 1010, in cythonize
      module_list, module_metadata = create_extension_list(
                                     ~~~~~~~~~~~~~~~~~~~~~^
          module_list,
          ^^^^^^^^^^^^
      ...<4 lines>...
          language=language,
          ^^^^^^^^^^^^^^^^^^
          aliases=aliases)
          ^^^^^^^^^^^^^^^^
    File "C:\Users\runneradmin\AppData\Local\Temp\pip-build-env-75mgcoi7\overlay\Lib\site-packages\Cython\Build\Dependencies.py", line 845, in create_extension_list
      for file in nonempty(sorted(extended_iglob(filepattern)), "'%s' doesn't match any files" % filepattern):
                  ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "C:\Users\runneradmin\AppData\Local\Temp\pip-build-env-75mgcoi7\overlay\Lib\site-packages\Cython\Build\Dependencies.py", line 117, in nonempty
      raise ValueError(error_msg)
  ValueError: 'ts2vg/graph/_base.pyx' doesn't match any files
  [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

Getting requirements to build wheel did not run successfully.
exit code: 1

See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
Collecting pickleshare

Alternatively, we could try to get rid of the dependency altogether since it seems to be only used by one function. If we made a replication of what we need in this repo it would also save the hassle of controlling for that dependency.

$ rg -i ts2vg
ecg/ecg_findpeaks.py
1229:    # Try loading ts2vg
1231:        import ts2vg
1234:            "NeuroKit error: ecg_findpeaks(): the 'ts2vg' module is required for"
1235:            " this method to run. Please install it first (`pip install ts2vg`)."
1277:            ts2vg.NaturalVG(directed="top_to_bottom")

DominiqueMakowski and others added 3 commits February 12, 2025 18:33
[Update] changes scipy.signal.daub to PyWavelets format
- Numpy no longer has np.math and recommends the built-in math
[Fix] Replaced np.math with built-in math
@DominiqueMakowski
Copy link
Member Author

I'd say let's just skip that test/example for now and we'll reactive it when that dependency gets updated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants