Skip to content

Commit 0d2e9ef

Browse files
committed
Auto-generated commit
1 parent 54ef7b8 commit 0d2e9ef

File tree

5 files changed

+168
-1
lines changed

5 files changed

+168
-1
lines changed

CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
55
<section class="release" id="unreleased">
66

7-
## Unreleased (2025-01-11)
7+
## Unreleased (2025-01-12)
88

99
<section class="packages">
1010

@@ -86,6 +86,7 @@
8686

8787
##### Features
8888

89+
- [`e661213`](https://github.com/stdlib-js/stdlib/commit/e66121352ef767cdb87d19e938b1eccf7970fa3a) - update namespace TypeScript declarations [(#4706)](https://github.com/stdlib-js/stdlib/pull/4706)
8990
- [`741b6f1`](https://github.com/stdlib-js/stdlib/commit/741b6f1df8ce11e77fb22c279cee6bbae3323176) - add `spreadDimensions` to namespace
9091
- [`908239e`](https://github.com/stdlib-js/stdlib/commit/908239e7cc6b4b3e260d0cc1f5aebb9af35d83c6) - add `toUniqueNormalizedIndices` to namespace
9192
- [`524e854`](https://github.com/stdlib-js/stdlib/commit/524e854202862d5b37d66470d719fac1270e33c1) - add `toNormalizedIndices` to namespace
@@ -129,6 +130,7 @@
129130

130131
##### Features
131132

133+
- [`e661213`](https://github.com/stdlib-js/stdlib/commit/e66121352ef767cdb87d19e938b1eccf7970fa3a) - update namespace TypeScript declarations [(#4706)](https://github.com/stdlib-js/stdlib/pull/4706)
132134
- [`a94dcea`](https://github.com/stdlib-js/stdlib/commit/a94dceaa9469c774ee4622567e4c15a15e215bcf) - add `isColumnMajorString` to namespace
133135
- [`5e1be08`](https://github.com/stdlib-js/stdlib/commit/5e1be08ff661fb981dc4a91c2e9d37d7396327f5) - add `isRowMajorString` to namespace
134136
- [`8b1548f`](https://github.com/stdlib-js/stdlib/commit/8b1548fb45c1ff131f5edac20cb984344a2d28ec) - update namespace TypeScript declarations [(#3190)](https://github.com/stdlib-js/stdlib/pull/3190)
@@ -754,6 +756,8 @@ A total of 3 people contributed to this release. Thank you to the following cont
754756

755757
<details>
756758

759+
- [`e661213`](https://github.com/stdlib-js/stdlib/commit/e66121352ef767cdb87d19e938b1eccf7970fa3a) - **feat:** update namespace TypeScript declarations [(#4706)](https://github.com/stdlib-js/stdlib/pull/4706) _(by stdlib-bot)_
760+
- [`cff470f`](https://github.com/stdlib-js/stdlib/commit/cff470f9608165100c8c122fce70c40b1af864ec) - **docs:** update namespace table of contents (#4708) _(by stdlib-bot, Planeshifter)_
757761
- [`741b6f1`](https://github.com/stdlib-js/stdlib/commit/741b6f1df8ce11e77fb22c279cee6bbae3323176) - **feat:** add `spreadDimensions` to namespace _(by Athan Reines)_
758762
- [`3767255`](https://github.com/stdlib-js/stdlib/commit/3767255c7cfe85f09cea5c007e21297cd628245d) - **feat:** add `ndarray/base/spread-dimensions` _(by Athan Reines)_
759763
- [`712a9a8`](https://github.com/stdlib-js/stdlib/commit/712a9a8554f59fdfe520c4e2daafdbfd93637c76) - **fix:** compute singleton strides as if strides computed apriori _(by Athan Reines)_

base/README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ var o = ns;
9898
- <span class="signature">[`nextCartesianIndex( shape, order, idx, dim )`][@stdlib/ndarray/base/next-cartesian-index]</span><span class="delimiter">: </span><span class="description">return the next Cartesian index (i.e., set of subscripts/dimension indices).</span>
9999
- <span class="signature">[`nonsingletonDimensions( shape )`][@stdlib/ndarray/base/nonsingleton-dimensions]</span><span class="delimiter">: </span><span class="description">return the number of non-singleton dimensions.</span>
100100
- <span class="signature">[`normalizeIndex( idx, max )`][@stdlib/ndarray/base/normalize-index]</span><span class="delimiter">: </span><span class="description">normalize an index to the interval `[0,max]`.</span>
101+
- <span class="signature">[`normalizeIndices( indices, max )`][@stdlib/ndarray/base/normalize-indices]</span><span class="delimiter">: </span><span class="description">normalize a list of indices to the interval `[0,max]`.</span>
101102
- <span class="signature">[`nullaryLoopOrder( shape, stridesX )`][@stdlib/ndarray/base/nullary-loop-interchange-order]</span><span class="delimiter">: </span><span class="description">reorder ndarray dimensions and associated strides for loop interchange.</span>
102103
- <span class="signature">[`nullaryBlockSize( dtypeX )`][@stdlib/ndarray/base/nullary-tiling-block-size]</span><span class="delimiter">: </span><span class="description">resolve a loop block size for multi-dimensional array tiled loops.</span>
103104
- <span class="signature">[`nullary( arrays, fcn )`][@stdlib/ndarray/base/nullary]</span><span class="delimiter">: </span><span class="description">apply a nullary callback and assign results to elements in an output ndarray.</span>
@@ -124,13 +125,16 @@ var o = ns;
124125
- <span class="signature">[`sliceFrom( x, start, strict, writable )`][@stdlib/ndarray/base/slice-from]</span><span class="delimiter">: </span><span class="description">return a shifted view of an input ndarray.</span>
125126
- <span class="signature">[`sliceTo( x, stop, strict, writable )`][@stdlib/ndarray/base/slice-to]</span><span class="delimiter">: </span><span class="description">return a truncated view of an input ndarray.</span>
126127
- <span class="signature">[`slice( x, slice, strict, writable )`][@stdlib/ndarray/base/slice]</span><span class="delimiter">: </span><span class="description">return a view of an input ndarray.</span>
128+
- <span class="signature">[`spreadDimensions( ndims, x, dims )`][@stdlib/ndarray/base/spread-dimensions]</span><span class="delimiter">: </span><span class="description">expand the shape of an array to a specified dimensionality by spreading its dimensions to specified dimension indices and inserting dimensions of size one for the remaining dimensions.</span>
127129
- <span class="signature">[`stride( x, dim )`][@stdlib/ndarray/base/stride]</span><span class="delimiter">: </span><span class="description">return the stride along a specified dimension for a provided ndarray.</span>
128130
- <span class="signature">[`strides( x, copy )`][@stdlib/ndarray/base/strides]</span><span class="delimiter">: </span><span class="description">return the strides of a provided ndarray.</span>
129131
- <span class="signature">[`strides2offset( shape, strides )`][@stdlib/ndarray/base/strides2offset]</span><span class="delimiter">: </span><span class="description">determine the index offset which specifies the location of the first indexed value in a multidimensional array based on a stride array.</span>
130132
- <span class="signature">[`strides2order( strides )`][@stdlib/ndarray/base/strides2order]</span><span class="delimiter">: </span><span class="description">determine the order of a multidimensional array based on a provided stride array.</span>
131133
- <span class="signature">[`sub2ind( shape, strides, offset, ...subscripts, mode )`][@stdlib/ndarray/base/sub2ind]</span><span class="delimiter">: </span><span class="description">convert subscripts to a linear index.</span>
132134
- <span class="signature">[`ndarray2array( buffer, shape, strides, offset, order )`][@stdlib/ndarray/base/to-array]</span><span class="delimiter">: </span><span class="description">convert an ndarray buffer to a generic array.</span>
135+
- <span class="signature">[`toNormalizedIndices( indices, max )`][@stdlib/ndarray/base/to-normalized-indices]</span><span class="delimiter">: </span><span class="description">normalize a list of indices to the interval `[0,max]`.</span>
133136
- <span class="signature">[`toReversed( x )`][@stdlib/ndarray/base/to-reversed]</span><span class="delimiter">: </span><span class="description">return a new ndarray where the order of elements of an input ndarray is reversed along each dimension.</span>
137+
- <span class="signature">[`toUniqueNormalizedIndices( indices, max )`][@stdlib/ndarray/base/to-unique-normalized-indices]</span><span class="delimiter">: </span><span class="description">return a list of unique indices after normalizing to the interval `[0,max]`.</span>
134138
- <span class="signature">[`transpose( x )`][@stdlib/ndarray/base/transpose]</span><span class="delimiter">: </span><span class="description">transpose a matrix (or a stack of matrices).</span>
135139
- <span class="signature">[`unaryBy( arrays, fcn, clbk[, thisArg] )`][@stdlib/ndarray/base/unary-by]</span><span class="delimiter">: </span><span class="description">apply a unary function to each element in an input ndarray according to a callback function and assign results to elements in an output ndarray.</span>
136140
- <span class="signature">[`unaryLoopOrder( shape, stridesX, stridesY )`][@stdlib/ndarray/base/unary-loop-interchange-order]</span><span class="delimiter">: </span><span class="description">reorder ndarray dimensions and associated strides for loop interchange.</span>
@@ -307,6 +311,8 @@ console.log( objectKeys( ns ) );
307311

308312
[@stdlib/ndarray/base/normalize-index]: https://github.com/stdlib-js/ndarray/tree/main/base/normalize-index
309313

314+
[@stdlib/ndarray/base/normalize-indices]: https://github.com/stdlib-js/ndarray/tree/main/base/normalize-indices
315+
310316
[@stdlib/ndarray/base/nullary-loop-interchange-order]: https://github.com/stdlib-js/ndarray/tree/main/base/nullary-loop-interchange-order
311317

312318
[@stdlib/ndarray/base/nullary-tiling-block-size]: https://github.com/stdlib-js/ndarray/tree/main/base/nullary-tiling-block-size
@@ -359,6 +365,8 @@ console.log( objectKeys( ns ) );
359365

360366
[@stdlib/ndarray/base/slice]: https://github.com/stdlib-js/ndarray/tree/main/base/slice
361367

368+
[@stdlib/ndarray/base/spread-dimensions]: https://github.com/stdlib-js/ndarray/tree/main/base/spread-dimensions
369+
362370
[@stdlib/ndarray/base/stride]: https://github.com/stdlib-js/ndarray/tree/main/base/stride
363371

364372
[@stdlib/ndarray/base/strides]: https://github.com/stdlib-js/ndarray/tree/main/base/strides
@@ -371,8 +379,12 @@ console.log( objectKeys( ns ) );
371379

372380
[@stdlib/ndarray/base/to-array]: https://github.com/stdlib-js/ndarray/tree/main/base/to-array
373381

382+
[@stdlib/ndarray/base/to-normalized-indices]: https://github.com/stdlib-js/ndarray/tree/main/base/to-normalized-indices
383+
374384
[@stdlib/ndarray/base/to-reversed]: https://github.com/stdlib-js/ndarray/tree/main/base/to-reversed
375385

386+
[@stdlib/ndarray/base/to-unique-normalized-indices]: https://github.com/stdlib-js/ndarray/tree/main/base/to-unique-normalized-indices
387+
376388
[@stdlib/ndarray/base/transpose]: https://github.com/stdlib-js/ndarray/tree/main/base/transpose
377389

378390
[@stdlib/ndarray/base/unary-by]: https://github.com/stdlib-js/ndarray/tree/main/base/unary-by

base/assert/README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ var o = ns;
5050
- <span class="signature">[`isBufferLengthCompatible( len, shape, strides, offset )`][@stdlib/ndarray/base/assert/is-buffer-length-compatible]</span><span class="delimiter">: </span><span class="description">determine if a buffer length is compatible with ndarray meta data.</span>
5151
- <span class="signature">[`isCastingMode( value )`][@stdlib/ndarray/base/assert/is-casting-mode]</span><span class="delimiter">: </span><span class="description">test if an input value is a supported ndarray casting mode.</span>
5252
- <span class="signature">[`isColumnMajorContiguous( shape, strides, offset )`][@stdlib/ndarray/base/assert/is-column-major-contiguous]</span><span class="delimiter">: </span><span class="description">determine if an array is column-major contiguous.</span>
53+
- <span class="signature">[`isColumnMajorString( value )`][@stdlib/ndarray/base/assert/is-column-major-string]</span><span class="delimiter">: </span><span class="description">test whether an input value is the string representing column-major order.</span>
5354
- <span class="signature">[`isColumnMajor( strides )`][@stdlib/ndarray/base/assert/is-column-major]</span><span class="delimiter">: </span><span class="description">given a stride array, determine whether an array is column-major.</span>
5455
- <span class="signature">[`isComplexFloatingPointDataType( value )`][@stdlib/ndarray/base/assert/is-complex-floating-point-data-type]</span><span class="delimiter">: </span><span class="description">test if an input value is a supported ndarray complex-valued floating-point data type.</span>
5556
- <span class="signature">[`isContiguous( shape, strides, offset )`][@stdlib/ndarray/base/assert/is-contiguous]</span><span class="delimiter">: </span><span class="description">determine if an array is contiguous.</span>
@@ -64,6 +65,7 @@ var o = ns;
6465
- <span class="signature">[`isRealDataType( value )`][@stdlib/ndarray/base/assert/is-real-data-type]</span><span class="delimiter">: </span><span class="description">test if an input value is a supported ndarray real-valued data type.</span>
6566
- <span class="signature">[`isRealFloatingPointDataType( value )`][@stdlib/ndarray/base/assert/is-real-floating-point-data-type]</span><span class="delimiter">: </span><span class="description">test if an input value is a supported ndarray real-valued floating-point data type.</span>
6667
- <span class="signature">[`isRowMajorContiguous( shape, strides, offset )`][@stdlib/ndarray/base/assert/is-row-major-contiguous]</span><span class="delimiter">: </span><span class="description">determine if an array is row-major contiguous.</span>
68+
- <span class="signature">[`isRowMajorString( value )`][@stdlib/ndarray/base/assert/is-row-major-string]</span><span class="delimiter">: </span><span class="description">test whether an input value is the string representing row-major order.</span>
6769
- <span class="signature">[`isRowMajor( strides )`][@stdlib/ndarray/base/assert/is-row-major]</span><span class="delimiter">: </span><span class="description">given a stride array, determine whether an array is row-major.</span>
6870
- <span class="signature">[`isSafeDataTypeCast( from, to )`][@stdlib/ndarray/base/assert/is-safe-data-type-cast]</span><span class="delimiter">: </span><span class="description">determine whether an ndarray data type can be safely cast to another ndarray data type.</span>
6971
- <span class="signature">[`isSameKindDataTypeCast( from, to )`][@stdlib/ndarray/base/assert/is-same-kind-data-type-cast]</span><span class="delimiter">: </span><span class="description">determine whether an ndarray data type can be safely cast to, or is of the same "kind" as, another ndarray data type.</span>
@@ -126,6 +128,8 @@ console.log( objectKeys( ns ) );
126128

127129
[@stdlib/ndarray/base/assert/is-column-major-contiguous]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-column-major-contiguous
128130

131+
[@stdlib/ndarray/base/assert/is-column-major-string]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-column-major-string
132+
129133
[@stdlib/ndarray/base/assert/is-column-major]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-column-major
130134

131135
[@stdlib/ndarray/base/assert/is-complex-floating-point-data-type]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-complex-floating-point-data-type
@@ -154,6 +158,8 @@ console.log( objectKeys( ns ) );
154158

155159
[@stdlib/ndarray/base/assert/is-row-major-contiguous]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-row-major-contiguous
156160

161+
[@stdlib/ndarray/base/assert/is-row-major-string]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-row-major-string
162+
157163
[@stdlib/ndarray/base/assert/is-row-major]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-row-major
158164

159165
[@stdlib/ndarray/base/assert/is-safe-data-type-cast]: https://github.com/stdlib-js/ndarray/tree/main/base/assert/is-safe-data-type-cast

base/assert/docs/types/index.d.ts

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import isBufferLengthCompatibleShape = require( './../../../../base/assert/is-bu
2828
import isCastingMode = require( './../../../../base/assert/is-casting-mode' );
2929
import isColumnMajor = require( './../../../../base/assert/is-column-major' );
3030
import isColumnMajorContiguous = require( './../../../../base/assert/is-column-major-contiguous' );
31+
import isColumnMajorString = require( './../../../../base/assert/is-column-major-string' );
3132
import isComplexFloatingPointDataType = require( './../../../../base/assert/is-complex-floating-point-data-type' );
3233
import isContiguous = require( './../../../../base/assert/is-contiguous' );
3334
import isDataType = require( './../../../../base/assert/is-data-type' );
@@ -42,6 +43,7 @@ import isRealDataType = require( './../../../../base/assert/is-real-data-type' )
4243
import isRealFloatingPointDataType = require( './../../../../base/assert/is-real-floating-point-data-type' );
4344
import isRowMajor = require( './../../../../base/assert/is-row-major' );
4445
import isRowMajorContiguous = require( './../../../../base/assert/is-row-major-contiguous' );
46+
import isRowMajorString = require( './../../../../base/assert/is-row-major-string' );
4547
import isSafeDataTypeCast = require( './../../../../base/assert/is-safe-data-type-cast' );
4648
import isSameKindDataTypeCast = require( './../../../../base/assert/is-same-kind-data-type-cast' );
4749
import isSignedIntegerDataType = require( './../../../../base/assert/is-signed-integer-data-type' );
@@ -262,6 +264,24 @@ interface Namespace {
262264
*/
263265
isColumnMajorContiguous: typeof isColumnMajorContiguous;
264266

267+
/**
268+
* Tests whether an input value is the string representing column-major order.
269+
*
270+
* @param v - value to test
271+
* @returns boolean result
272+
*
273+
* @example
274+
* var bool = ns.isColumnMajorString( 'column-major' );
275+
* // returns true
276+
*
277+
* bool = ns.isColumnMajorString( 'row-major' );
278+
* // returns false
279+
*
280+
* bool = ns.isColumnMajorString( 'foo' );
281+
* // returns false
282+
*/
283+
isColumnMajorString: typeof isColumnMajorString;
284+
265285
/**
266286
* Tests whether an input value is a supported ndarray complex-valued floating-point data type.
267287
*
@@ -747,6 +767,24 @@ interface Namespace {
747767
*/
748768
isRowMajorContiguous: typeof isRowMajorContiguous;
749769

770+
/**
771+
* Tests whether an input value is the string representing row-major order.
772+
*
773+
* @param v - value to test
774+
* @returns boolean result
775+
*
776+
* @example
777+
* var bool = ns.isRowMajorString( 'row-major' );
778+
* // returns true
779+
*
780+
* bool = ns.isRowMajorString( 'column-major' );
781+
* // returns false
782+
*
783+
* bool = ns.isRowMajorString( 'foo' );
784+
* // returns false
785+
*/
786+
isRowMajorString: typeof isRowMajorString;
787+
750788
/**
751789
* Returns a boolean indicating if a provided ndarray data type can be safely cast to another ndarray data type.
752790
*

0 commit comments

Comments
 (0)