Skip to content
This repository was archived by the owner on Jul 7, 2023. It is now read-only.

v1.3.1 #451

Merged
merged 11 commits into from
Dec 1, 2017
7 changes: 2 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,12 +126,9 @@ t2t-decoder \
--output_dir=$TRAIN_DIR \
--decode_hparams="beam_size=$BEAM_SIZE,alpha=$ALPHA" \
--decode_from_file=$DECODE_FILE
--decode_to_file=translation.en
```

# Eval BLEU

t2t-bleu --translation=translation.en --reference=ref-translation.de
cat $DECODE_FILE.$MODEL.$HPARAMS.beam$BEAM_SIZE.alpha$ALPHA.decodes
```

---

Expand Down
2 changes: 1 addition & 1 deletion docs/example_life.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ hooks in the `Problem` class and the model's `HParams` object (typically
registered in the model's file and specified by the `--hparams_set` flag).

The entire input pipeline is implemented with the new `tf.data.Dataset` API
(previously `tf.contrib.data.Dataset`).
(previously `tf.data.Dataset`).

The key function in the codebase for the input pipeline is
[`data_reader.input_pipeline`](https://github.com/tensorflow/tensor2tensor/tree/master/tensor2tensor/utils/data_reader.py).
Expand Down
13 changes: 6 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

setup(
name='tensor2tensor',
version='1.3.0',
version='1.3.1',
description='Tensor2Tensor',
author='Google Inc.',
author_email='[email protected]',
Expand All @@ -15,16 +15,14 @@
package_data={
'tensor2tensor.data_generators': ['test_data/*'],
'tensor2tensor.visualization': [
'attention.js',
'TransformerVisualization.ipynb'
'attention.js', 'TransformerVisualization.ipynb'
],
},
scripts=[
'tensor2tensor/bin/t2t-trainer',
'tensor2tensor/bin/t2t-datagen',
'tensor2tensor/bin/t2t-decoder',
'tensor2tensor/bin/t2t-make-tf-configs',
'tensor2tensor/bin/t2t-bleu',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the deletion of t2t-bleu intentional?
(I can understand it, if yes.)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for noticing that. No, it was not intentional and likely due to a bad internal merge of the PR.

],
install_requires=[
'bz2file',
Expand All @@ -35,8 +33,8 @@
'six',
],
extras_require={
'tensorflow': ['tensorflow>=1.3.0'],
'tensorflow_gpu': ['tensorflow-gpu>=1.3.0'],
'tensorflow': ['tensorflow>=1.4.0'],
'tensorflow_gpu': ['tensorflow-gpu>=1.4.0'],
'tests': ['pytest', 'h5py', 'mock'],
},
classifiers=[
Expand All @@ -46,4 +44,5 @@
'License :: OSI Approved :: Apache Software License',
'Topic :: Scientific/Engineering :: Artificial Intelligence',
],
keywords='tensorflow machine learning',)
keywords='tensorflow machine learning',
)
200 changes: 0 additions & 200 deletions tensor2tensor/bin/t2t-bleu

This file was deleted.

Empty file modified tensor2tensor/bin/t2t-datagen
100755 → 100644
Empty file.
7 changes: 2 additions & 5 deletions tensor2tensor/bin/t2t-decoder
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,7 @@ import tensorflow as tf
flags = tf.flags
FLAGS = flags.FLAGS

flags.DEFINE_string("output_dir", "",
"Training directory where the latest checkpoint is used.")
flags.DEFINE_string("checkpoint_path", None,
"Path to the model checkpoint. Overrides output_dir.")
flags.DEFINE_string("output_dir", "", "Training directory to load from.")
flags.DEFINE_string("decode_from_file", None,
"Path to the source file for decoding")
flags.DEFINE_string("decode_to_file", None,
Expand Down Expand Up @@ -93,7 +90,7 @@ def main(_):
decoding.decode_interactively(estimator, decode_hp)
elif FLAGS.decode_from_file:
decoding.decode_from_file(estimator, FLAGS.decode_from_file, decode_hp,
FLAGS.decode_to_file, checkpoint_path=FLAGS.checkpoint_path)
FLAGS.decode_to_file)
else:
decoding.decode_from_dataset(
estimator,
Expand Down
Empty file modified tensor2tensor/bin/t2t-make-tf-configs
100755 → 100644
Empty file.
Empty file modified tensor2tensor/bin/t2t-trainer
100755 → 100644
Empty file.
Loading