Commit 6f1a8db6 authored by Tiago de Freitas Pereira's avatar Tiago de Freitas Pereira

Merge branch 'issue-64' into 'master'

For some reason tensorflow 1.9 changed such index from 1 to 0

Closes #64

See merge request !69
parents 920ec198 4802606d
Pipeline #24071 passed with stages
in 26 minutes and 24 seconds
......@@ -169,7 +169,7 @@ def test_eval():
with open(evaluated_path) as f:
doc = f.read()
assert '1' in doc, doc
assert '0' in doc, doc
assert '200' in doc, doc
print('Train and evaluate a dummy network')
......@@ -201,8 +201,7 @@ def test_eval_keep_n_model():
assert os.path.exists(evaluated_path), evaluated_path
with open(evaluated_path) as f:
doc = f.read()
assert '1 ' in doc, doc
assert '0 ' in doc, doc
assert '200 ' in doc, doc
assert len(glob('{}/model.ckpt-*'.format(eval_dir))) == 3, \
os.listdir(eval_dir)
......
......@@ -20,7 +20,7 @@ def test_early_stopping_linear_classifier():
hooks = [
EarlyStopping(
'linear/head/metrics/accuracy/value', min_delta=0.001, patience=1),
'linear/metrics/accuracy/total', min_delta=0.001, patience=1),
]
train_spec = tf.estimator.TrainSpec(input_fn=train_input_fn)
......
......@@ -171,7 +171,7 @@ Explicitly triggering the estimator
...................................
.. doctest::
+SKIP
>>> estimator = Logits(
... architecture,
... optimizer=tf.train.GradientDescentOptimizer(1e-4),
......@@ -182,7 +182,7 @@ Explicitly triggering the estimator
... model_dir=model_dir,
... )
>>> tf.estimator.train_and_evaluate(estimator, train_spec, eval_spec)
Triggering the estimator via command line
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment