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

Index out of range signal.go 21 #2

Open
BrandonRaeder opened this issue Jul 24, 2022 · 7 comments
Open

Index out of range signal.go 21 #2

BrandonRaeder opened this issue Jul 24, 2022 · 7 comments

Comments

@BrandonRaeder
Copy link

BrandonRaeder commented Jul 24, 2022

Never Mind! Not enough data..

@eripe970
Copy link
Owner

Cool! :) Hope you like the library, if you have any improvements, just open a PR :)

@BrandonRaeder
Copy link
Author

K! I'm half a programmer so I stumble over basic things. The out of range index was coming in because I didn't have 10 seconds of data yet call thing the function.

@eripe970
Copy link
Owner

👍 everyone started somewhere, hope you can get your code to compile and that the library is working the way it should :)

@BrandonRaeder
Copy link
Author

Oh its working! I believe as time progresses though, for my application, I need the heart rate to start dropping if no new signal was received.

https://ibb.co/tpGyg4S

@BrandonRaeder
Copy link
Author

Not sure if that would make sense though based on how the library is processing the data. Your library is taking the data I am give it and only measuring what It can measure, statically. And if no new signal comes in, than bpm can't really change.

@eripe970
Copy link
Owner

Maybe look at a window of like 10-20 seconds and calculate the heart-rate in that, an example when I did that from a mendi.io device, https://twitter.com/lazyloading/status/1403336825213751300?s=20&t=pQdh70MMCzdb6OA-1SACAQ

(that code is not open source,).

@BrandonRaeder
Copy link
Author

Eric... Some time has passed and I am learning more everyday:) If you ever want to collaborate on a project let me know!

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

No branches or pull requests

2 participants