FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

tensorflow.estimator · sattisvar/TensorFlow.NET@bbd76d5 · GitHub

Repository navigation

Commit bbd76d5

Browse files
committed
tensorflow.estimator
1 parent fa41aac commit bbd76d5

19 files changed

Lines changed: 244 additions & 68 deletions

File tree

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
/*****************************************************************************
2+
Copyright 2018 The TensorFlow.NET Authors. All Rights Reserved.
3+
4+
Licensed under the Apache License, Version 2.0 (the "License");
5+
you may not use this file except in compliance with the License.
6+
You may obtain a copy of the License at
7+
8+
http://www.apache.org/licenses/LICENSE-2.0
9+
10+
Unless required by applicable law or agreed to in writing, software
11+
distributed under the License is distributed on an "AS IS" BASIS,
12+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
See the License for the specific language governing permissions and
14+
limitations under the License.
15+
******************************************************************************/
16+
17+
using System;
18+
using static Tensorflow.Binding;
19+
using Tensorflow.Estimators;
20+
21+
namespace Tensorflow
22+
{
23+
public partial class tensorflow
24+
{
25+
public Estimator_Internal estimator { get; } = new Estimator_Internal();
26+
27+
public class Estimator_Internal
28+
{
29+
public Estimator Estimator(RunConfig config)
30+
=> new Estimator(config: config);
31+
32+
public RunConfig RunConfig(string model_dir)
33+
=> new RunConfig(model_dir: model_dir);
34+
35+
public void train_and_evaluate()
36+
=> Training.train_and_evaluate();
37+
}
38+
}
39+
}

‎src/TensorFlowNET.Core/Estimator/EstimatorV2.cs‎

Lines changed: 0 additions & 36 deletions
This file was deleted.

‎src/TensorFlowNET.Core/Estimator/IEstimator.cs‎

Lines changed: 0 additions & 7 deletions
This file was deleted.

‎src/TensorFlowNET.Core/Estimator/TrainingExecutor.cs‎

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
5+
namespace Tensorflow.Estimators
6+
{
7+
public class Estimator : IObjectLife
8+
{
9+
public RunConfig config;
10+
11+
public Estimator(RunConfig config)
12+
{
13+
this.config = config;
14+
}
15+
16+
public void __init__()
17+
{
18+
throw new NotImplementedException();
19+
}
20+
21+
public void __enter__()
22+
{
23+
throw new NotImplementedException();
24+
}
25+
26+
public void __del__()
27+
{
28+
throw new NotImplementedException();
29+
}
30+
31+
public void __exit__()
32+
{
33+
throw new NotImplementedException();
34+
}
35+
36+
public void Dispose()
37+
{
38+
throw new NotImplementedException();
39+
}
40+
}
41+
}

src/TensorFlowNET.Core/Estimator/HyperParams.cs renamed to src/TensorFlowNET.Core/Estimators/HyperParams.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using System.IO;
22

3-
namespace Tensorflow.Estimator
3+
namespace Tensorflow.Estimators
44
{
55
public class HyperParams
66
{
Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
### TensorFlow Estimator
1+
# TensorFlow Estimator
22

33
TensorFlow Estimator is a high-level TensorFlow API that greatly simplifies machine learning programming. Estimators encapsulate training, evaluation, prediction, and exporting for your model.
44

5-
Guide: <https://www.tensorflow.org/guide/estimators>
65

6+
7+
https://github.com/tensorflow/estimator
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
using System;
2+
3+
namespace Tensorflow.Estimators
4+
{
5+
public class RunConfig
6+
{
7+
public RunConfig(string model_dir)
8+
{
9+
10+
}
11+
}
12+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
5+
namespace Tensorflow.Estimators
6+
{
7+
public class Training
8+
{
9+
public static void train_and_evaluate()
10+
{
11+
var executor = new _TrainingExecutor();
12+
executor.run();
13+
}
14+
}
15+
}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
5+
namespace Tensorflow.Estimators
6+
{
7+
public class _TrainingExecutor
8+
{
9+
Estimator _estimator;
10+
11+
public _TrainingExecutor(Estimator estimator)
12+
{
13+
14+
}
15+
16+
public void run()
17+
{
18+
run_local();
19+
}
20+
21+
private void run_local()
22+
{
23+
24+
}
25+
}
26+
}

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL