Giter Club home page Giter Club logo

Comments (7)

XuezheMax avatar XuezheMax commented on August 15, 2024

Please contact fairseq for this issues.
Thanks.

from flowseq.

DeNeutoy avatar DeNeutoy commented on August 15, 2024

@XuezheMax - this is not a fairseq issue - prepare-wmt14en2de.sh does not create any files called *.ori. Because of the way these files are prepared by moses, it is difficult to recreate them (the bpe files are cleaned, meaning we cannot just use the raw {train,dev,test}.{en, de} files). Would you be able to share how you produced these files?

from flowseq.

DeNeutoy avatar DeNeutoy commented on August 15, 2024

In the meantime, I first cleaned the validation data (without peforming bpe segmentation on it) using this line https://github.com/pytorch/fairseq/blob/master/examples/translation/prepare-wmt14en2de.sh#L138

and then ran the BPE encoding script. This meant that both the word tokenized version and the bpe tokenized version get the same data filtered out (as it was done before). I then just copied the files to valid.{lang}.ori. I don't know if this is officially correct, because the data that is filtered is different depending on whether you run the filtering script before or after doing BPE, but 🤷‍♂

from flowseq.

violet-zct avatar violet-zct commented on August 15, 2024

@DeNeutoy *.ori are just the original tokenized files, we use them to compute the BLEU score. You can just put your original dev/test original tokenized files in the corresponding directories.

from flowseq.

DeNeutoy avatar DeNeutoy commented on August 15, 2024

@violet-zct you actually can't do that, I don't think - because the prepare-wmt14en2de.sh script does two things,

  1. BPE encodes {train, dev, test}.
  2. cleans the BPE encoded files, using the moses script, which reduces the number of examples in {train,dev}.

So, once the final dataset is produced, it does not have the same number of dev/test data points as in the original (because it has been cleaned), meaning that just putting the original files in the right place doesn't work.

from flowseq.

violet-zct avatar violet-zct commented on August 15, 2024

@DeNeutoy You can simply sed -r 's/(@@ )|(@@ ?$)//g' to restore the original segmentation of ``the '' dev file you are using from the BPE version.

from flowseq.

DeNeutoy avatar DeNeutoy commented on August 15, 2024

Oh great, thanks!

from flowseq.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.