Comments (3)
Hi, thanks for using kNN-BOX. Here's a short reply to your answer:
- Yes.
- Yes.
Detailed reply with more information:
- Yes. We used the smallest version because of resource limitations when M2M100 is combined with Robust kNN-MT. For your reference, 25GB+ GPU memory is needed to train Robust Combiner for M2M100-418M.
- Yes. The datastore is created for each language pair, so is the RobustCombiner. En->Cs M2M-100 BLEU score for M2M100 is 20.7, and when adding a En-Cs datastore based on the TED En->Cs training data the result will be improved to 22.3.
Here are scripts used to produce our result in attachment. Additional information that might be helpfull if you want to reproduce our results:
- Dataset:
- Tokenization: The TED dataset from Qi et al.,2018 is preprocessed using Moses tokenizer. So before using it with M2M100, you must detokenize it first, then use the spm model provided by M2M100 to do a correct SPM encoding.
- Binarization: The dict file to run
fairseq-preprocess
is nameddata_dict.128k.txt
, please note this.
- Datastore: The datastore size is provided below, "1.3M" means 1.3 million key-value pairs. The dimention of key is 1024.
cs | da | de | es | fr | it | nl | pl | pt | sv | |
---|---|---|---|---|---|---|---|---|---|---|
En-X | 2.9M | 1.2M | 4.6M | 5.1M | 5.8M | 5.6M | 4.7M | 4.7M | 1.2M | 1.4M |
X-En | 2.6M | 1.1M | 4.3M | 5.0M | 4.9M | 5.3M | 4.6M | 4.5M | 1.2M | 1.3M |
- Model: The M2M100 418M is a
transformer_wmt_en_de_big
model with the tasktranslation_multi_simple_epoch
and some model comfiguration changes. These are arguments that makes M2M100 special:
--task translation_multi_simple_epoch \
--source-lang $SRC --target-lang $TGT \
--lang-pairs $PROJECT_PATH/model/language_pairs_small_models.txt \
--fixed-dictionary $PROJECT_PATH/model/model_dict.128k.txt \
--encoder-normalize-before \
--decoder-normalize-before \
--dropout 0.3 \
--attention-dropout 0.1 \
--encoder-layers 12 \
--decoder-layers 12 \
--encoder-layerdrop 0.05 \
--decoder-layerdrop 0.05 \
--share-decoder-input-output-embed \
--share-all-embeddings \
--encoder-langtok src \
--decoder-langtok \
from knn-box.
I was able to replicate your results, thanks again!
from knn-box.
Thanks for your quick and detailed reply! I'll try again with this information :)
from knn-box.
Related Issues (20)
- missing 'transformer_wmt19_de_en' arch when I trying to reproduce the Adaptive-kNN HOT 6
- 关于plac-knn-mt运行报错 HOT 1
- KeyError: 'keys' HOT 4
- 基础NMT模型fairseq版本冲突问题 HOT 18
- 推理训练数据与标签不一致 HOT 4
- 感谢您指出这个问题。我们经过对checkpoint文件的对比,确认了您提出的现象,您可以按照下面的示例代码,对checkpoint进行一个小的修改,以正常加载,而kNN-BOX的代码无需修改:
- 关于vanilla-knn-mt inference报错 HOT 1
- 翻译错误:AssertionError: interactive mode, should have only one sentence HOT 1
- the blue-score always 0 HOT 5
- 关于运行速度的问题 HOT 3
- 关于计时的一个问题 HOT 3
- 关于RuntimeError: Error(s) in loading state_dict for VanillaKNNMT: HOT 1
- 您好,当我运行adaptive-knn-mt中的build_datasotre.sh时,报No moudle named'knnbox' HOT 12
- Multi-processing for huge datastore HOT 2
- FileNotFoundError: /home/demo/knn-box/knnbox/models HOT 1
- AssertionError: You should set pad mask first! 当我尝试运行bash build_datastore.sh HOT 4
- 运行vanilla-knn-mt-visual出错 HOT 9
- 运行adaptive knn-mt出错 HOT 2
- KeyError when load_faiss_index from a dumpped datastore
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from knn-box.