From 87c547a29caaa4048c7b3f3f2a2b5e570decb414 Mon Sep 17 00:00:00 2001 From: pepure Date: Wed, 1 Jul 2020 21:52:30 +0800 Subject: [PATCH] tensor init bug test --- test/TensorFlowNET.UnitTest/TF_API/TensorOperate.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/TensorFlowNET.UnitTest/TF_API/TensorOperate.cs b/test/TensorFlowNET.UnitTest/TF_API/TensorOperate.cs index b3ce7a4a..e8d959c4 100644 --- a/test/TensorFlowNET.UnitTest/TF_API/TensorOperate.cs +++ b/test/TensorFlowNET.UnitTest/TF_API/TensorOperate.cs @@ -23,6 +23,13 @@ namespace Tensorflow.UnitTest.TF_API Assert.IsTrue(Enumerable.SequenceEqual(transpose_a.numpy().ToArray(), b.numpy().ToArray())); } + [TestMethod] + public void InitTensorTest() + { + var a = tf.constant(new NDArray(new[, ,] { { { 1 }, { 2 }, { 3 } }, { { 4 }, { 5 }, { 6 } } })); + var b = tf.constant(new[, ,] { { { 1 }, { 2 }, { 3 } }, { { 4 }, { 5 }, { 6 } } }); + //Test Result : a is OK , and b is error . + } } }