Skip to content
  1. Feb 09, 2019
    • Myle Ott's avatar
      Add fairseq to PyPI (#495) · fbd4cef9
      Myle Ott authored
      Summary:
      - fairseq can now be installed via pip: `pip install fairseq`
      - command-line tools are globally accessible: `fairseq-preprocess`, `fairseq-train`, `fairseq-generate`, etc.
      Pull Request resolved: https://github.com/pytorch/fairseq/pull/495
      
      Differential Revision: D14017761
      
      Pulled By: myleott
      
      fbshipit-source-id: 10c9f6634a3056074eac2f33324b4f1f404d4235
      v0.6.1
      fbd4cef9
  2. Feb 07, 2019
    • Ruty Rinott's avatar
      stitch preprocessing pipeline · cea0e4b9
      Ruty Rinott authored
      Summary:
      1. add call to binarization to complete preprocessing pipeline
      2. add ability to specify task to select the dictionary, and add a bert task
      3. Get rid of function calls that are no longer needed after moving functions from fairseq here
      
      Reviewed By: jingfeidu
      
      Differential Revision: D13977842
      
      fbshipit-source-id: ec9bbb4e98e62e12c20ba68bb52b8bcc94aee91d
      cea0e4b9
  3. Feb 06, 2019
  4. Feb 05, 2019
  5. Feb 01, 2019
    • Davide Caroselli's avatar
      Support custom Dictionary implementations in 'preprocess.py' (#448) · bbb4120b
      Davide Caroselli authored
      Summary:
      The `preprocess.py` script has been refactored in order to:
      
      1. Use the `options` module for command line arguments  parsing. This will give to `preprocess.py` the ability to load custom modules with `--user-dir` flag (already implemented to all other binaries)
      2. Dictionary loading and building code has moved to Task implementation. This allows custom Dictionary classes to be used during the data generation step.
      Pull Request resolved: https://github.com/pytorch/fairseq/pull/448
      
      Differential Revision: D13674819
      
      Pulled By: myleott
      
      fbshipit-source-id: b40648a98ed6c08284577e5ec25876e018d8c822
      bbb4120b
  6. Jan 30, 2019
    • Myle Ott's avatar
      Do distributed init after data loading · ec6f8ef9
      Myle Ott authored
      Summary:
      FACEBOOK
      
      This switches back to torch.multiprocessing.spawn, instead of directly calling fb_train.par using a subprocess.Process. This has the advantage that exceptions are propagated properly. It also moves the distributed_init part to happen after data loading, which gets around the timeout issue.
      
      The downside of this approach is that it's not so easy to pipe stdout to multiple places, which was nice when using the sweep.py scripts. I'm still working on a fix for that.
      
      Reviewed By: rutyrinott, ngoyal2707
      
      Differential Revision: D13873224
      
      fbshipit-source-id: 08d593233b8d23590c01c723363630a79804a8b0
      ec6f8ef9
    • Myle Ott's avatar
      Add --input option to interactive.py to support reading from file · 3dce7c9f
      Myle Ott authored
      Summary: Pull Request resolved: https://github.com/pytorch/fairseq/pull/484
      
      Differential Revision: D13880636
      
      Pulled By: myleott
      
      fbshipit-source-id: 984b2e1c3b281c28243102eb971ea45ec891d94e
      3dce7c9f
    • Myle Ott's avatar
      Merge internal changes (#483) · 42be3ebd
      Myle Ott authored
      Summary:
      Changelog:
      - `4889802`: can now remove detokenize sentencepiece output with `--remove-bpe=sentencepiece` (fixes #331). Also added `--sacrebleu` for computing detokenized BLEU.
      - `0d76427`: fix assertion error when training language model with dataset containing empty sentences
      - minor bug and style fixes
      Pull Request resolved: https://github.com/pytorch/fairseq/pull/483
      
      Differential Revision: D13867899
      
      Pulled By: myleott
      
      fbshipit-source-id: 25c940b847fe270262ac8f5ac838407b3977fdda
      42be3ebd
  7. Jan 29, 2019
  8. Jan 25, 2019
  9. Jan 24, 2019
  10. Jan 17, 2019
    • Myle Ott's avatar
      Fix stories generation · d259ffa9
      Myle Ott authored
      Summary: Pull Request resolved: https://github.com/pytorch/fairseq/pull/454
      
      Differential Revision: D13708565
      
      Pulled By: myleott
      
      fbshipit-source-id: 5cd0e07e3e1885eef14e3a5e8074f24cf4bde632
      d259ffa9
    • Myle Ott's avatar
      Fix initial learning rate (#453) · 2210fa71
      Myle Ott authored
      Summary:
      There was a very subtle bug here 😢When we recently removed this line (7633129b), it meant that the learning rate scheduler didn't get initialized until after the first update. Unfortunately pytorch optimizers store the learning rate in their internal state, so some learning rate schedulers use their `__init__` method to reset the learning rate to some sane initial value. This is especially problematic for LR schedulers that include a warmup, where the Optimizer is likely to contain the peak learning rate at initialization, and it's only in the LR scheduler's `__init__` that the (much smaller) warmup value is set.
      
      For example, the inverse_sqrt scheduler resets the learning rate upon initialization:
      https://github.com/pytorch/fairseq/blob/7853818c2e33a63ec17a31bcfe20e4fc75d94130/fairseq/optim/lr_scheduler/inverse_square_root_schedule.py#L48-L50
      
      **Impact:** For the last ~1.5 weeks, the first training update would use the optimizer's default learning rate instead of the initial rate set by the LR scheduler. All subsequent updates used the correct learning rates. This primarily affects LR schedulers with warmups.
      Pull Request resolved: https://github.com/pytorch/fairseq/pull/453
      
      Differential Revision: D13704453
      
      Pulled By: myleott
      
      fbshipit-source-id: a946da30100f837c66bdc6b9b77b014ab4eb8764
      2210fa71
  11. Jan 16, 2019
    • Davide Caroselli's avatar
      FIX: '--user-dir' on multi-gpu (#449) · 7853818c
      Davide Caroselli authored
      Summary:
      On a multi-gpu training scenario, the `train.py` script spawns new processes with `torch.multiprocessing.spawn`. Unfortunately those child processes don't inherit the modules imported with `--user-dir`.
      
      This pull request fixes this problem: custom module import in now explicit on every `main()` function.
      Pull Request resolved: https://github.com/pytorch/fairseq/pull/449
      
      Differential Revision: D13676922
      
      Pulled By: myleott
      
      fbshipit-source-id: 520358d66155697885b878a37e7d0484bddbc1c6
      7853818c
    • Myle Ott's avatar
      Add --checkpoint-upper-bound to average_checkpoints.py (#452) · bdec179b
      Myle Ott authored
      Summary:
      This is useful for averaging the last N checkpoints, ending at some "best" checkpoint.
      Pull Request resolved: https://github.com/pytorch/fairseq/pull/452
      
      Differential Revision: D13695407
      
      Pulled By: myleott
      
      fbshipit-source-id: 5d9d2bff3706834f01501e9259834c77fb335817
      bdec179b
    • Ruty Rinott's avatar
      optimizations for token_block_dataset · d1dc66d9
      Ruty Rinott authored
      Summary:
      optimizing memory use of token_block_dataset by replacing python data structures with numpy arrays.
      applying needed parts from D13498973, instead of rebasing it on changes
      
      Reviewed By: edunov
      
      Differential Revision: D13678485
      
      fbshipit-source-id: c0c827a8b95834a6a5456476040ebdc8e42136d4
      d1dc66d9
  12. Jan 15, 2019
  13. Jan 14, 2019
  14. Jan 10, 2019
  15. Jan 09, 2019
  16. Jan 07, 2019
  17. Jan 05, 2019
  18. Dec 28, 2018
  19. Dec 26, 2018
Loading