IndexError when plotting annotations out of range
Personne n'a encore pris cette issue.
- Langage dominant
- Jupyter Notebook
- Étoiles
- 853
- Forks
- 322
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
If you pass annotations to plot_items or plot_wfdb that are before the start or after the end of the supplied signals, it will give an error
Exception: IndexError: try setting shift_samps=True in the "rdann" function?
The error message has a valid point, in that if you load a subset using sampfrom then the default behavior of rdrecord and rdann is different, which can be confusing.
Still, it's quite possible to load annotations that are outside the time range of the signals you're plotting. In such a case it's often desirable to either:
-
hide all annotations that occur before/after the signal time range
-
plot the annotations anyway (with a y-value of zero), and extend the horizontal range of the plot (or maybe not)
So it'd be nice to have one or both of these behaviors as an option at least. Not sure what the default for plot_wfdb should be.
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Piste de recherche
Commencez par les points d’entrée plot_items et plot_wfdb et reproduisez l’IndexError avec des annotations situées en dehors de la plage du signal fourni. Comparez le comportement demandé entre masquer et tracer, puis décidez du fonctionnement par défaut de plot_wfdb. Le travail est terminé lorsque le comportement choisi est exposé sous forme d’option et que les annotations hors plage ne provoquent plus l’erreur signalée.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- python
- Domaine
- data-visualization
- Type d'issue
- Fonctionnalité
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 38/100