Skip to content

Commit 30864c2

Browse files
committed
Update for deprecated into_shape
1 parent 5a20985 commit 30864c2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/summary_statistics.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ fn test_with_array_of_floats() {
164164
epsilon = 1e-12
165165
);
166166

167-
let data = a.into_shape((2, 5, 5)).unwrap();
167+
let data = a.into_shape_with_order((2, 5, 5)).unwrap();
168168
let weights = array![0.1, 0.5, 0.25, 0.15, 0.2];
169169
assert_abs_diff_eq!(
170170
data.weighted_mean_axis(Axis(1), &weights).unwrap(),
@@ -254,7 +254,7 @@ fn mean_axis_eq_if_uniform_weights() {
254254
let depth = a.len() / 12;
255255
a.truncate(depth * 3 * 4);
256256
let weights = Array1::from_elem(depth, 1.0 / depth as f64);
257-
let a = Array1::from(a).into_shape((depth, 3, 4)).unwrap();
257+
let a = Array1::from(a).into_shape_with_order((depth, 3, 4)).unwrap();
258258
let ma = a.mean_axis(Axis(0)).unwrap();
259259
let wm = a.weighted_mean_axis(Axis(0), &weights).unwrap();
260260
let ws = a.weighted_sum_axis(Axis(0), &weights).unwrap();
@@ -288,7 +288,7 @@ fn weighted_var_algo_eq_simple_algo() {
288288
}
289289
let depth = a.len() / 12;
290290
a.truncate(depth * 3 * 4);
291-
let a = Array1::from(a).into_shape((depth, 3, 4)).unwrap();
291+
let a = Array1::from(a).into_shape_with_order((depth, 3, 4)).unwrap();
292292
let mut success = true;
293293
for axis in 0..3 {
294294
let axis = Axis(axis);

0 commit comments

Comments
 (0)