This repository has been archived by the owner on Jan 15, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 538
[BUGFIX] [DOC] Update nlp.model.get_model documentation and get_model API #734
Merged
Conversation
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
Codecov Report
|
Codecov Report
@@ Coverage Diff @@
## master #734 +/- ##
==========================================
- Coverage 90.56% 90.53% -0.03%
==========================================
Files 65 65
Lines 6071 6075 +4
==========================================
+ Hits 5498 5500 +2
- Misses 573 575 +2
|
Job PR-734/2 is complete. |
The |
szha
approved these changes
Jun 3, 2019
Job PR-734/3 is complete. |
eric-haibin-lin
approved these changes
Jun 3, 2019
paperplanet
pushed a commit
to paperplanet/gluon-nlp
that referenced
this pull request
Jun 9, 2019
… API (dmlc#734) * Improve gluonnlp.model docs * Fix nlp.model.get_model API * Update model.rst
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
http://gluon-nlp.mxnet.io/api/modules/model.html currently does not
differentiate pre-defined models exposed by the
get_model
function and othercomponents. This PR is a quick attempt to improve the distinction.
Further,
get_model
used a hardcodeddataset=wikitext-2
argument. This islikely by accident as the
get_model
function was initially mainly used forlanguage models, but now also provides access to other models such as Bert, for
which hardcoded dataset argument does not make sense.
For example, loading a Bert model with a prespecified Vocab currently requires doing
instead of
The latter version currently fails, as it will pass the "wikitext-2" as
dataset_name to the Bert model constructor.
Checklist
Essentials
Changes
nlp.model.get_model
dataset argument default to Nonenlp.model
docs