Deep Learning Cookbook by Douwe Osinga

Deep Learning Cookbook by Douwe Osinga

Author:Douwe Osinga
Language: eng
Format: epub, mobi
Publisher: O'Reilly Media
Published: 2018-04-24T16:00:00+00:00


python -m bin.infer \ --tasks " - class: DecodeText" \ --model_dir $SEQ2SEQROOT/model_large \ --input_pipeline " class: ParallelTextInputPipeline params: source_files: - '/tmp/test_questions.txt'"

A simple conversation works:

> hi hi > what is your name ? sam barker > how do you feel ? Fine > good night good night

With more complex sentences it is a bit hit or miss.

Discussion

The seq2seq model’s primary use case seems to be automatic translation, although it has also been effective for captioning images and summarizing texts. The documentation contains a tutorial on how to train a model that learns decent English–German translations in weeks or months, depending on your hardware. Google claims that making a sequence-to-sequence model central to its machine translation efforts has improved the quality dramatically.

One interesting way to think about sequence-to-sequence mapping is to see it as an embedding process. For translations, both the source and the target sentence are projected into a multidimensional space and the model learns a projection such that sentences that mean the same thing end up around the same point in that space. This leads to the intriguing possibility of “zero-shot” translations; if a model learns to translate between Finnish and English and then later between English and Greek and it uses the same semantic space, it can also be used to directly translate between Finnish and Greek. This then opens up the possibility of “thought vectors,” embeddings for relatively complex ideas that have similar properties to the “word vectors” we saw in Chapter 3.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.