Skip to content

Commit 3e8ab11

Browse files
bug-fix: Pandas set indexing error
Current version of Pandas will throw the following error when indexing using a set. TypeError: Passing a set as an indexer is not supported. Use a list instead.
1 parent 870d792 commit 3e8ab11

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

wfdb/io/annotation.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1352,7 +1352,7 @@ def get_contained_labels(self, inplace=True):
13521352
else:
13531353
raise Exception("No annotation labels contained in object")
13541354

1355-
contained_labels = label_map.loc[index_vals, :]
1355+
contained_labels = label_map.loc[list(index_vals), :]
13561356

13571357
# Add the counts
13581358
for i in range(len(counts[0])):

0 commit comments

Comments
 (0)