allennlp
allennlp copied to clipboard
Add allowed_transitions in __init__.py of crf mod.
Fix ImportError: from allennlp.modules.conditional_random_field import allowed_transitions ImportError: cannot import name 'allowed_transitions' from 'allennlp.modules.conditional_random_field'
Fixes #5695.
Changes proposed in this pull request:
- Fix ImportError of allowed_transitions
Before submitting
- [x] I've read and followed all steps in the Making a pull request
section of the
CONTRIBUTINGdocs. - [x] I've updated or added any relevant docstrings following the syntax described in the
Writing docstrings section of the
CONTRIBUTINGdocs. - [x] If this PR fixes a bug, I've added a test that will fail without my fix.
- [x] If this PR adds a new feature, I've added tests that sufficiently cover my new functionality.
After submitting
- [ ] All GitHub Actions jobs for my pull request have passed.
- [ ]
codecov/patchreports high test coverage (at least 90%). You can find this under the "Actions" tab of the pull request once the other checks have finished.
I finished this in #5706. Thank you!