FIX: number of peaks returned from feature.corner_peaks

corner_peaks accepted a num_peaks argument, but the call
to peak_local_max inside the function used np.inf instead
of the value of this keyword argument, leading to an unbounded
number of peaks being returned.
TEST: added test for num_peaks kwarg in peak_local_max.
FIX: move corner detection outside loop in test_num_peaks.
FIX: changed xrange to range so Python 3 works.
Merge pull request #467 from malcolmreynolds/fix-num-peaks-typo

FIX: number of peaks returned from feature.corner_peaks