Skip to content

Commit 82c2abf

Browse files
committed
chore: clean-up
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: na - task: lint_repl_help status: passed - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: passed - task: lint_c_examples status: passed - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: passed - task: lint_license_headers status: passed ---
1 parent 79fe4bc commit 82c2abf

File tree

8 files changed

+20
-29
lines changed

8 files changed

+20
-29
lines changed

lib/node_modules/@stdlib/blas/ext/base/drss/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,8 @@ var Float64Array = require( '@stdlib/array/float64' );
8181
var x = new Float64Array( [ 1.0, 2.0, 2.0, -7.0, -2.0, 3.0, 4.0, 2.0 ] );
8282
var y = new Float64Array( [ 2.0, 1.0, 2.0, 1.0, -2.0, 2.0, 3.0, 4.0 ] );
8383

84-
var z = drss( x.length, x, 1, y, 1 );
85-
// returns 72.0
84+
var z = drss( 4, x, 2, y, 2 );
85+
// returns 2.0
8686
```
8787

8888
Note that indexing is relative to the first index. To introduce an offset, use [`typed array`][mdn-typed-array] views.
@@ -104,7 +104,7 @@ var z = drss( 4, x1, 2, y1, 2 );
104104

105105
#### drss.ndarray( N, x, strideX, offsetX, y, strideY, offsetY )
106106

107-
Computes the [residual sum of squares][wikipedia-residual-sum-of-squares] of two double-precision floating-point strided arrays and alternative indexing semantics.
107+
Computes the [residual sum of squares][wikipedia-residual-sum-of-squares] of two double-precision floating-point strided arrays using alternative indexing semantics.
108108

109109
```javascript
110110
var Float64Array = require( '@stdlib/array/float64' );
@@ -230,13 +230,13 @@ double stdlib_strided_drss( const CBLAS_INT N, const double *X, const CBLAS_INT
230230

231231
<!--lint enable maximum-heading-length-->
232232

233-
Computes the [residual sum of squares][wikipedia-residual-sum-of-squares] of two double-precision floating-point strided arrays and alternative indexing semantics.
233+
Computes the [residual sum of squares][wikipedia-residual-sum-of-squares] of two double-precision floating-point strided arrays using alternative indexing semantics.
234234

235235
```c
236236
const double x[] = { 1.0, -2.0, 2.0 };
237237
const double y[] = { 1.0, 1.0, -4.0 };
238238

239-
double v = stdlib_strided_drss_ndarray( 3, x, 1, 0, 1, 0 );
239+
double v = stdlib_strided_drss_ndarray( 3, x, 1, 0, y, 1, 0 );
240240
// returns 45.0
241241
```
242242

lib/node_modules/@stdlib/blas/ext/base/drss/docs/repl.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858

5959
{{alias}}.ndarray( N, x, strideX, offsetX, y, strideY, offsetY )
6060
Computes the residual sum of squares of two double-precision floating-point
61-
strided arrays and alternative indexing semantics.
61+
strided arrays using alternative indexing semantics.
6262

6363
While typed array views mandate a view offset based on the underlying
6464
buffer, the offset parameters support indexing semantics based on starting

lib/node_modules/@stdlib/blas/ext/base/drss/docs/types/index.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ interface Routine {
4444
( N: number, x: Float64Array, strideX: number, y: Float64Array, strideY: number ): number;
4545

4646
/**
47-
* Computes the residual sum of squares of two double-precision floating-point strided arrays and alternative indexing semantics.
47+
* Computes the residual sum of squares of two double-precision floating-point strided arrays using alternative indexing semantics.
4848
*
4949
* @param N - number of indexed elements
5050
* @param x - first input array
@@ -68,7 +68,7 @@ interface Routine {
6868
}
6969

7070
/**
71-
* Compute the residual sum of squares of two double-precision floating-point strided arrays.
71+
* Computes the residual sum of squares of two double-precision floating-point strided arrays.
7272
*
7373
* @param N - number of indexed elements
7474
* @param x - first input array

lib/node_modules/@stdlib/blas/ext/base/drss/examples/c/example.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ int main( void ) {
3131
const int strideX = 1;
3232
const int strideY = 1;
3333

34-
// Compute the square root of the residual sum of squares of `x` and `y`:
34+
// Compute the residual sum of squares of `x` and `y`:
3535
double d = stdlib_strided_drss( N, x, strideX, y, strideY );
3636

3737
// Print the result:
@@ -41,7 +41,7 @@ int main( void ) {
4141
const int offsetX = 1;
4242
const int offsetY = 1;
4343

44-
// Compute the square root of the residual sum of squares of `x` and `y` with offsets:
44+
// Compute the residual sum of squares of `x` and `y` with offsets:
4545
d = stdlib_strided_drss_ndarray( N, x, strideX, offsetX, y, strideY, offsetY );
4646

4747
// Print the result:

lib/node_modules/@stdlib/blas/ext/base/drss/include/stdlib/blas/ext/base/drss.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,12 @@ extern "C" {
3131
/**
3232
* Computes the residual sum of squares of two double-precision floating-point strided arrays.
3333
*/
34-
double API_SUFFIX( stdlib_strided_drss )( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const double *Y, const CBLAS_INT strideY );
34+
double API_SUFFIX(stdlib_strided_drss)( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const double *Y, const CBLAS_INT strideY );
3535

3636
/**
37-
* Computes the residual sum of squares of two double-precision floating-point strided arrays and alternative indexing semantics.
37+
* Computes the residual sum of squares of two double-precision floating-point strided arrays using alternative indexing semantics.
3838
*/
39-
double API_SUFFIX( stdlib_strided_drss_ndarray )( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const CBLAS_INT offsetX, const double *Y, const CBLAS_INT strideY, const CBLAS_INT offsetY );
39+
double API_SUFFIX(stdlib_strided_drss_ndarray)( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const CBLAS_INT offsetX, const double *Y, const CBLAS_INT strideY, const CBLAS_INT offsetY );
4040

4141
#ifdef __cplusplus
4242
}

lib/node_modules/@stdlib/blas/ext/base/drss/manifest.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@
3939
"libpath": [],
4040
"dependencies": [
4141
"@stdlib/blas/base/shared",
42-
"@stdlib/strided/base/stride2offset",
4342
"@stdlib/blas/ext/base/drssbl",
4443
"@stdlib/napi/export",
4544
"@stdlib/napi/argv",
@@ -61,7 +60,6 @@
6160
"libpath": [],
6261
"dependencies": [
6362
"@stdlib/blas/base/shared",
64-
"@stdlib/strided/base/stride2offset",
6563
"@stdlib/blas/ext/base/drssbl"
6664
]
6765
},
@@ -78,7 +76,6 @@
7876
"libpath": [],
7977
"dependencies": [
8078
"@stdlib/blas/base/shared",
81-
"@stdlib/strided/base/stride2offset",
8279
"@stdlib/blas/ext/base/drssbl"
8380
]
8481
},
@@ -95,7 +92,6 @@
9592
"libpath": [],
9693
"dependencies": [
9794
"@stdlib/blas/base/shared",
98-
"@stdlib/strided/base/stride2offset",
9995
"@stdlib/blas/ext/base/drssbl"
10096
]
10197
}

lib/node_modules/@stdlib/blas/ext/base/drss/src/addon.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ static napi_value addon( napi_env env, napi_callback_info info ) {
3939
STDLIB_NAPI_ARGV_INT64( env, strideY, argv, 4 );
4040
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
4141
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 3 );
42-
STDLIB_NAPI_CREATE_DOUBLE( env, API_SUFFIX( stdlib_strided_drss )( N, X, strideX, Y, strideY ), v );
42+
STDLIB_NAPI_CREATE_DOUBLE( env, API_SUFFIX(stdlib_strided_drss)( N, X, strideX, Y, strideY ), v );
4343
return v;
4444
}
4545

@@ -59,7 +59,7 @@ static napi_value addon_method( napi_env env, napi_callback_info info ) {
5959
STDLIB_NAPI_ARGV_INT64( env, offsetY, argv, 6 );
6060
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, X, N, strideX, argv, 1 );
6161
STDLIB_NAPI_ARGV_STRIDED_FLOAT64ARRAY( env, Y, N, strideY, argv, 4 );
62-
STDLIB_NAPI_CREATE_DOUBLE( env, API_SUFFIX( stdlib_strided_drss_ndarray )( N, X, strideX, offsetX, Y, strideY, offsetY ), v );
62+
STDLIB_NAPI_CREATE_DOUBLE( env, API_SUFFIX(stdlib_strided_drss_ndarray)( N, X, strideX, offsetX, Y, strideY, offsetY ), v );
6363
return v;
6464
}
6565

lib/node_modules/@stdlib/blas/ext/base/drss/src/main.c

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,6 @@
1919
#include "stdlib/blas/ext/base/drss.h"
2020
#include "stdlib/blas/ext/base/drssbl.h"
2121
#include "stdlib/blas/base/shared.h"
22-
#include "stdlib/strided/base/stride2offset.h"
23-
#include <stdbool.h>
24-
2522

2623
/**
2724
* Computes the residual sum of squares of two double-precision floating-point strided arrays.
@@ -33,14 +30,12 @@
3330
* @param strideY stride length of `Y`
3431
* @return output value
3532
*/
36-
double API_SUFFIX( stdlib_strided_drss )( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const double *Y, const CBLAS_INT strideY ) {
37-
const CBLAS_INT ox = stdlib_strided_stride2offset( N, strideX );
38-
const CBLAS_INT oy = stdlib_strided_stride2offset( N, strideY );
39-
return API_SUFFIX( stdlib_strided_drss_ndarray )( N, X, strideX, ox, Y, strideY, oy );
33+
double API_SUFFIX(stdlib_strided_drss)( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const double *Y, const CBLAS_INT strideY ) {
34+
return API_SUFFIX(stdlib_strided_drssbl)( N, X, strideX, Y, strideY );
4035
}
4136

4237
/**
43-
* Computes the residual sum of squares of two double-precision floating-point strided arrays and alternative indexing semantics.
38+
* Computes the residual sum of squares of two double-precision floating-point strided arrays using alternative indexing semantics.
4439
*
4540
* @param N number of indexed elements
4641
* @param X first input array
@@ -51,6 +46,6 @@ double API_SUFFIX( stdlib_strided_drss )( const CBLAS_INT N, const double *X, co
5146
* @param offsetY starting index for `Y`
5247
* @return output value
5348
*/
54-
double API_SUFFIX( stdlib_strided_drss_ndarray )( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const CBLAS_INT offsetX, const double *Y, const CBLAS_INT strideY, const CBLAS_INT offsetY ) {
55-
return stdlib_strided_drssbl_ndarray( N, X, strideX, offsetX, Y, strideY, offsetY );
49+
double API_SUFFIX(stdlib_strided_drss_ndarray)( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const CBLAS_INT offsetX, const double *Y, const CBLAS_INT strideY, const CBLAS_INT offsetY ) {
50+
return API_SUFFIX(stdlib_strided_drssbl_ndarray)( N, X, strideX, offsetX, Y, strideY, offsetY );
5651
}

0 commit comments

Comments
 (0)