Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 57feb65

Browse files
comment IndexedSlices test
1 parent a9dad3c commit 57feb65

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

test/TensorFlowNET.Graph.UnitTest/GradientTest/GradientTest.cs

+6-2
Original file line numberDiff line numberDiff line change
@@ -488,17 +488,20 @@ public void testNoGradientForStringOutputs()
488488
// self.assertTrue(isinstance(grads[0], ops.Tensor))
489489
}
490490

491-
[Ignore("FIXME")]
491+
[Ignore("TODO: CompositeTensors are not supported yet.")]
492492
[TestMethod]
493493
public void testSingletonIndexedSlices()
494494
{
495495
tf.Graph().as_default();
496496

497+
// TODO: uncomment when CompositeTensors are supported.
498+
/*
497499
var x = tf.placeholder(TF_DataType.TF_FLOAT);
498500
var y = tf.identity(x);
499501
var dy_indices = tf.placeholder(TF_DataType.TF_INT32);
500502
var dy_values = tf.placeholder(TF_DataType.TF_FLOAT);
501-
Tensor dy = new IndexedSlices(dy_values, dy_indices);
503+
var dy = new IndexedSlices(dy_values, dy_indices);
504+
502505
var dx = tf.gradients(new[] { y }, new[] { x }, grad_ys: new[] { dy })[0];
503506
// The IndexedSlices gradient of tf.identity is the identity map.
504507
using (var sess = self.cached_session())
@@ -514,6 +517,7 @@ public void testSingletonIndexedSlices()
514517
var vdy = result[1];
515518
self.assertEqual(vdx, vdy);
516519
}
520+
*/
517521

518522
}
519523

0 commit comments

Comments
 (0)