//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test(expectedExceptions = IllegalArgumentException.class) public void testOutOfBounds() public virtual void testOutOfBounds() { //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final int[] indices = new int[] {2, 7, 1 }; int[] indices = new int[] { 2, 7, 1 }; //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final int[] dimensions = new int[] {5, 7, 3 }; int[] dimensions = new int[] { 5, 7, 3 }; FunctionUtils.toTensorIndex(indices, dimensions); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void testTensorIndexTest2() public virtual void testTensorIndexTest2() { //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final int[] indices = new int[] {2, 3 }; int[] indices = new int[] { 2, 3 }; //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final int[] dimensions = new int[] {5, 7 }; int[] dimensions = new int[] { 5, 7 }; //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final int index = FunctionUtils.toTensorIndex(indices, dimensions); int index = FunctionUtils.toTensorIndex(indices, dimensions); //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final int[] res = FunctionUtils.fromTensorIndex(index, dimensions); int[] res = FunctionUtils.fromTensorIndex(index, dimensions); assertEquals(indices[0], res[0], 0); assertEquals(indices[1], res[1], 0); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test(expectedExceptions = IllegalArgumentException.class) public void testWrongLength() public virtual void testWrongLength() { FunctionUtils.toTensorIndex(new int[] { 1, 2 }, new int[] { 1, 2, 3 }); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test(expectedExceptions = IllegalArgumentException.class) public void testNullDimensions1() public virtual void testNullDimensions1() { FunctionUtils.toTensorIndex(new int[] { 1, 2, 3 }, null); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test(expectedExceptions = IllegalArgumentException.class) public void testNullIndices() public virtual void testNullIndices() { FunctionUtils.toTensorIndex(null, new int[] { 1, 2, 3 }); }