@stdlib/strided-base 0.2.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NOTICE +1 -1
- package/README.md +20 -5
- package/dist/index.js +1 -1
- package/dist/index.js.map +2 -2
- package/docs/types/index.d.ts +212 -51
- package/lib/index.js +45 -0
- package/package.json +48 -43
package/NOTICE
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Copyright (c) 2016-
|
|
1
|
+
Copyright (c) 2016-2026 The Stdlib Authors.
|
package/README.md
CHANGED
|
@@ -95,6 +95,8 @@ The following functions are currently exported:
|
|
|
95
95
|
- <span class="signature">[`offsetView( x, offset )`][@stdlib/strided/base/offset-view]</span><span class="delimiter">: </span><span class="description">return a typed array view having the same data type as a provided input typed array and starting at a specified index offset.</span>
|
|
96
96
|
- <span class="signature">[`quaternary( arrays, shape, strides, fcn )`][@stdlib/strided/base/quaternary]</span><span class="delimiter">: </span><span class="description">apply a quaternary callback to strided input array elements and assign results to elements in a strided output array.</span>
|
|
97
97
|
- <span class="signature">[`quinary( arrays, shape, strides, fcn )`][@stdlib/strided/base/quinary]</span><span class="delimiter">: </span><span class="description">apply a quinary callback to strided input array elements and assign results to elements in a strided output array.</span>
|
|
98
|
+
- <span class="signature">[`readDataView( N, view, strideView, out, strideOut, littleEndian )`][@stdlib/strided/base/read-dataview]</span><span class="delimiter">: </span><span class="description">copy elements from an input strided `DataView` to elements in an output strided array.</span>
|
|
99
|
+
- <span class="signature">[`reinterpretBoolean( x, offset )`][@stdlib/strided/base/reinterpret-boolean]</span><span class="delimiter">: </span><span class="description">reinterpret a `BooleanArray` as a `Uint8Array`.</span>
|
|
98
100
|
- <span class="signature">[`reinterpretComplex( x, offset )`][@stdlib/strided/base/reinterpret-complex]</span><span class="delimiter">: </span><span class="description">reinterpret a complex-valued floating-point array as a real-valued floating-point array having the same precision.</span>
|
|
99
101
|
- <span class="signature">[`reinterpretComplex128( x, offset )`][@stdlib/strided/base/reinterpret-complex128]</span><span class="delimiter">: </span><span class="description">reinterpret a `Complex128Array` as a `Float64Array`.</span>
|
|
100
102
|
- <span class="signature">[`reinterpretComplex64( x, offset )`][@stdlib/strided/base/reinterpret-complex64]</span><span class="delimiter">: </span><span class="description">reinterpret a `Complex64Array` as a `Float32Array`.</span>
|
|
@@ -102,12 +104,15 @@ The following functions are currently exported:
|
|
|
102
104
|
- <span class="signature">[`smap2( N, x, strideX, y, strideY, z, strideZ, fcn )`][@stdlib/strided/base/smap2]</span><span class="delimiter">: </span><span class="description">apply a binary function to single-precision floating-point strided input arrays and assign results to a single-precision floating-point strided output array.</span>
|
|
103
105
|
- <span class="signature">[`smskmap( N, x, strideX, mask, strideMask, y, strideY, fcn )`][@stdlib/strided/base/smskmap]</span><span class="delimiter">: </span><span class="description">apply a unary function to a single-precision floating-point strided input array according to a strided mask array and assign results to a single-precision floating-point strided output array.</span>
|
|
104
106
|
- <span class="signature">[`smskmap2( N, x, strideX, y, strideY, mask, strideMask, z, strideZ, fcn )`][@stdlib/strided/base/smskmap2]</span><span class="delimiter">: </span><span class="description">apply a binary function to single-precision floating-point strided input arrays according to a strided mask array and assign results to a single-precision floating-point strided output array.</span>
|
|
107
|
+
- <span class="signature">[`stride2offset( N, stride )`][@stdlib/strided/base/stride2offset]</span><span class="delimiter">: </span><span class="description">determine the index offset which specifies the location of the first indexed value in a strided array.</span>
|
|
108
|
+
- <span class="signature">[`strided2object( N, x, stride, offset )`][@stdlib/strided/base/strided2object]</span><span class="delimiter">: </span><span class="description">convert a strided array and associated metadata to an object likely to have the same "shape".</span>
|
|
105
109
|
- <span class="signature">[`ternary( arrays, shape, strides, fcn )`][@stdlib/strided/base/ternary]</span><span class="delimiter">: </span><span class="description">apply a ternary callback to strided input array elements and assign results to elements in a strided output array.</span>
|
|
106
110
|
- <span class="signature">[`unaryAddonDispatch( addon, fallback )`][@stdlib/strided/base/unary-addon-dispatch]</span><span class="delimiter">: </span><span class="description">dispatch to a native add-on applying a unary function to an input strided array.</span>
|
|
107
111
|
- <span class="signature">[`unaryBy( arrays, shape, strides, fcn, clbk[, thisArg] )`][@stdlib/strided/base/unary-by]</span><span class="delimiter">: </span><span class="description">apply a unary function to each element retrieved from a strided input array according to a callback function and assign results to a strided output array.</span>
|
|
108
112
|
- <span class="signature">[`unaryDtypeSignatures( dtypes1, dtypes2[, options] )`][@stdlib/strided/base/unary-dtype-signatures]</span><span class="delimiter">: </span><span class="description">generate a list of unary interface signatures from strided array data types.</span>
|
|
109
113
|
- <span class="signature">[`unarySignatureCallbacks( table, signatures )`][@stdlib/strided/base/unary-signature-callbacks]</span><span class="delimiter">: </span><span class="description">assign callbacks to unary interfaces according to type promotion rules.</span>
|
|
110
114
|
- <span class="signature">[`unary( arrays, shape, strides, fcn )`][@stdlib/strided/base/unary]</span><span class="delimiter">: </span><span class="description">apply a unary callback to elements in a strided input array and assign results to elements in a strided output array.</span>
|
|
115
|
+
- <span class="signature">[`writeDataView( N, x, strideX, view, strideView, littleEndian )`][@stdlib/strided/base/write-dataview]</span><span class="delimiter">: </span><span class="description">copy elements from an input strided array to elements in a strided `DataView`.</span>
|
|
111
116
|
- <span class="signature">[`zmap( N, x, strideX, y, strideY, fcn )`][@stdlib/strided/base/zmap]</span><span class="delimiter">: </span><span class="description">apply a unary function to a double-precision floating-point strided input array and assign results to a double-precision floating-point strided output array.</span>
|
|
112
117
|
|
|
113
118
|
</div>
|
|
@@ -171,7 +176,7 @@ See [LICENSE][stdlib-license].
|
|
|
171
176
|
|
|
172
177
|
## Copyright
|
|
173
178
|
|
|
174
|
-
Copyright © 2016-
|
|
179
|
+
Copyright © 2016-2026. The Stdlib [Authors][stdlib-authors].
|
|
175
180
|
|
|
176
181
|
</section>
|
|
177
182
|
|
|
@@ -184,8 +189,8 @@ Copyright © 2016-2024. The Stdlib [Authors][stdlib-authors].
|
|
|
184
189
|
[npm-image]: http://img.shields.io/npm/v/@stdlib/strided-base.svg
|
|
185
190
|
[npm-url]: https://npmjs.org/package/@stdlib/strided-base
|
|
186
191
|
|
|
187
|
-
[test-image]: https://github.com/stdlib-js/strided-base/actions/workflows/test.yml/badge.svg?branch=v0.
|
|
188
|
-
[test-url]: https://github.com/stdlib-js/strided-base/actions/workflows/test.yml?query=branch:v0.
|
|
192
|
+
[test-image]: https://github.com/stdlib-js/strided-base/actions/workflows/test.yml/badge.svg?branch=v0.4.0
|
|
193
|
+
[test-url]: https://github.com/stdlib-js/strided-base/actions/workflows/test.yml?query=branch:v0.4.0
|
|
189
194
|
|
|
190
195
|
[coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/strided-base/main.svg
|
|
191
196
|
[coverage-url]: https://codecov.io/github/stdlib-js/strided-base?branch=main
|
|
@@ -197,8 +202,8 @@ Copyright © 2016-2024. The Stdlib [Authors][stdlib-authors].
|
|
|
197
202
|
|
|
198
203
|
-->
|
|
199
204
|
|
|
200
|
-
[chat-image]: https://img.shields.io/
|
|
201
|
-
[chat-url]: https://
|
|
205
|
+
[chat-image]: https://img.shields.io/badge/zulip-join_chat-brightgreen.svg
|
|
206
|
+
[chat-url]: https://stdlib.zulipchat.com
|
|
202
207
|
|
|
203
208
|
[stdlib]: https://github.com/stdlib-js/stdlib
|
|
204
209
|
|
|
@@ -273,6 +278,10 @@ Copyright © 2016-2024. The Stdlib [Authors][stdlib-authors].
|
|
|
273
278
|
|
|
274
279
|
[@stdlib/strided/base/quinary]: https://www.npmjs.com/package/@stdlib/strided-base-quinary
|
|
275
280
|
|
|
281
|
+
[@stdlib/strided/base/read-dataview]: https://www.npmjs.com/package/@stdlib/strided-base-read-dataview
|
|
282
|
+
|
|
283
|
+
[@stdlib/strided/base/reinterpret-boolean]: https://www.npmjs.com/package/@stdlib/strided-base-reinterpret-boolean
|
|
284
|
+
|
|
276
285
|
[@stdlib/strided/base/reinterpret-complex]: https://www.npmjs.com/package/@stdlib/strided-base-reinterpret-complex
|
|
277
286
|
|
|
278
287
|
[@stdlib/strided/base/reinterpret-complex128]: https://www.npmjs.com/package/@stdlib/strided-base-reinterpret-complex128
|
|
@@ -287,6 +296,10 @@ Copyright © 2016-2024. The Stdlib [Authors][stdlib-authors].
|
|
|
287
296
|
|
|
288
297
|
[@stdlib/strided/base/smskmap2]: https://www.npmjs.com/package/@stdlib/strided-base-smskmap2
|
|
289
298
|
|
|
299
|
+
[@stdlib/strided/base/stride2offset]: https://www.npmjs.com/package/@stdlib/strided-base-stride2offset
|
|
300
|
+
|
|
301
|
+
[@stdlib/strided/base/strided2object]: https://www.npmjs.com/package/@stdlib/strided-base-strided2object
|
|
302
|
+
|
|
290
303
|
[@stdlib/strided/base/ternary]: https://www.npmjs.com/package/@stdlib/strided-base-ternary
|
|
291
304
|
|
|
292
305
|
[@stdlib/strided/base/unary-addon-dispatch]: https://www.npmjs.com/package/@stdlib/strided-base-unary-addon-dispatch
|
|
@@ -299,6 +312,8 @@ Copyright © 2016-2024. The Stdlib [Authors][stdlib-authors].
|
|
|
299
312
|
|
|
300
313
|
[@stdlib/strided/base/unary]: https://www.npmjs.com/package/@stdlib/strided-base-unary
|
|
301
314
|
|
|
315
|
+
[@stdlib/strided/base/write-dataview]: https://www.npmjs.com/package/@stdlib/strided-base-write-dataview
|
|
316
|
+
|
|
302
317
|
[@stdlib/strided/base/zmap]: https://www.npmjs.com/package/@stdlib/strided-base-zmap
|
|
303
318
|
|
|
304
319
|
<!-- </toc-links> -->
|
package/dist/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var r=require('@stdlib/utils-define-read-only-property/dist'),e={};r(e,"binary",require('@stdlib/strided-base-binary/dist'));r(e,"binaryAddonDispatch",require('@stdlib/strided-base-binary-addon-dispatch/dist'));r(e,"binaryDtypeSignatures",require('@stdlib/strided-base-binary-dtype-signatures/dist'));r(e,"binarySignatureCallbacks",require('@stdlib/strided-base-binary-signature-callbacks/dist'));r(e,"cmap",require('@stdlib/strided-base-cmap/dist'));r(e,"dmap",require('@stdlib/strided-base-dmap/dist'));r(e,"dmap2",require('@stdlib/strided-base-dmap2/dist'));r(e,"dmskmap",require('@stdlib/strided-base-dmskmap/dist'));r(e,"dmskmap2",require('@stdlib/strided-base-dmskmap2/dist'));r(e,"dtypeEnum2Str",require('@stdlib/strided-base-dtype-enum2str/dist'));r(e,"dtypeResolveEnum",require('@stdlib/strided-base-dtype-resolve-enum/dist'));r(e,"dtypeResolveStr",require('@stdlib/strided-base-dtype-resolve-str/dist'));r(e,"dtypeStr2Enum",require('@stdlib/strided-base-dtype-str2enum/dist'));r(e,"mapBy",require('@stdlib/strided-base-map-by/dist'));r(e,"mapBy2",require('@stdlib/strided-base-map-by2/dist'));r(e,"maxViewBufferIndex",require('@stdlib/strided-base-max-view-buffer-index/dist'));r(e,"metaDataProps",require('@stdlib/strided-base-meta-data-props/dist'));r(e,"minViewBufferIndex",require('@stdlib/strided-base-min-view-buffer-index/dist'));r(e,"mskunary",require('@stdlib/strided-base-mskunary/dist'));r(e,"mskunaryAddonDispatch",require('@stdlib/strided-base-mskunary-addon-dispatch/dist'));r(e,"mskunaryDtypeSignatures",require('@stdlib/strided-base-mskunary-dtype-signatures/dist'));r(e,"mskunarySignatureCallbacks",require('@stdlib/strided-base-mskunary-signature-callbacks/dist'));r(e,"nullary",require('@stdlib/strided-base-nullary/dist'));r(e,"nullaryAddonDispatch",require('@stdlib/strided-base-nullary-addon-dispatch/dist'));r(e,"offsetView",require('@stdlib/strided-base-offset-view/dist'));r(e,"quaternary",require('@stdlib/strided-base-quaternary/dist'));r(e,"quinary",require('@stdlib/strided-base-quinary/dist'));r(e,"readDataView",require('@stdlib/strided-base-read-dataview/dist'));r(e,"reinterpretBoolean",require('@stdlib/strided-base-reinterpret-boolean/dist'));r(e,"reinterpretComplex",require('@stdlib/strided-base-reinterpret-complex/dist'));r(e,"reinterpretComplex64",require('@stdlib/strided-base-reinterpret-complex64/dist'));r(e,"reinterpretComplex128",require('@stdlib/strided-base-reinterpret-complex128/dist'));r(e,"smap",require('@stdlib/strided-base-smap/dist'));r(e,"smap2",require('@stdlib/strided-base-smap2/dist'));r(e,"smskmap",require('@stdlib/strided-base-smskmap/dist'));r(e,"smskmap2",require('@stdlib/strided-base-smskmap2/dist'));r(e,"stride2offset",require('@stdlib/strided-base-stride2offset/dist'));r(e,"strided2object",require('@stdlib/strided-base-strided2object/dist'));r(e,"ternary",require('@stdlib/strided-base-ternary/dist'));r(e,"unary",require('@stdlib/strided-base-unary/dist'));r(e,"unaryAddonDispatch",require('@stdlib/strided-base-unary-addon-dispatch/dist'));r(e,"unaryBy",require('@stdlib/strided-base-unary-by/dist'));r(e,"unaryDtypeSignatures",require('@stdlib/strided-base-unary-dtype-signatures/dist'));r(e,"unarySignatureCallbacks",require('@stdlib/strided-base-unary-signature-callbacks/dist'));r(e,"writeDataView",require('@stdlib/strided-base-write-dataview/dist'));r(e,"zmap",require('@stdlib/strided-base-zmap/dist'));module.exports=e;
|
|
2
2
|
/** @license Apache-2.0 */
|
|
3
3
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../lib/index.js"],
|
|
4
|
-
"sourcesContent": ["/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/*\n* When adding modules to the namespace, ensure that they are added in alphabetical order according to module name.\n*/\n\n/*\n* The following modules are intentionally not exported: function-object\n*/\n\n// MODULES //\n\nvar setReadOnly = require( '@stdlib/utils-define-read-only-property' );\n\n\n// MAIN //\n\n/**\n* Top-level namespace.\n*\n* @namespace ns\n*/\nvar ns = {};\n\n/**\n* @name binary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary}\n*/\nsetReadOnly( ns, 'binary', require( '@stdlib/strided-base-binary' ) );\n\n/**\n* @name binaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary-addon-dispatch}\n*/\nsetReadOnly( ns, 'binaryAddonDispatch', require( '@stdlib/strided-base-binary-addon-dispatch' ) );\n\n/**\n* @name binaryDtypeSignatures\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary-dtype-signatures}\n*/\nsetReadOnly( ns, 'binaryDtypeSignatures', require( '@stdlib/strided-base-binary-dtype-signatures' ) );\n\n/**\n* @name binarySignatureCallbacks\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary-signature-callbacks}\n*/\nsetReadOnly( ns, 'binarySignatureCallbacks', require( '@stdlib/strided-base-binary-signature-callbacks' ) );\n\n/**\n* @name cmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/cmap}\n*/\nsetReadOnly( ns, 'cmap', require( '@stdlib/strided-base-cmap' ) );\n\n/**\n* @name dmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmap}\n*/\nsetReadOnly( ns, 'dmap', require( '@stdlib/strided-base-dmap' ) );\n\n/**\n* @name dmap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmap2}\n*/\nsetReadOnly( ns, 'dmap2', require( '@stdlib/strided-base-dmap2' ) );\n\n/**\n* @name dmskmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmskmap}\n*/\nsetReadOnly( ns, 'dmskmap', require( '@stdlib/strided-base-dmskmap' ) );\n\n/**\n* @name dmskmap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmskmap2}\n*/\nsetReadOnly( ns, 'dmskmap2', require( '@stdlib/strided-base-dmskmap2' ) );\n\n/**\n* @name dtypeEnum2Str\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-enum2str}\n*/\nsetReadOnly( ns, 'dtypeEnum2Str', require( '@stdlib/strided-base-dtype-enum2str' ) );\n\n/**\n* @name dtypeResolveEnum\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-resolve-enum}\n*/\nsetReadOnly( ns, 'dtypeResolveEnum', require( '@stdlib/strided-base-dtype-resolve-enum' ) );\n\n/**\n* @name dtypeResolveStr\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-resolve-str}\n*/\nsetReadOnly( ns, 'dtypeResolveStr', require( '@stdlib/strided-base-dtype-resolve-str' ) );\n\n/**\n* @name dtypeStr2Enum\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-str2enum}\n*/\nsetReadOnly( ns, 'dtypeStr2Enum', require( '@stdlib/strided-base-dtype-str2enum' ) );\n\n/**\n* @name mapBy\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/map-by}\n*/\nsetReadOnly( ns, 'mapBy', require( '@stdlib/strided-base-map-by' ) );\n\n/**\n* @name mapBy2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/map-by2}\n*/\nsetReadOnly( ns, 'mapBy2', require( '@stdlib/strided-base-map-by2' ) );\n\n/**\n* @name maxViewBufferIndex\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/max-view-buffer-index}\n*/\nsetReadOnly( ns, 'maxViewBufferIndex', require( '@stdlib/strided-base-max-view-buffer-index' ) );\n\n/**\n* @name metaDataProps\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/meta-data-props}\n*/\nsetReadOnly( ns, 'metaDataProps', require( '@stdlib/strided-base-meta-data-props' ) );\n\n/**\n* @name minViewBufferIndex\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/min-view-buffer-index}\n*/\nsetReadOnly( ns, 'minViewBufferIndex', require( '@stdlib/strided-base-min-view-buffer-index' ) );\n\n/**\n* @name mskunary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary}\n*/\nsetReadOnly( ns, 'mskunary', require( '@stdlib/strided-base-mskunary' ) );\n\n/**\n* @name mskunaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary-addon-dispatch}\n*/\nsetReadOnly( ns, 'mskunaryAddonDispatch', require( '@stdlib/strided-base-mskunary-addon-dispatch' ) );\n\n/**\n* @name mskunaryDtypeSignatures\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary-dtype-signatures}\n*/\nsetReadOnly( ns, 'mskunaryDtypeSignatures', require( '@stdlib/strided-base-mskunary-dtype-signatures' ) );\n\n/**\n* @name mskunarySignatureCallbacks\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary-signature-callbacks}\n*/\nsetReadOnly( ns, 'mskunarySignatureCallbacks', require( '@stdlib/strided-base-mskunary-signature-callbacks' ) );\n\n/**\n* @name nullary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/nullary}\n*/\nsetReadOnly( ns, 'nullary', require( '@stdlib/strided-base-nullary' ) );\n\n/**\n* @name nullaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/nullary-addon-dispatch}\n*/\nsetReadOnly( ns, 'nullaryAddonDispatch', require( '@stdlib/strided-base-nullary-addon-dispatch' ) );\n\n/**\n* @name offsetView\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/offset-view}\n*/\nsetReadOnly( ns, 'offsetView', require( '@stdlib/strided-base-offset-view' ) );\n\n/**\n* @name quaternary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/quaternary}\n*/\nsetReadOnly( ns, 'quaternary', require( '@stdlib/strided-base-quaternary' ) );\n\n/**\n* @name quinary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/quinary}\n*/\nsetReadOnly( ns, 'quinary', require( '@stdlib/strided-base-quinary' ) );\n\n/**\n* @name reinterpretComplex\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/reinterpret-complex}\n*/\nsetReadOnly( ns, 'reinterpretComplex', require( '@stdlib/strided-base-reinterpret-complex' ) );\n\n/**\n* @name reinterpretComplex64\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/reinterpret-complex64}\n*/\nsetReadOnly( ns, 'reinterpretComplex64', require( '@stdlib/strided-base-reinterpret-complex64' ) );\n\n/**\n* @name reinterpretComplex128\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/reinterpret-complex128}\n*/\nsetReadOnly( ns, 'reinterpretComplex128', require( '@stdlib/strided-base-reinterpret-complex128' ) );\n\n/**\n* @name smap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smap}\n*/\nsetReadOnly( ns, 'smap', require( '@stdlib/strided-base-smap' ) );\n\n/**\n* @name smap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smap2}\n*/\nsetReadOnly( ns, 'smap2', require( '@stdlib/strided-base-smap2' ) );\n\n/**\n* @name smskmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smskmap}\n*/\nsetReadOnly( ns, 'smskmap', require( '@stdlib/strided-base-smskmap' ) );\n\n/**\n* @name smskmap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smskmap2}\n*/\nsetReadOnly( ns, 'smskmap2', require( '@stdlib/strided-base-smskmap2' ) );\n\n/**\n* @name ternary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/ternary}\n*/\nsetReadOnly( ns, 'ternary', require( '@stdlib/strided-base-ternary' ) );\n\n/**\n* @name unary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary}\n*/\nsetReadOnly( ns, 'unary', require( '@stdlib/strided-base-unary' ) );\n\n/**\n* @name unaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-addon-dispatch}\n*/\nsetReadOnly( ns, 'unaryAddonDispatch', require( '@stdlib/strided-base-unary-addon-dispatch' ) );\n\n/**\n* @name unaryBy\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-by}\n*/\nsetReadOnly( ns, 'unaryBy', require( '@stdlib/strided-base-unary-by' ) );\n\n/**\n* @name unaryDtypeSignatures\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-dtype-signatures}\n*/\nsetReadOnly( ns, 'unaryDtypeSignatures', require( '@stdlib/strided-base-unary-dtype-signatures' ) );\n\n/**\n* @name unarySignatureCallbacks\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-signature-callbacks}\n*/\nsetReadOnly( ns, 'unarySignatureCallbacks', require( '@stdlib/strided-base-unary-signature-callbacks' ) );\n\n/**\n* @name zmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/zmap}\n*/\nsetReadOnly( ns, 'zmap', require( '@stdlib/strided-base-zmap' ) );\n\n\n// EXPORTS //\n\nmodule.exports = ns;\n"],
|
|
5
|
-
"mappings": "aA8BA,IAAIA,EAAc,QAAS,yCAA0C,EAUjEC,EAAK,CAAC,EASVD,EAAaC,EAAI,SAAU,QAAS,6BAA8B,CAAE,EASpED,EAAaC,EAAI,sBAAuB,QAAS,4CAA6C,CAAE,EAShGD,EAAaC,EAAI,wBAAyB,QAAS,8CAA+C,CAAE,EASpGD,EAAaC,EAAI,2BAA4B,QAAS,iDAAkD,CAAE,EAS1GD,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAShED,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAShED,EAAaC,EAAI,QAAS,QAAS,4BAA6B,CAAE,EASlED,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,WAAY,QAAS,+BAAgC,CAAE,EASxED,EAAaC,EAAI,gBAAiB,QAAS,qCAAsC,CAAE,EASnFD,EAAaC,EAAI,mBAAoB,QAAS,yCAA0C,CAAE,EAS1FD,EAAaC,EAAI,kBAAmB,QAAS,wCAAyC,CAAE,EASxFD,EAAaC,EAAI,gBAAiB,QAAS,qCAAsC,CAAE,EASnFD,EAAaC,EAAI,QAAS,QAAS,6BAA8B,CAAE,EASnED,EAAaC,EAAI,SAAU,QAAS,8BAA+B,CAAE,EASrED,EAAaC,EAAI,qBAAsB,QAAS,4CAA6C,CAAE,EAS/FD,EAAaC,EAAI,gBAAiB,QAAS,sCAAuC,CAAE,EASpFD,EAAaC,EAAI,qBAAsB,QAAS,4CAA6C,CAAE,EAS/FD,EAAaC,EAAI,WAAY,QAAS,+BAAgC,CAAE,EASxED,EAAaC,EAAI,wBAAyB,QAAS,8CAA+C,CAAE,EASpGD,EAAaC,EAAI,0BAA2B,QAAS,gDAAiD,CAAE,EASxGD,EAAaC,EAAI,6BAA8B,QAAS,mDAAoD,CAAE,EAS9GD,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,uBAAwB,QAAS,6CAA8C,CAAE,EASlGD,EAAaC,EAAI,aAAc,QAAS,kCAAmC,CAAE,EAS7ED,EAAaC,EAAI,aAAc,QAAS,iCAAkC,CAAE,EAS5ED,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,qBAAsB,QAAS,0CAA2C,CAAE,EAS7FD,EAAaC,EAAI,uBAAwB,QAAS,4CAA6C,CAAE,EASjGD,EAAaC,EAAI,wBAAyB,QAAS,6CAA8C,CAAE,EASnGD,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAShED,EAAaC,EAAI,QAAS,QAAS,4BAA6B,CAAE,EASlED,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,WAAY,QAAS,+BAAgC,CAAE,EASxED,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,QAAS,QAAS,4BAA6B,CAAE,EASlED,EAAaC,EAAI,qBAAsB,QAAS,2CAA4C,CAAE,EAS9FD,EAAaC,EAAI,UAAW,QAAS,+BAAgC,CAAE,EASvED,EAAaC,EAAI,uBAAwB,QAAS,6CAA8C,CAAE,EASlGD,EAAaC,EAAI,0BAA2B,QAAS,gDAAiD,CAAE,EASxGD,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAKhE,OAAO,QAAUA",
|
|
4
|
+
"sourcesContent": ["/**\n* @license Apache-2.0\n*\n* Copyright (c) 2020 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/*\n* When adding modules to the namespace, ensure that they are added in alphabetical order according to module name.\n*/\n\n/*\n* The following modules are intentionally not exported: function-object\n*/\n\n// MODULES //\n\nvar setReadOnly = require( '@stdlib/utils-define-read-only-property' );\n\n\n// MAIN //\n\n/**\n* Top-level namespace.\n*\n* @namespace ns\n*/\nvar ns = {};\n\n/**\n* @name binary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary}\n*/\nsetReadOnly( ns, 'binary', require( '@stdlib/strided-base-binary' ) );\n\n/**\n* @name binaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary-addon-dispatch}\n*/\nsetReadOnly( ns, 'binaryAddonDispatch', require( '@stdlib/strided-base-binary-addon-dispatch' ) );\n\n/**\n* @name binaryDtypeSignatures\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary-dtype-signatures}\n*/\nsetReadOnly( ns, 'binaryDtypeSignatures', require( '@stdlib/strided-base-binary-dtype-signatures' ) );\n\n/**\n* @name binarySignatureCallbacks\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/binary-signature-callbacks}\n*/\nsetReadOnly( ns, 'binarySignatureCallbacks', require( '@stdlib/strided-base-binary-signature-callbacks' ) );\n\n/**\n* @name cmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/cmap}\n*/\nsetReadOnly( ns, 'cmap', require( '@stdlib/strided-base-cmap' ) );\n\n/**\n* @name dmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmap}\n*/\nsetReadOnly( ns, 'dmap', require( '@stdlib/strided-base-dmap' ) );\n\n/**\n* @name dmap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmap2}\n*/\nsetReadOnly( ns, 'dmap2', require( '@stdlib/strided-base-dmap2' ) );\n\n/**\n* @name dmskmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmskmap}\n*/\nsetReadOnly( ns, 'dmskmap', require( '@stdlib/strided-base-dmskmap' ) );\n\n/**\n* @name dmskmap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dmskmap2}\n*/\nsetReadOnly( ns, 'dmskmap2', require( '@stdlib/strided-base-dmskmap2' ) );\n\n/**\n* @name dtypeEnum2Str\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-enum2str}\n*/\nsetReadOnly( ns, 'dtypeEnum2Str', require( '@stdlib/strided-base-dtype-enum2str' ) );\n\n/**\n* @name dtypeResolveEnum\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-resolve-enum}\n*/\nsetReadOnly( ns, 'dtypeResolveEnum', require( '@stdlib/strided-base-dtype-resolve-enum' ) );\n\n/**\n* @name dtypeResolveStr\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-resolve-str}\n*/\nsetReadOnly( ns, 'dtypeResolveStr', require( '@stdlib/strided-base-dtype-resolve-str' ) );\n\n/**\n* @name dtypeStr2Enum\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/dtype-str2enum}\n*/\nsetReadOnly( ns, 'dtypeStr2Enum', require( '@stdlib/strided-base-dtype-str2enum' ) );\n\n/**\n* @name mapBy\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/map-by}\n*/\nsetReadOnly( ns, 'mapBy', require( '@stdlib/strided-base-map-by' ) );\n\n/**\n* @name mapBy2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/map-by2}\n*/\nsetReadOnly( ns, 'mapBy2', require( '@stdlib/strided-base-map-by2' ) );\n\n/**\n* @name maxViewBufferIndex\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/max-view-buffer-index}\n*/\nsetReadOnly( ns, 'maxViewBufferIndex', require( '@stdlib/strided-base-max-view-buffer-index' ) );\n\n/**\n* @name metaDataProps\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/meta-data-props}\n*/\nsetReadOnly( ns, 'metaDataProps', require( '@stdlib/strided-base-meta-data-props' ) );\n\n/**\n* @name minViewBufferIndex\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/min-view-buffer-index}\n*/\nsetReadOnly( ns, 'minViewBufferIndex', require( '@stdlib/strided-base-min-view-buffer-index' ) );\n\n/**\n* @name mskunary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary}\n*/\nsetReadOnly( ns, 'mskunary', require( '@stdlib/strided-base-mskunary' ) );\n\n/**\n* @name mskunaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary-addon-dispatch}\n*/\nsetReadOnly( ns, 'mskunaryAddonDispatch', require( '@stdlib/strided-base-mskunary-addon-dispatch' ) );\n\n/**\n* @name mskunaryDtypeSignatures\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary-dtype-signatures}\n*/\nsetReadOnly( ns, 'mskunaryDtypeSignatures', require( '@stdlib/strided-base-mskunary-dtype-signatures' ) );\n\n/**\n* @name mskunarySignatureCallbacks\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/mskunary-signature-callbacks}\n*/\nsetReadOnly( ns, 'mskunarySignatureCallbacks', require( '@stdlib/strided-base-mskunary-signature-callbacks' ) );\n\n/**\n* @name nullary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/nullary}\n*/\nsetReadOnly( ns, 'nullary', require( '@stdlib/strided-base-nullary' ) );\n\n/**\n* @name nullaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/nullary-addon-dispatch}\n*/\nsetReadOnly( ns, 'nullaryAddonDispatch', require( '@stdlib/strided-base-nullary-addon-dispatch' ) );\n\n/**\n* @name offsetView\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/offset-view}\n*/\nsetReadOnly( ns, 'offsetView', require( '@stdlib/strided-base-offset-view' ) );\n\n/**\n* @name quaternary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/quaternary}\n*/\nsetReadOnly( ns, 'quaternary', require( '@stdlib/strided-base-quaternary' ) );\n\n/**\n* @name quinary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/quinary}\n*/\nsetReadOnly( ns, 'quinary', require( '@stdlib/strided-base-quinary' ) );\n\n/**\n* @name readDataView\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/read-dataview}\n*/\nsetReadOnly( ns, 'readDataView', require( '@stdlib/strided-base-read-dataview' ) );\n\n/**\n* @name reinterpretBoolean\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/reinterpret-boolean}\n*/\nsetReadOnly( ns, 'reinterpretBoolean', require( '@stdlib/strided-base-reinterpret-boolean' ) );\n\n/**\n* @name reinterpretComplex\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/reinterpret-complex}\n*/\nsetReadOnly( ns, 'reinterpretComplex', require( '@stdlib/strided-base-reinterpret-complex' ) );\n\n/**\n* @name reinterpretComplex64\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/reinterpret-complex64}\n*/\nsetReadOnly( ns, 'reinterpretComplex64', require( '@stdlib/strided-base-reinterpret-complex64' ) );\n\n/**\n* @name reinterpretComplex128\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/reinterpret-complex128}\n*/\nsetReadOnly( ns, 'reinterpretComplex128', require( '@stdlib/strided-base-reinterpret-complex128' ) );\n\n/**\n* @name smap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smap}\n*/\nsetReadOnly( ns, 'smap', require( '@stdlib/strided-base-smap' ) );\n\n/**\n* @name smap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smap2}\n*/\nsetReadOnly( ns, 'smap2', require( '@stdlib/strided-base-smap2' ) );\n\n/**\n* @name smskmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smskmap}\n*/\nsetReadOnly( ns, 'smskmap', require( '@stdlib/strided-base-smskmap' ) );\n\n/**\n* @name smskmap2\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/smskmap2}\n*/\nsetReadOnly( ns, 'smskmap2', require( '@stdlib/strided-base-smskmap2' ) );\n\n/**\n* @name stride2offset\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/stride2offset}\n*/\nsetReadOnly( ns, 'stride2offset', require( '@stdlib/strided-base-stride2offset' ) );\n\n/**\n* @name strided2object\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/strided2object}\n*/\nsetReadOnly( ns, 'strided2object', require( '@stdlib/strided-base-strided2object' ) );\n\n/**\n* @name ternary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/ternary}\n*/\nsetReadOnly( ns, 'ternary', require( '@stdlib/strided-base-ternary' ) );\n\n/**\n* @name unary\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary}\n*/\nsetReadOnly( ns, 'unary', require( '@stdlib/strided-base-unary' ) );\n\n/**\n* @name unaryAddonDispatch\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-addon-dispatch}\n*/\nsetReadOnly( ns, 'unaryAddonDispatch', require( '@stdlib/strided-base-unary-addon-dispatch' ) );\n\n/**\n* @name unaryBy\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-by}\n*/\nsetReadOnly( ns, 'unaryBy', require( '@stdlib/strided-base-unary-by' ) );\n\n/**\n* @name unaryDtypeSignatures\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-dtype-signatures}\n*/\nsetReadOnly( ns, 'unaryDtypeSignatures', require( '@stdlib/strided-base-unary-dtype-signatures' ) );\n\n/**\n* @name unarySignatureCallbacks\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/unary-signature-callbacks}\n*/\nsetReadOnly( ns, 'unarySignatureCallbacks', require( '@stdlib/strided-base-unary-signature-callbacks' ) );\n\n/**\n* @name writeDataView\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/write-dataview}\n*/\nsetReadOnly( ns, 'writeDataView', require( '@stdlib/strided-base-write-dataview' ) );\n\n/**\n* @name zmap\n* @memberof ns\n* @readonly\n* @type {Function}\n* @see {@link module:@stdlib/strided/base/zmap}\n*/\nsetReadOnly( ns, 'zmap', require( '@stdlib/strided-base-zmap' ) );\n\n\n// EXPORTS //\n\nmodule.exports = ns;\n"],
|
|
5
|
+
"mappings": "aA8BA,IAAIA,EAAc,QAAS,yCAA0C,EAUjEC,EAAK,CAAC,EASVD,EAAaC,EAAI,SAAU,QAAS,6BAA8B,CAAE,EASpED,EAAaC,EAAI,sBAAuB,QAAS,4CAA6C,CAAE,EAShGD,EAAaC,EAAI,wBAAyB,QAAS,8CAA+C,CAAE,EASpGD,EAAaC,EAAI,2BAA4B,QAAS,iDAAkD,CAAE,EAS1GD,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAShED,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAShED,EAAaC,EAAI,QAAS,QAAS,4BAA6B,CAAE,EASlED,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,WAAY,QAAS,+BAAgC,CAAE,EASxED,EAAaC,EAAI,gBAAiB,QAAS,qCAAsC,CAAE,EASnFD,EAAaC,EAAI,mBAAoB,QAAS,yCAA0C,CAAE,EAS1FD,EAAaC,EAAI,kBAAmB,QAAS,wCAAyC,CAAE,EASxFD,EAAaC,EAAI,gBAAiB,QAAS,qCAAsC,CAAE,EASnFD,EAAaC,EAAI,QAAS,QAAS,6BAA8B,CAAE,EASnED,EAAaC,EAAI,SAAU,QAAS,8BAA+B,CAAE,EASrED,EAAaC,EAAI,qBAAsB,QAAS,4CAA6C,CAAE,EAS/FD,EAAaC,EAAI,gBAAiB,QAAS,sCAAuC,CAAE,EASpFD,EAAaC,EAAI,qBAAsB,QAAS,4CAA6C,CAAE,EAS/FD,EAAaC,EAAI,WAAY,QAAS,+BAAgC,CAAE,EASxED,EAAaC,EAAI,wBAAyB,QAAS,8CAA+C,CAAE,EASpGD,EAAaC,EAAI,0BAA2B,QAAS,gDAAiD,CAAE,EASxGD,EAAaC,EAAI,6BAA8B,QAAS,mDAAoD,CAAE,EAS9GD,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,uBAAwB,QAAS,6CAA8C,CAAE,EASlGD,EAAaC,EAAI,aAAc,QAAS,kCAAmC,CAAE,EAS7ED,EAAaC,EAAI,aAAc,QAAS,iCAAkC,CAAE,EAS5ED,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,eAAgB,QAAS,oCAAqC,CAAE,EASjFD,EAAaC,EAAI,qBAAsB,QAAS,0CAA2C,CAAE,EAS7FD,EAAaC,EAAI,qBAAsB,QAAS,0CAA2C,CAAE,EAS7FD,EAAaC,EAAI,uBAAwB,QAAS,4CAA6C,CAAE,EASjGD,EAAaC,EAAI,wBAAyB,QAAS,6CAA8C,CAAE,EASnGD,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAShED,EAAaC,EAAI,QAAS,QAAS,4BAA6B,CAAE,EASlED,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,WAAY,QAAS,+BAAgC,CAAE,EASxED,EAAaC,EAAI,gBAAiB,QAAS,oCAAqC,CAAE,EASlFD,EAAaC,EAAI,iBAAkB,QAAS,qCAAsC,CAAE,EASpFD,EAAaC,EAAI,UAAW,QAAS,8BAA+B,CAAE,EAStED,EAAaC,EAAI,QAAS,QAAS,4BAA6B,CAAE,EASlED,EAAaC,EAAI,qBAAsB,QAAS,2CAA4C,CAAE,EAS9FD,EAAaC,EAAI,UAAW,QAAS,+BAAgC,CAAE,EASvED,EAAaC,EAAI,uBAAwB,QAAS,6CAA8C,CAAE,EASlGD,EAAaC,EAAI,0BAA2B,QAAS,gDAAiD,CAAE,EASxGD,EAAaC,EAAI,gBAAiB,QAAS,qCAAsC,CAAE,EASnFD,EAAaC,EAAI,OAAQ,QAAS,2BAA4B,CAAE,EAKhE,OAAO,QAAUA",
|
|
6
6
|
"names": ["setReadOnly", "ns"]
|
|
7
7
|
}
|
package/docs/types/index.d.ts
CHANGED
|
@@ -47,6 +47,8 @@ import nullaryAddonDispatch = require( '@stdlib/strided-base-nullary-addon-dispa
|
|
|
47
47
|
import offsetView = require( '@stdlib/strided-base-offset-view' );
|
|
48
48
|
import quaternary = require( '@stdlib/strided-base-quaternary' );
|
|
49
49
|
import quinary = require( '@stdlib/strided-base-quinary' );
|
|
50
|
+
import readDataView = require( '@stdlib/strided-base-read-dataview' );
|
|
51
|
+
import reinterpretBoolean = require( '@stdlib/strided-base-reinterpret-boolean' );
|
|
50
52
|
import reinterpretComplex = require( '@stdlib/strided-base-reinterpret-complex' );
|
|
51
53
|
import reinterpretComplex64 = require( '@stdlib/strided-base-reinterpret-complex64' );
|
|
52
54
|
import reinterpretComplex128 = require( '@stdlib/strided-base-reinterpret-complex128' );
|
|
@@ -54,12 +56,15 @@ import smap = require( '@stdlib/strided-base-smap' );
|
|
|
54
56
|
import smap2 = require( '@stdlib/strided-base-smap2' );
|
|
55
57
|
import smskmap = require( '@stdlib/strided-base-smskmap' );
|
|
56
58
|
import smskmap2 = require( '@stdlib/strided-base-smskmap2' );
|
|
59
|
+
import stride2offset = require( '@stdlib/strided-base-stride2offset' );
|
|
60
|
+
import strided2object = require( '@stdlib/strided-base-strided2object' );
|
|
57
61
|
import ternary = require( '@stdlib/strided-base-ternary' );
|
|
58
62
|
import unary = require( '@stdlib/strided-base-unary' );
|
|
59
63
|
import unaryAddonDispatch = require( '@stdlib/strided-base-unary-addon-dispatch' );
|
|
60
64
|
import unaryBy = require( '@stdlib/strided-base-unary-by' );
|
|
61
65
|
import unaryDtypeSignatures = require( '@stdlib/strided-base-unary-dtype-signatures' );
|
|
62
66
|
import unarySignatureCallbacks = require( '@stdlib/strided-base-unary-signature-callbacks' );
|
|
67
|
+
import writeDataView = require( '@stdlib/strided-base-write-dataview' );
|
|
63
68
|
import zmap = require( '@stdlib/strided-base-zmap' );
|
|
64
69
|
|
|
65
70
|
/**
|
|
@@ -208,9 +213,9 @@ interface Namespace {
|
|
|
208
213
|
*
|
|
209
214
|
* @example
|
|
210
215
|
* var signatures = require( '@stdlib/strided-base-binary-dtype-signatures' );
|
|
211
|
-
* var add = require( '@stdlib/
|
|
212
|
-
* var cadd = require( '@stdlib/
|
|
213
|
-
* var caddf = require( '@stdlib/
|
|
216
|
+
* var add = require( '@stdlib/number-float64-base-add' );
|
|
217
|
+
* var cadd = require( '@stdlib/complex-float64-base-add' );
|
|
218
|
+
* var caddf = require( '@stdlib/complex-float32-base-add' );
|
|
214
219
|
*
|
|
215
220
|
* var dtypes = [
|
|
216
221
|
* 'float64',
|
|
@@ -246,9 +251,9 @@ interface Namespace {
|
|
|
246
251
|
*
|
|
247
252
|
* @example
|
|
248
253
|
* var Complex64Array = require( '@stdlib/array-complex64' );
|
|
249
|
-
* var real = require( '@stdlib/complex-real' );
|
|
250
|
-
* var imag = require( '@stdlib/complex-imag' );
|
|
251
|
-
* var Complex64 = require( '@stdlib/complex-float32' );
|
|
254
|
+
* var real = require( '@stdlib/complex-float64-real' );
|
|
255
|
+
* var imag = require( '@stdlib/complex-float64-imag' );
|
|
256
|
+
* var Complex64 = require( '@stdlib/complex-float32-ctor' );
|
|
252
257
|
*
|
|
253
258
|
* function scale( x ) {
|
|
254
259
|
* var re = real( x );
|
|
@@ -272,9 +277,9 @@ interface Namespace {
|
|
|
272
277
|
*
|
|
273
278
|
* @example
|
|
274
279
|
* var Complex64Array = require( '@stdlib/array-complex64' );
|
|
275
|
-
* var real = require( '@stdlib/complex-real' );
|
|
276
|
-
* var imag = require( '@stdlib/complex-imag' );
|
|
277
|
-
* var Complex64 = require( '@stdlib/complex-float32' );
|
|
280
|
+
* var real = require( '@stdlib/complex-float64-real' );
|
|
281
|
+
* var imag = require( '@stdlib/complex-float64-imag' );
|
|
282
|
+
* var Complex64 = require( '@stdlib/complex-float32-ctor' );
|
|
278
283
|
*
|
|
279
284
|
* function scale( x ) {
|
|
280
285
|
* var re = real( x );
|
|
@@ -352,7 +357,7 @@ interface Namespace {
|
|
|
352
357
|
*
|
|
353
358
|
* @example
|
|
354
359
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
355
|
-
* var add = require( '@stdlib/
|
|
360
|
+
* var add = require( '@stdlib/number-float64-base-add' );
|
|
356
361
|
*
|
|
357
362
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
358
363
|
* var y = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -363,7 +368,7 @@ interface Namespace {
|
|
|
363
368
|
*
|
|
364
369
|
* @example
|
|
365
370
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
366
|
-
* var add = require( '@stdlib/
|
|
371
|
+
* var add = require( '@stdlib/number-float64-base-add' );
|
|
367
372
|
*
|
|
368
373
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
369
374
|
* var y = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -437,7 +442,7 @@ interface Namespace {
|
|
|
437
442
|
* @example
|
|
438
443
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
439
444
|
* var Uint8Array = require( '@stdlib/array-uint8' );
|
|
440
|
-
* var add = require( '@stdlib/
|
|
445
|
+
* var add = require( '@stdlib/number-float64-base-add' );
|
|
441
446
|
*
|
|
442
447
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
443
448
|
* var y = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -450,7 +455,7 @@ interface Namespace {
|
|
|
450
455
|
* @example
|
|
451
456
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
452
457
|
* var Uint8Array = require( '@stdlib/array-uint8' );
|
|
453
|
-
* var add = require( '@stdlib/
|
|
458
|
+
* var add = require( '@stdlib/number-float64-base-add' );
|
|
454
459
|
*
|
|
455
460
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
456
461
|
* var y = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -582,7 +587,7 @@ interface Namespace {
|
|
|
582
587
|
* @returns `z`
|
|
583
588
|
*
|
|
584
589
|
* @example
|
|
585
|
-
* var add = require( '@stdlib/
|
|
590
|
+
* var add = require( '@stdlib/number-float64-base-add' );
|
|
586
591
|
*
|
|
587
592
|
* function accessor( values ) {
|
|
588
593
|
* values[ 0 ] *= 2.0;
|
|
@@ -597,7 +602,7 @@ interface Namespace {
|
|
|
597
602
|
* // z => [ 4.0, 0.0, 12.0, 0.0, 20.0 ]
|
|
598
603
|
*
|
|
599
604
|
* @example
|
|
600
|
-
* var add = require( '@stdlib/
|
|
605
|
+
* var add = require( '@stdlib/number-float64-base-add' );
|
|
601
606
|
*
|
|
602
607
|
* function accessor( values ) {
|
|
603
608
|
* values[ 0 ] *= 2.0;
|
|
@@ -820,9 +825,9 @@ interface Namespace {
|
|
|
820
825
|
*
|
|
821
826
|
* @example
|
|
822
827
|
* var signatures = require( '@stdlib/strided-base-mskunary-dtype-signatures' );
|
|
823
|
-
* var identity = require( '@stdlib/
|
|
824
|
-
* var cidentity = require( '@stdlib/
|
|
825
|
-
* var cidentityf = require( '@stdlib/
|
|
828
|
+
* var identity = require( '@stdlib/number-float64-base-identity' );
|
|
829
|
+
* var cidentity = require( '@stdlib/complex-float64-base-identity' );
|
|
830
|
+
* var cidentityf = require( '@stdlib/complex-float32-base-identity' );
|
|
826
831
|
*
|
|
827
832
|
* var dtypes = [
|
|
828
833
|
* 'float64',
|
|
@@ -961,7 +966,7 @@ interface Namespace {
|
|
|
961
966
|
* @param fcn - quaternary callback
|
|
962
967
|
*
|
|
963
968
|
* @example
|
|
964
|
-
* var add = require( '@stdlib/
|
|
969
|
+
* var add = require( '@stdlib/number-float64-base-add4' );
|
|
965
970
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
966
971
|
*
|
|
967
972
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -979,7 +984,7 @@ interface Namespace {
|
|
|
979
984
|
* // => <Float64Array>[ 4.0, 8.0, 12.0, 16.0, 20.0 ]
|
|
980
985
|
*
|
|
981
986
|
* @example
|
|
982
|
-
* var add = require( '@stdlib/
|
|
987
|
+
* var add = require( '@stdlib/number-float64-base-add4' );
|
|
983
988
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
984
989
|
*
|
|
985
990
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1008,7 +1013,7 @@ interface Namespace {
|
|
|
1008
1013
|
* @param fcn - quinary callback
|
|
1009
1014
|
*
|
|
1010
1015
|
* @example
|
|
1011
|
-
* var add = require( '@stdlib/
|
|
1016
|
+
* var add = require( '@stdlib/number-float64-base-add5' );
|
|
1012
1017
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
1013
1018
|
*
|
|
1014
1019
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1027,7 +1032,7 @@ interface Namespace {
|
|
|
1027
1032
|
* // => <Float64Array>[ 5.0, 10.0, 15.0, 20.0, 25.0 ]
|
|
1028
1033
|
*
|
|
1029
1034
|
* @example
|
|
1030
|
-
* var add = require( '@stdlib/
|
|
1035
|
+
* var add = require( '@stdlib/number-float64-base-add5' );
|
|
1031
1036
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
1032
1037
|
*
|
|
1033
1038
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1048,6 +1053,67 @@ interface Namespace {
|
|
|
1048
1053
|
*/
|
|
1049
1054
|
quinary: typeof quinary;
|
|
1050
1055
|
|
|
1056
|
+
/**
|
|
1057
|
+
* Copies elements from an input strided DataView to elements in an output strided array.
|
|
1058
|
+
*
|
|
1059
|
+
* @param N - number of indexed elements
|
|
1060
|
+
* @param view - output DataView
|
|
1061
|
+
* @param strideView - `view` stride length (in bytes)
|
|
1062
|
+
* @param out - output array
|
|
1063
|
+
* @param strideOut - `out` stride length
|
|
1064
|
+
* @param littleEndian - boolean indicating whether the data is stored in little-endian format
|
|
1065
|
+
* @returns output DataView
|
|
1066
|
+
*
|
|
1067
|
+
* @example
|
|
1068
|
+
* var Float64Array = require( '@stdlib/array-float64' );
|
|
1069
|
+
* var DataView = require( '@stdlib/array-dataview' );
|
|
1070
|
+
*
|
|
1071
|
+
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0 ] );
|
|
1072
|
+
* var view = new DataView( x.buffer );
|
|
1073
|
+
*
|
|
1074
|
+
* var y = new Float64Array( x.length );
|
|
1075
|
+
* var out = ns.readDataView( x.length, view, 8, y, 1, true );
|
|
1076
|
+
* // e.g., returns <Float64Array>[ 1.0, 2.0, 3.0, 4.0 ]
|
|
1077
|
+
*
|
|
1078
|
+
* var bool = ( out === y );
|
|
1079
|
+
* // returns true
|
|
1080
|
+
*
|
|
1081
|
+
* @example
|
|
1082
|
+
* var Float64Array = require( '@stdlib/array-float64' );
|
|
1083
|
+
* var DataView = require( '@stdlib/array-dataview' );
|
|
1084
|
+
*
|
|
1085
|
+
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0 ] );
|
|
1086
|
+
* var view = new DataView( x.buffer );
|
|
1087
|
+
*
|
|
1088
|
+
* var y = new Float64Array( x.length );
|
|
1089
|
+
* var out = ns.readDataView.ndarray( x.length, view, 8, 0, y, 1, 0, true );
|
|
1090
|
+
* // e.g., returns <Float64Array>[ 1.0, 2.0, 3.0, 4.0 ]
|
|
1091
|
+
*
|
|
1092
|
+
* var bool = ( out === y );
|
|
1093
|
+
* // returns true
|
|
1094
|
+
*/
|
|
1095
|
+
readDataView: typeof readDataView;
|
|
1096
|
+
|
|
1097
|
+
/**
|
|
1098
|
+
* Reinterprets a `BooleanArray` as a `Uint8Array`.
|
|
1099
|
+
*
|
|
1100
|
+
* @param x - input array
|
|
1101
|
+
* @param offset - starting index
|
|
1102
|
+
* @returns `Uint8Array` view
|
|
1103
|
+
*
|
|
1104
|
+
* @example
|
|
1105
|
+
* var BooleanArray = require( '@stdlib/array-bool' );
|
|
1106
|
+
*
|
|
1107
|
+
* var x = new BooleanArray( 10 );
|
|
1108
|
+
*
|
|
1109
|
+
* var out = ns.reinterpretBoolean( x, 0 );
|
|
1110
|
+
* // returns <Uint8Array>
|
|
1111
|
+
*
|
|
1112
|
+
* var bool = ( out.buffer === x.buffer );
|
|
1113
|
+
* // returns true
|
|
1114
|
+
*/
|
|
1115
|
+
reinterpretBoolean: typeof reinterpretBoolean;
|
|
1116
|
+
|
|
1051
1117
|
/**
|
|
1052
1118
|
* Reinterprets a `Complex128Array` as a `Float64Array`.
|
|
1053
1119
|
*
|
|
@@ -1159,7 +1225,7 @@ interface Namespace {
|
|
|
1159
1225
|
*
|
|
1160
1226
|
* @example
|
|
1161
1227
|
* var Float32Array = require( '@stdlib/array-float32' );
|
|
1162
|
-
* var addf = require( '@stdlib/
|
|
1228
|
+
* var addf = require( '@stdlib/number-float32-base-add' );
|
|
1163
1229
|
*
|
|
1164
1230
|
* var x = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
1165
1231
|
* var y = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1170,7 +1236,7 @@ interface Namespace {
|
|
|
1170
1236
|
*
|
|
1171
1237
|
* @example
|
|
1172
1238
|
* var Float32Array = require( '@stdlib/array-float32' );
|
|
1173
|
-
* var addf = require( '@stdlib/
|
|
1239
|
+
* var addf = require( '@stdlib/number-float32-base-add' );
|
|
1174
1240
|
*
|
|
1175
1241
|
* var x = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
1176
1242
|
* var y = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1244,7 +1310,7 @@ interface Namespace {
|
|
|
1244
1310
|
* @example
|
|
1245
1311
|
* var Float32Array = require( '@stdlib/array-float32' );
|
|
1246
1312
|
* var Uint8Array = require( '@stdlib/array-uint8' );
|
|
1247
|
-
* var addf = require( '@stdlib/
|
|
1313
|
+
* var addf = require( '@stdlib/number-float32-base-add' );
|
|
1248
1314
|
*
|
|
1249
1315
|
* var x = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
1250
1316
|
* var y = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1257,7 +1323,7 @@ interface Namespace {
|
|
|
1257
1323
|
* @example
|
|
1258
1324
|
* var Float32Array = require( '@stdlib/array-float32' );
|
|
1259
1325
|
* var Uint8Array = require( '@stdlib/array-uint8' );
|
|
1260
|
-
* var addf = require( '@stdlib/
|
|
1326
|
+
* var addf = require( '@stdlib/number-float32-base-add' );
|
|
1261
1327
|
*
|
|
1262
1328
|
* var x = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
1263
1329
|
* var y = new Float32Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1269,6 +1335,64 @@ interface Namespace {
|
|
|
1269
1335
|
*/
|
|
1270
1336
|
smskmap2: typeof smskmap2;
|
|
1271
1337
|
|
|
1338
|
+
/**
|
|
1339
|
+
* Returns the index offset which specifies the location of the first indexed value in a strided array.
|
|
1340
|
+
*
|
|
1341
|
+
* @param N - number of indexed elements
|
|
1342
|
+
* @param stride - index increment
|
|
1343
|
+
* @returns offset
|
|
1344
|
+
*
|
|
1345
|
+
* @example
|
|
1346
|
+
* var offset = ns.stride2offset( 10, -10 );
|
|
1347
|
+
* // returns 90
|
|
1348
|
+
*/
|
|
1349
|
+
stride2offset: typeof stride2offset;
|
|
1350
|
+
|
|
1351
|
+
/**
|
|
1352
|
+
* Converts a strided array and associated metadata to an object likely to have the same "shape".
|
|
1353
|
+
*
|
|
1354
|
+
* ## Notes
|
|
1355
|
+
*
|
|
1356
|
+
* - This function is intended as a potential performance optimization. In V8, for example, even if two objects share common properties, if those properties were added in different orders or if one object has additional properties not shared by the other object, then those objects will have different "hidden" classes. If a function is provided many objects having different "shapes", some JavaScript VMs (e.g., V8) will consider the function "megamorphic" and fail to perform various runtime optimizations. Accordingly, the intent of this function is to standardize the "shape" of the object holding strided array metadata to ensure that internal functions operating on strided arrays are provided consistent argument "shapes".
|
|
1357
|
+
*
|
|
1358
|
+
* - The returned object has the following properties:
|
|
1359
|
+
*
|
|
1360
|
+
* - **data**: reference to the input array.
|
|
1361
|
+
* - **dtype**: array data type.
|
|
1362
|
+
* - **length**: number of indexed elements.
|
|
1363
|
+
* - **stride**: index increment.
|
|
1364
|
+
* - **offset**: starting index.
|
|
1365
|
+
* - **accessorProtocol**: boolean indicating whether the input array uses accessors for getting and setting elements.
|
|
1366
|
+
* - **accessors**: a two-element array whose first element is an accessor for retrieving an array element and whose second element is an accessor for setting an array element.
|
|
1367
|
+
*
|
|
1368
|
+
* @param N - number of indexed elements
|
|
1369
|
+
* @param x - input array
|
|
1370
|
+
* @param stride - index increment
|
|
1371
|
+
* @param offset - index offset
|
|
1372
|
+
* @returns object containing strided array data
|
|
1373
|
+
*
|
|
1374
|
+
* @example
|
|
1375
|
+
* var x = {
|
|
1376
|
+
* '0': 1,
|
|
1377
|
+
* '1': 2,
|
|
1378
|
+
* '2': 3,
|
|
1379
|
+
* '4': 4,
|
|
1380
|
+
* 'length': 4
|
|
1381
|
+
* };
|
|
1382
|
+
* var obj = ns.strided2object( 4, x, 1, 0 );
|
|
1383
|
+
* // returns {...}
|
|
1384
|
+
*
|
|
1385
|
+
* var bool = obj.accessorProtocol;
|
|
1386
|
+
* // returns false
|
|
1387
|
+
*
|
|
1388
|
+
* var fcns = obj.accessors;
|
|
1389
|
+
* // returns [ <Function>, <Function> ]
|
|
1390
|
+
*
|
|
1391
|
+
* var v = fcns[ 0 ]( x.data, 2 );
|
|
1392
|
+
* // returns 3
|
|
1393
|
+
*/
|
|
1394
|
+
strided2object: typeof strided2object;
|
|
1395
|
+
|
|
1272
1396
|
/**
|
|
1273
1397
|
* Applies a ternary callback to strided input array elements and assigns results to elements in a strided output array.
|
|
1274
1398
|
*
|
|
@@ -1278,7 +1402,7 @@ interface Namespace {
|
|
|
1278
1402
|
* @param fcn - ternary callback
|
|
1279
1403
|
*
|
|
1280
1404
|
* @example
|
|
1281
|
-
* var add = require( '@stdlib/
|
|
1405
|
+
* var add = require( '@stdlib/number-float64-base-add3' );
|
|
1282
1406
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
1283
1407
|
*
|
|
1284
1408
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1295,7 +1419,7 @@ interface Namespace {
|
|
|
1295
1419
|
* // => <Float64Array>[ 3.0, 6.0, 9.0, 12.0, 15.0 ]
|
|
1296
1420
|
*
|
|
1297
1421
|
* @example
|
|
1298
|
-
* var add = require( '@stdlib/
|
|
1422
|
+
* var add = require( '@stdlib/number-float64-base-add3' );
|
|
1299
1423
|
* var Float64Array = require( '@stdlib/array-float64' );
|
|
1300
1424
|
*
|
|
1301
1425
|
* var x = new Float64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0 ] );
|
|
@@ -1498,9 +1622,9 @@ interface Namespace {
|
|
|
1498
1622
|
*
|
|
1499
1623
|
* @example
|
|
1500
1624
|
* var signatures = require( '@stdlib/strided-base-unary-dtype-signatures' );
|
|
1501
|
-
* var identity = require( '@stdlib/
|
|
1502
|
-
* var cidentity = require( '@stdlib/
|
|
1503
|
-
* var cidentityf = require( '@stdlib/
|
|
1625
|
+
* var identity = require( '@stdlib/number-float64-base-identity' );
|
|
1626
|
+
* var cidentity = require( '@stdlib/complex-float64-base-identity' );
|
|
1627
|
+
* var cidentityf = require( '@stdlib/complex-float32-base-identity' );
|
|
1504
1628
|
*
|
|
1505
1629
|
* var dtypes = [
|
|
1506
1630
|
* 'float64',
|
|
@@ -1523,6 +1647,55 @@ interface Namespace {
|
|
|
1523
1647
|
*/
|
|
1524
1648
|
unarySignatureCallbacks: typeof unarySignatureCallbacks;
|
|
1525
1649
|
|
|
1650
|
+
/**
|
|
1651
|
+
* Copies elements from an input strided array to elements in a strided DataView.
|
|
1652
|
+
*
|
|
1653
|
+
* @param N - number of indexed elements
|
|
1654
|
+
* @param x - input array
|
|
1655
|
+
* @param strideX - `x` stride length
|
|
1656
|
+
* @param view - output DataView
|
|
1657
|
+
* @param strideView - `view` stride length (in bytes)
|
|
1658
|
+
* @param littleEndian - boolean indicating whether to store the data in little-endian format
|
|
1659
|
+
* @returns output DataView
|
|
1660
|
+
*
|
|
1661
|
+
* @example
|
|
1662
|
+
* var ArrayBuffer = require( '@stdlib/array-buffer' );
|
|
1663
|
+
* var DataView = require( '@stdlib/array-dataview' );
|
|
1664
|
+
*
|
|
1665
|
+
* var x = [ 1.0, 2.0, 3.0, 4.0 ];
|
|
1666
|
+
*
|
|
1667
|
+
* var buf = new ArrayBuffer( 32 );
|
|
1668
|
+
* var view = new DataView( buf );
|
|
1669
|
+
*
|
|
1670
|
+
* var out = ns.writeDataView( 4, x, 1, view, 8, true );
|
|
1671
|
+
* // returns <DataView>
|
|
1672
|
+
*
|
|
1673
|
+
* var bool = ( out === view );
|
|
1674
|
+
* // returns true
|
|
1675
|
+
*
|
|
1676
|
+
* var v = view.getFloat64( 0, true );
|
|
1677
|
+
* // returns 1.0
|
|
1678
|
+
*
|
|
1679
|
+
* @example
|
|
1680
|
+
* var ArrayBuffer = require( '@stdlib/array-buffer' );
|
|
1681
|
+
* var DataView = require( '@stdlib/array-dataview' );
|
|
1682
|
+
*
|
|
1683
|
+
* var x = [ 1.0, 2.0, 3.0, 4.0 ];
|
|
1684
|
+
*
|
|
1685
|
+
* var buf = new ArrayBuffer( 32 );
|
|
1686
|
+
* var view = new DataView( buf );
|
|
1687
|
+
*
|
|
1688
|
+
* var out = ns.writeDataView.ndarray( 4, x, 1, 0, view, 8, 0, true );
|
|
1689
|
+
* // returns <DataView>
|
|
1690
|
+
*
|
|
1691
|
+
* var bool = ( out === view );
|
|
1692
|
+
* // returns true
|
|
1693
|
+
*
|
|
1694
|
+
* var v = view.getFloat64( 0, true );
|
|
1695
|
+
* // returns 1.0
|
|
1696
|
+
*/
|
|
1697
|
+
writeDataView: typeof writeDataView;
|
|
1698
|
+
|
|
1526
1699
|
/**
|
|
1527
1700
|
* Applies a unary function to a double-precision complex floating-point strided input array and assigns results to a double-precision complex floating-point strided output array.
|
|
1528
1701
|
*
|
|
@@ -1536,9 +1709,9 @@ interface Namespace {
|
|
|
1536
1709
|
*
|
|
1537
1710
|
* @example
|
|
1538
1711
|
* var Complex128Array = require( '@stdlib/array-complex128' );
|
|
1539
|
-
* var real = require( '@stdlib/complex-real' );
|
|
1540
|
-
* var imag = require( '@stdlib/complex-imag' );
|
|
1541
|
-
* var Complex128 = require( '@stdlib/complex-float64' );
|
|
1712
|
+
* var real = require( '@stdlib/complex-float64-real' );
|
|
1713
|
+
* var imag = require( '@stdlib/complex-float64-imag' );
|
|
1714
|
+
* var Complex128 = require( '@stdlib/complex-float64-ctor' );
|
|
1542
1715
|
*
|
|
1543
1716
|
* function scale( x ) {
|
|
1544
1717
|
* var re = real( x );
|
|
@@ -1552,19 +1725,13 @@ interface Namespace {
|
|
|
1552
1725
|
* ns.zmap( x.length, x, 1, y, 1, scale );
|
|
1553
1726
|
*
|
|
1554
1727
|
* var v = y.get( 0 );
|
|
1555
|
-
* // returns <Complex128>
|
|
1556
|
-
*
|
|
1557
|
-
* var re = real( v );
|
|
1558
|
-
* // returns 10.0
|
|
1559
|
-
*
|
|
1560
|
-
* var im = imag( v );
|
|
1561
|
-
* // returns 10.0
|
|
1728
|
+
* // returns <Complex128>[ 10.0, 10.0 ]
|
|
1562
1729
|
*
|
|
1563
1730
|
* @example
|
|
1564
1731
|
* var Complex128Array = require( '@stdlib/array-complex128' );
|
|
1565
|
-
* var real = require( '@stdlib/complex-real' );
|
|
1566
|
-
* var imag = require( '@stdlib/complex-imag' );
|
|
1567
|
-
* var Complex128 = require( '@stdlib/complex-float64' );
|
|
1732
|
+
* var real = require( '@stdlib/complex-float64-real' );
|
|
1733
|
+
* var imag = require( '@stdlib/complex-float64-imag' );
|
|
1734
|
+
* var Complex128 = require( '@stdlib/complex-float64-ctor' );
|
|
1568
1735
|
*
|
|
1569
1736
|
* function scale( x ) {
|
|
1570
1737
|
* var re = real( x );
|
|
@@ -1578,13 +1745,7 @@ interface Namespace {
|
|
|
1578
1745
|
* ns.zmap.ndarray( x.length, x, 1, 0, y, 1, 0, scale );
|
|
1579
1746
|
*
|
|
1580
1747
|
* var v = y.get( 0 );
|
|
1581
|
-
* // returns <Complex128>
|
|
1582
|
-
*
|
|
1583
|
-
* var re = real( v );
|
|
1584
|
-
* // returns 10.0
|
|
1585
|
-
*
|
|
1586
|
-
* var im = imag( v );
|
|
1587
|
-
* // returns 10.0
|
|
1748
|
+
* // returns <Complex128>[ 10.0, 10.0 ]
|
|
1588
1749
|
*/
|
|
1589
1750
|
zmap: typeof zmap;
|
|
1590
1751
|
}
|
package/lib/index.js
CHANGED
|
@@ -283,6 +283,24 @@ setReadOnly( ns, 'quaternary', require( '@stdlib/strided-base-quaternary' ) );
|
|
|
283
283
|
*/
|
|
284
284
|
setReadOnly( ns, 'quinary', require( '@stdlib/strided-base-quinary' ) );
|
|
285
285
|
|
|
286
|
+
/**
|
|
287
|
+
* @name readDataView
|
|
288
|
+
* @memberof ns
|
|
289
|
+
* @readonly
|
|
290
|
+
* @type {Function}
|
|
291
|
+
* @see {@link module:@stdlib/strided/base/read-dataview}
|
|
292
|
+
*/
|
|
293
|
+
setReadOnly( ns, 'readDataView', require( '@stdlib/strided-base-read-dataview' ) );
|
|
294
|
+
|
|
295
|
+
/**
|
|
296
|
+
* @name reinterpretBoolean
|
|
297
|
+
* @memberof ns
|
|
298
|
+
* @readonly
|
|
299
|
+
* @type {Function}
|
|
300
|
+
* @see {@link module:@stdlib/strided/base/reinterpret-boolean}
|
|
301
|
+
*/
|
|
302
|
+
setReadOnly( ns, 'reinterpretBoolean', require( '@stdlib/strided-base-reinterpret-boolean' ) );
|
|
303
|
+
|
|
286
304
|
/**
|
|
287
305
|
* @name reinterpretComplex
|
|
288
306
|
* @memberof ns
|
|
@@ -346,6 +364,24 @@ setReadOnly( ns, 'smskmap', require( '@stdlib/strided-base-smskmap' ) );
|
|
|
346
364
|
*/
|
|
347
365
|
setReadOnly( ns, 'smskmap2', require( '@stdlib/strided-base-smskmap2' ) );
|
|
348
366
|
|
|
367
|
+
/**
|
|
368
|
+
* @name stride2offset
|
|
369
|
+
* @memberof ns
|
|
370
|
+
* @readonly
|
|
371
|
+
* @type {Function}
|
|
372
|
+
* @see {@link module:@stdlib/strided/base/stride2offset}
|
|
373
|
+
*/
|
|
374
|
+
setReadOnly( ns, 'stride2offset', require( '@stdlib/strided-base-stride2offset' ) );
|
|
375
|
+
|
|
376
|
+
/**
|
|
377
|
+
* @name strided2object
|
|
378
|
+
* @memberof ns
|
|
379
|
+
* @readonly
|
|
380
|
+
* @type {Function}
|
|
381
|
+
* @see {@link module:@stdlib/strided/base/strided2object}
|
|
382
|
+
*/
|
|
383
|
+
setReadOnly( ns, 'strided2object', require( '@stdlib/strided-base-strided2object' ) );
|
|
384
|
+
|
|
349
385
|
/**
|
|
350
386
|
* @name ternary
|
|
351
387
|
* @memberof ns
|
|
@@ -400,6 +436,15 @@ setReadOnly( ns, 'unaryDtypeSignatures', require( '@stdlib/strided-base-unary-dt
|
|
|
400
436
|
*/
|
|
401
437
|
setReadOnly( ns, 'unarySignatureCallbacks', require( '@stdlib/strided-base-unary-signature-callbacks' ) );
|
|
402
438
|
|
|
439
|
+
/**
|
|
440
|
+
* @name writeDataView
|
|
441
|
+
* @memberof ns
|
|
442
|
+
* @readonly
|
|
443
|
+
* @type {Function}
|
|
444
|
+
* @see {@link module:@stdlib/strided/base/write-dataview}
|
|
445
|
+
*/
|
|
446
|
+
setReadOnly( ns, 'writeDataView', require( '@stdlib/strided-base-write-dataview' ) );
|
|
447
|
+
|
|
403
448
|
/**
|
|
404
449
|
* @name zmap
|
|
405
450
|
* @memberof ns
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stdlib/strided-base",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "Base strided.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": {
|
|
@@ -30,48 +30,53 @@
|
|
|
30
30
|
"url": "https://github.com/stdlib-js/stdlib/issues"
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@stdlib/strided-base-binary": "^0.
|
|
34
|
-
"@stdlib/strided-base-binary-addon-dispatch": "^0.
|
|
35
|
-
"@stdlib/strided-base-binary-dtype-signatures": "^0.2.
|
|
36
|
-
"@stdlib/strided-base-binary-signature-callbacks": "^0.2.
|
|
37
|
-
"@stdlib/strided-base-cmap": "^0.2.
|
|
38
|
-
"@stdlib/strided-base-dmap": "^0.2.
|
|
39
|
-
"@stdlib/strided-base-dmap2": "^0.2.
|
|
40
|
-
"@stdlib/strided-base-dmskmap": "^0.2.
|
|
41
|
-
"@stdlib/strided-base-dmskmap2": "^0.2.
|
|
42
|
-
"@stdlib/strided-base-dtype-enum2str": "^0.2.
|
|
43
|
-
"@stdlib/strided-base-dtype-resolve-enum": "^0.2.
|
|
44
|
-
"@stdlib/strided-base-dtype-resolve-str": "^0.2.
|
|
45
|
-
"@stdlib/strided-base-dtype-str2enum": "^0.2.
|
|
46
|
-
"@stdlib/strided-base-map-by": "^0.2.
|
|
47
|
-
"@stdlib/strided-base-map-by2": "^0.2.
|
|
48
|
-
"@stdlib/strided-base-max-view-buffer-index": "^0.
|
|
49
|
-
"@stdlib/strided-base-meta-data-props": "^0.2.
|
|
50
|
-
"@stdlib/strided-base-min-view-buffer-index": "^0.
|
|
51
|
-
"@stdlib/strided-base-mskunary": "^0.
|
|
52
|
-
"@stdlib/strided-base-mskunary-addon-dispatch": "^0.
|
|
53
|
-
"@stdlib/strided-base-mskunary-dtype-signatures": "^0.2.
|
|
54
|
-
"@stdlib/strided-base-mskunary-signature-callbacks": "^0.2.
|
|
55
|
-
"@stdlib/strided-base-nullary": "^0.
|
|
56
|
-
"@stdlib/strided-base-nullary-addon-dispatch": "^0.
|
|
57
|
-
"@stdlib/strided-base-offset-view": "^0.2.
|
|
58
|
-
"@stdlib/strided-base-quaternary": "^0.2.
|
|
59
|
-
"@stdlib/strided-base-quinary": "^0.2.
|
|
60
|
-
"@stdlib/strided-base-
|
|
61
|
-
"@stdlib/strided-base-reinterpret-
|
|
62
|
-
"@stdlib/strided-base-reinterpret-
|
|
63
|
-
"@stdlib/strided-base-
|
|
64
|
-
"@stdlib/strided-base-
|
|
65
|
-
"@stdlib/strided-base-
|
|
66
|
-
"@stdlib/strided-base-
|
|
67
|
-
"@stdlib/strided-base-
|
|
68
|
-
"@stdlib/strided-base-
|
|
69
|
-
"@stdlib/strided-base-
|
|
70
|
-
"@stdlib/strided-base-
|
|
71
|
-
"@stdlib/strided-base-
|
|
72
|
-
"@stdlib/strided-base-unary
|
|
73
|
-
"@stdlib/strided-base-
|
|
74
|
-
"@stdlib/
|
|
33
|
+
"@stdlib/strided-base-binary": "^0.3.0",
|
|
34
|
+
"@stdlib/strided-base-binary-addon-dispatch": "^0.3.0",
|
|
35
|
+
"@stdlib/strided-base-binary-dtype-signatures": "^0.2.2",
|
|
36
|
+
"@stdlib/strided-base-binary-signature-callbacks": "^0.2.2",
|
|
37
|
+
"@stdlib/strided-base-cmap": "^0.2.2",
|
|
38
|
+
"@stdlib/strided-base-dmap": "^0.2.2",
|
|
39
|
+
"@stdlib/strided-base-dmap2": "^0.2.2",
|
|
40
|
+
"@stdlib/strided-base-dmskmap": "^0.2.2",
|
|
41
|
+
"@stdlib/strided-base-dmskmap2": "^0.2.2",
|
|
42
|
+
"@stdlib/strided-base-dtype-enum2str": "^0.2.2",
|
|
43
|
+
"@stdlib/strided-base-dtype-resolve-enum": "^0.2.2",
|
|
44
|
+
"@stdlib/strided-base-dtype-resolve-str": "^0.2.2",
|
|
45
|
+
"@stdlib/strided-base-dtype-str2enum": "^0.2.2",
|
|
46
|
+
"@stdlib/strided-base-map-by": "^0.2.2",
|
|
47
|
+
"@stdlib/strided-base-map-by2": "^0.2.2",
|
|
48
|
+
"@stdlib/strided-base-max-view-buffer-index": "^0.3.0",
|
|
49
|
+
"@stdlib/strided-base-meta-data-props": "^0.2.2",
|
|
50
|
+
"@stdlib/strided-base-min-view-buffer-index": "^0.3.0",
|
|
51
|
+
"@stdlib/strided-base-mskunary": "^0.3.0",
|
|
52
|
+
"@stdlib/strided-base-mskunary-addon-dispatch": "^0.3.0",
|
|
53
|
+
"@stdlib/strided-base-mskunary-dtype-signatures": "^0.2.2",
|
|
54
|
+
"@stdlib/strided-base-mskunary-signature-callbacks": "^0.2.2",
|
|
55
|
+
"@stdlib/strided-base-nullary": "^0.3.0",
|
|
56
|
+
"@stdlib/strided-base-nullary-addon-dispatch": "^0.3.0",
|
|
57
|
+
"@stdlib/strided-base-offset-view": "^0.2.2",
|
|
58
|
+
"@stdlib/strided-base-quaternary": "^0.2.2",
|
|
59
|
+
"@stdlib/strided-base-quinary": "^0.2.2",
|
|
60
|
+
"@stdlib/strided-base-read-dataview": "github:stdlib-js/strided-base-read-dataview#main",
|
|
61
|
+
"@stdlib/strided-base-reinterpret-boolean": "^0.0.2",
|
|
62
|
+
"@stdlib/strided-base-reinterpret-complex": "^0.1.2",
|
|
63
|
+
"@stdlib/strided-base-reinterpret-complex128": "^0.2.2",
|
|
64
|
+
"@stdlib/strided-base-reinterpret-complex64": "^0.2.1",
|
|
65
|
+
"@stdlib/strided-base-smap": "^0.2.2",
|
|
66
|
+
"@stdlib/strided-base-smap2": "^0.2.2",
|
|
67
|
+
"@stdlib/strided-base-smskmap": "^0.2.2",
|
|
68
|
+
"@stdlib/strided-base-smskmap2": "^0.2.2",
|
|
69
|
+
"@stdlib/strided-base-stride2offset": "^0.1.0",
|
|
70
|
+
"@stdlib/strided-base-strided2object": "github:stdlib-js/strided-base-strided2object#main",
|
|
71
|
+
"@stdlib/strided-base-ternary": "^0.2.2",
|
|
72
|
+
"@stdlib/strided-base-unary": "^0.3.0",
|
|
73
|
+
"@stdlib/strided-base-unary-addon-dispatch": "^0.3.0",
|
|
74
|
+
"@stdlib/strided-base-unary-by": "^0.2.2",
|
|
75
|
+
"@stdlib/strided-base-unary-dtype-signatures": "^0.2.2",
|
|
76
|
+
"@stdlib/strided-base-unary-signature-callbacks": "^0.2.2",
|
|
77
|
+
"@stdlib/strided-base-write-dataview": "github:stdlib-js/strided-base-write-dataview#main",
|
|
78
|
+
"@stdlib/strided-base-zmap": "^0.2.2",
|
|
79
|
+
"@stdlib/utils-define-read-only-property": "^0.2.2"
|
|
75
80
|
},
|
|
76
81
|
"devDependencies": {},
|
|
77
82
|
"engines": {
|