Skip to content

Commit bf97e06

Browse files
committed
replace empty with zeros. ref #18
1 parent cc50262 commit bf97e06

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

wfdb/_rdann.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -70,13 +70,15 @@ def rdann(recordname, annot, sampfrom=0, sampto=[], anndisp=1):
7070

7171
# Allocate for the maximum possible number of annotations contained in the
7272
# file.
73-
annsamp = np.empty(filebytes.shape[0])
74-
anntype = np.empty(filebytes.shape[0])
75-
subtype = np.empty(filebytes.shape[0])
76-
chan = np.empty(filebytes.shape[0])
77-
num = np.empty(filebytes.shape[0])
73+
annsamp = np.zeros(filebytes.shape[0])
74+
anntype = np.zeros(filebytes.shape[0])
75+
subtype = np.zeros(filebytes.shape[0])
76+
chan = np.zeros(filebytes.shape[0])
77+
num = np.zeros(filebytes.shape[0])
7878
aux = [''] * filebytes.shape[0]
7979

80+
print subtype
81+
8082
# Annotation index, the number of annotations processed. Not to be
8183
# comfused with the 'num' field of an annotation.
8284
ai = 0

0 commit comments

Comments
 (0)