Browse Source

correct namespace

passing
pull/1184/head
Alexander 1 year ago
parent
commit
c5b4928bd6
2 changed files with 2 additions and 6 deletions
  1. +0
    -4
      test/TensorFlowNET.UnitTest/Training/BasicLinearModel.cs
  2. +2
    -2
      test/TensorFlowNET.UnitTest/Training/GradientDescentOptimizerTests.cs

+ 0
- 4
test/TensorFlowNET.UnitTest/Training/BasicLinearModel.cs View File

@@ -15,10 +15,6 @@ namespace TensorFlowNET.UnitTest.Training
[TestMethod] [TestMethod]
public void LinearRegression() public void LinearRegression()
{ {
var graph = tf.Graph().as_default();
var sess = new Session(graph);
sess.as_default();

// Initialize the weights to `5.0` and the bias to `0.0` // Initialize the weights to `5.0` and the bias to `0.0`
// In practice, these should be initialized to random values (for example, with `tf.random.normal`) // In practice, these should be initialized to random values (for example, with `tf.random.normal`)
var W = tf.Variable(5.0f); var W = tf.Variable(5.0f);


+ 2
- 2
test/TensorFlowNET.UnitTest/Training/GradientDescentOptimizerTests.cs View File

@@ -1,10 +1,10 @@
using Microsoft.VisualStudio.TestTools.UnitTesting; using Microsoft.VisualStudio.TestTools.UnitTesting;
using System; using System;
using Tensorflow;
using Tensorflow.NumPy; using Tensorflow.NumPy;
using TensorFlowNET.UnitTest;
using static Tensorflow.Binding; using static Tensorflow.Binding;


namespace Tensorflow.Keras.UnitTest.Optimizers
namespace TensorFlowNET.UnitTest.Training
{ {
[TestClass] [TestClass]
public class GradientDescentOptimizerTest : PythonTest public class GradientDescentOptimizerTest : PythonTest


Loading…
Cancel
Save