-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
support writing out nbest list v2 (#446)
* decoder interface and type annotations * add inference base clase; rename SimpleInference to SequenceInference; some refactoring to outputs and SequenceInference * add sequence labeler and classifier * move output processing from generator models to inference * rename SequenceInference to AutoRegressiveInference * improve doc for inference * fix some serialization issues * remove some model-specific code * cleanup: unused inference src_mask, inconsistent input reader read_sent * rename ClassifierInference to IndependentOutputInference * update generate, use independent inference for seq labeler * fix warning * refactor MLE loss to be agnostic of translator internals, rename to AutoRegressiveMLELoss * fix single-quote docstring warning * fix further warnings * some renaming plus doc updates for translator * refactor MLP class * un-comment sentencepiece import * avoid code duplication between calc_loss and generate methods * share code between inference classes * IndependentOutputInference supports forced decoding etc * small cleanup * support forced decoding and fix batch loss for sequence labeler * forced decoding for classifier * rename transducer.__call__() to transduce() to simplify multiple inheritance * more principled use of batcher in inference * batch decoding for sequence classifier * DefaultTranslator: fix masking for (looped) batch decoding * made parameters of generate() clearer + other minor doc fixes * Added type annotation for transducers * clean up output interface * support writing out nbest list * some fixes related to reporting * fix unit tests * Separated softmax and projection (#440) * Started separating out softmax * Started fixing tests * Fixed more tests * Fixed remainder of running tests * Fixed the rest of tests * Added AuxNonLinear * Updated examples (many were already broken?) * Fixed recipes * Removed MLP class * Added some doc * fix problem when calling a super constructor that is wrapped in serialized_init * Added some doc * fix / clean up sequence labeler * fix using scorer * document how to run test configs directly * fix examples * update api doc * Removed extraneous yaml file * Update to doc * attempt to fix travis * represent command line args as normal dictionary * temporarily disable travis cache * undo previous commit * fix serialization problem * downgrade pyyaml * support writing out nbest list
- Loading branch information
Showing
3 changed files
with
62 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters