Skip to content

Commit ecb0cf1

Browse files
committed
bench: fix value range
1 parent 446b4cb commit ecb0cf1

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • lib/node_modules/@stdlib/ndarray/sub2ind/benchmark

lib/node_modules/@stdlib/ndarray/sub2ind/benchmark/benchmark.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ bench( pkg+':mode=normalize', function benchmark( b ) {
292292

293293
b.tic();
294294
for ( i = 0; i < b.iterations; i++ ) {
295-
s2 = floor( randu()*2000.0 ) - 1000.0;
295+
s2 = floor( randu()*20.0 ) - 10.0;
296296
out = sub2ind( shape, s0, s1, s2, opts );
297297
if ( out !== out ) {
298298
b.fail( 'should not return NaN' );
@@ -327,7 +327,7 @@ bench( pkg+':mode=[normalize]', function benchmark( b ) {
327327

328328
b.tic();
329329
for ( i = 0; i < b.iterations; i++ ) {
330-
s2 = floor( randu()*2000.0 ) - 1000.0;
330+
s2 = floor( randu()*20.0 ) - 10.0;
331331
out = sub2ind( shape, s0, s1, s2, opts );
332332
if ( out !== out ) {
333333
b.fail( 'should not return NaN' );

0 commit comments

Comments
 (0)