dmlc / gluon-nlp

NLP made easy
https://nlp.gluon.ai/
Apache License 2.0
2.55k stars 538 forks source link

[Performance][WIP] Use boolean mask #1402

Closed sxjscience closed 3 years ago

sxjscience commented 3 years ago

Description

Switch to use boolean mask, which helps reduce the memory consumption of the models.

Checklist

Essentials

cc @dmlc/gluon-nlp-team

github-actions[bot] commented 3 years ago

The documentation website for preview: http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR1402/boolean_mask/index.html