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
The testcase below fails (second assert) on windows 10 using beta 2 (both CPU and CUDA 9.2). Removing specified index or using NDArrayIndex#interval causes testcase to pass.
@Test
public void testSpecifiedIndexArraySize1() {
final long[] shapeOk = {2, 2, 2, 2};
final long[] shapeNok = {1, 2, 2, 1};
final INDArray ok = Nd4j.create(shapeOk);
final INDArrayIndex[] noChange = IntStream.range(0, shapeOk.length).mapToObj(dummy -> NDArrayIndex.all()).toArray(INDArrayIndex[]::new);
noChange[1] = new SpecifiedIndex(IntStream.range(0, (int) shapeOk[1]).toArray());
assertArrayEquals("Incorrect shape!", ok.shape(), ok.get(noChange).shape());
final INDArray nok = Nd4j.create(shapeNok);
final INDArrayIndex[] noChangeAgain = IntStream.range(0, shapeOk.length).mapToObj(dummy -> NDArrayIndex.all()).toArray(INDArrayIndex[]::new);
// Comment line below to make testcase pass
noChangeAgain[1] = new SpecifiedIndex(IntStream.range(0, (int) shapeNok[1]).toArray());
// Uncomment line below to make testcase pass
// noChangeAgain[1] = NDArrayIndex.interval(0, shapeNok[1]);
assertArrayEquals("Incorrect shape!", nok.shape(), nok.get(noChangeAgain).shape());
}
The text was updated successfully, but these errors were encountered:
* #6327 INDArray.put with SpecifiedIndex
* #6341 - SpecifiedIndex with single value no longer collapses dimensions
* Another indexing fix
* #6343 TransferLearning nOutReplace fix
The testcase below fails (second assert) on windows 10 using beta 2 (both CPU and CUDA 9.2). Removing specified index or using NDArrayIndex#interval causes testcase to pass.
The text was updated successfully, but these errors were encountered: