You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -593,6 +593,8 @@
593
593
594
594
### Bug Fixes
595
595
596
+
- [`5795b39`](https://github.com/stdlib-js/stdlib/commit/5795b39e0f0f1d7ccae3ea1ed43809b7ff78b77d) - determine layout based on physical layout
597
+
- [`c20c5d6`](https://github.com/stdlib-js/stdlib/commit/c20c5d602a0f897e86d7fbd83180fec84c535984) - determine layout based on physical layout
596
598
- [`e47ee45`](https://github.com/stdlib-js/stdlib/commit/e47ee4551cf19ad584361fb80c9eed84ff9ea792) - resolve bugs, docs, and JSDoc type errors [(#11337)](https://github.com/stdlib-js/stdlib/pull/11337)
597
599
- [`d4710cd`](https://github.com/stdlib-js/stdlib/commit/d4710cd4279abf2e1e8383ce0e1bfbfadf4b609a) - improve type specificity with overloads
598
600
- [`762f410`](https://github.com/stdlib-js/stdlib/commit/762f410098b29afa3823ab1191553101db0dcead) - correct grammar in ndarray type test comments [(#11154)](https://github.com/stdlib-js/stdlib/pull/11154)
@@ -836,6 +838,8 @@ A total of 49 issues were closed in this release:
836
838
837
839
<details>
838
840
841
+
- [`5795b39`](https://github.com/stdlib-js/stdlib/commit/5795b39e0f0f1d7ccae3ea1ed43809b7ff78b77d) - **fix:** determine layout based on physical layout _(by Athan Reines)_
842
+
- [`c20c5d6`](https://github.com/stdlib-js/stdlib/commit/c20c5d602a0f897e86d7fbd83180fec84c535984) - **fix:** determine layout based on physical layout _(by Athan Reines)_
thrownewRangeError(format('invalid argument. First argument must be greater than or equal to the number of dimensions in the input ndarray. Number of dimensions: %d. Value: `%d`.',sh.length,ndims));
107
+
o=strides2order(st);
108
+
if(o===0||o===3){
109
+
// Fallback to stated layout when unable to infer the underlying physical layout:
110
+
isrm=isRowMajorString(ord);
111
+
}else{
112
+
isrm=(o===1);
113
+
}
114
+
N=sh.length;
115
+
116
+
if(N>ndims){
117
+
thrownewRangeError(format('invalid argument. First argument must be greater than or equal to the number of dimensions in the input ndarray. Number of dimensions: %d. Value: `%d`.',N,ndims));
thrownewError(format('invalid argument. Must provide unique dimension indices. Value: `[%s]`.',join(dims,', ')));
115
126
}
116
-
if(d.length!==sh.length){
117
-
thrownewRangeError(format('invalid argument. Must provide the same number of dimension indices as the number of dimensions in the input ndarray. Number of dimensions: %d. Value: `[%s]`.',sh.length,join(dims,', ')));
127
+
if(d.length!==N){
128
+
thrownewRangeError(format('invalid argument. Must provide the same number of dimension indices as the number of dimensions in the input ndarray. Number of dimensions: %d. Value: `[%s]`.',N,join(dims,', ')));
118
129
}
119
130
if(d.length&&!isSortedAscending(d)){
120
131
thrownewError(format('invalid argument. Must provide dimension indices which resolve to nonnegative indices arranged in ascending order. Value: `[%s]`.',join(dims,', ')));
121
132
}
122
133
// When provided a zero-dimensional array, every expanded dimension is a singleton dimension having zero stride...
0 commit comments