I have noticed that you usually try to handle manually common errors or warnings like:
empty series
file does not exist
etc
I would recommend to let the standard error/warning handlers developed in python or other packages to do the thing for us. In general, when they report an error/warrning, they also include file (.py), the line of code triggering the error and a detailed enough description of the problem. I have noticed that the error messages written in the vital_sqi package are sometimes not informative enough and we could save us some work too! (see example below)
For this second example, it is very difficult to know where the "name 'isscalar' is not defined" is being raised and why. In the vital_sqi/sqi/standard_sqi.py function msq_sqi you need to include from vital_sqi.common import PeakDetector. Please do it inside the function, because it is only needed for that one I think. Then when using the msq_sqi the error happens (see below)
Hi guys,
I have noticed that you usually try to handle manually common errors or warnings like:
I would recommend to let the standard error/warning handlers developed in python or other packages to do the thing for us. In general, when they report an error/warrning, they also include file (.py), the line of code triggering the error and a detailed enough description of the problem. I have noticed that the error messages written in the vital_sqi package are sometimes not informative enough and we could save us some work too! (see example below)
For this second example, it is very difficult to know where the "name 'isscalar' is not defined" is being raised and why. In the vital_sqi/sqi/standard_sqi.py function msq_sqi you need to include from vital_sqi.common import PeakDetector. Please do it inside the function, because it is only needed for that one I think. Then when using the msq_sqi the error happens (see below)