Skip to content

Commit af84c76

Browse files
committed
Simplified the index raveling
1 parent 2fcf35d commit af84c76

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pycorr/twopoint_jackknife.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ def label(self, positions, position_type=None):
214214
if not np.all((tmp >= 0) & (tmp < len(edge) - 1)):
215215
raise ValueError('Some input positions outside of bounding box')
216216
ii.append(tmp)
217-
return np.ravel_multi_index(tuple(ii), tuple(len(edge) - 1 for edge in self.edges), mode='raise', order='C')
217+
return np.ravel_multi_index(tuple(ii), self.nsamples, mode='raise', order='C')
218218

219219

220220
class KMeansSubsampler(BaseSubsampler):

0 commit comments

Comments
 (0)