Browse Source

Merge pull request #295 from PranovD/master

Added continue statement to as that is what is in the original python…
tags/v0.10
Haiping GitHub 6 years ago
parent
commit
e72fd53330
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions
  1. +2
    -1
      src/TensorFlowNET.Core/Framework/meta_graph.py.cs
  2. +2
    -2
      src/TensorFlowNET.Core/Train/Optimizer.cs

+ 2
- 1
src/TensorFlowNET.Core/Framework/meta_graph.py.cs View File

@@ -134,7 +134,8 @@ namespace Tensorflow
}
break;
default:
throw new NotImplementedException("import_scoped_meta_graph_with_return_elements");
Console.WriteLine("import_scoped_meta_graph_with_return_elements");
continue;
}
}
}


+ 2
- 2
src/TensorFlowNET.Core/Train/Optimizer.cs View File

@@ -199,8 +199,8 @@ namespace Tensorflow

if (!tf.context.executing_eagerly())
{
var train_op = ops.get_collection_ref(ops.GraphKeys.TRAIN_OP) as List<object>;
if (!train_op.Contains(apply_updates))
var train_op = ops.get_collection_ref(ops.GraphKeys.TRAIN_OP) as List<ITensorOrOperation>;
if (train_op != null && train_op.Contains(apply_updates))
train_op.Add(apply_updates);
}



Loading…
Cancel
Save