You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

GraphModeTestBase.cs 509 B

4 years ago
4 years ago
4 years ago
1234567891011121314151617181920212223
  1. using Microsoft.VisualStudio.TestTools.UnitTesting;
  2. using Tensorflow;
  3. using static Tensorflow.Binding;
  4. namespace TensorFlowNET.UnitTest
  5. {
  6. public class GraphModeTestBase : PythonTest
  7. {
  8. protected Graph graph;
  9. [TestInitialize]
  10. public void TestInit()
  11. {
  12. tf.compat.v1.disable_eager_execution();
  13. graph = tf.Graph().as_default();
  14. }
  15. [TestCleanup]
  16. public void TestClean()
  17. {
  18. graph.Exit();
  19. }
  20. }
  21. }