mirror of
https://github.com/explosion/spaCy.git
synced 2025-01-13 02:36:32 +03:00
Merge pull request #3441 from explosion/fix/cli-ud-scripts
💫 Move UD scripts to bin
This commit is contained in:
commit
1c8ff59185
|
@ -13,14 +13,14 @@ import srsly
|
||||||
|
|
||||||
import spacy
|
import spacy
|
||||||
import spacy.util
|
import spacy.util
|
||||||
from ...tokens import Token, Doc
|
from spacy.tokens import Token, Doc
|
||||||
from ...gold import GoldParse
|
from spacy.gold import GoldParse
|
||||||
from ...util import compounding, minibatch_by_words
|
from spacy.util import compounding, minibatch_by_words
|
||||||
from ...syntax.nonproj import projectivize
|
from spacy.syntax.nonproj import projectivize
|
||||||
from ...matcher import Matcher
|
from spacy.matcher import Matcher
|
||||||
|
|
||||||
# from ...morphology import Fused_begin, Fused_inside
|
# from spacy.morphology import Fused_begin, Fused_inside
|
||||||
from ... import displacy
|
from spacy import displacy
|
||||||
from collections import defaultdict, Counter
|
from collections import defaultdict, Counter
|
||||||
from timeit import default_timer as timer
|
from timeit import default_timer as timer
|
||||||
|
|
||||||
|
@ -33,10 +33,10 @@ import numpy.random
|
||||||
|
|
||||||
from . import conll17_ud_eval
|
from . import conll17_ud_eval
|
||||||
|
|
||||||
from ... import lang
|
from spacy import lang
|
||||||
from ...lang import zh
|
from spacy.lang import zh
|
||||||
from ...lang import ja
|
from spacy.lang import ja
|
||||||
from ...lang import ru
|
from spacy.lang import ru
|
||||||
|
|
||||||
|
|
||||||
################
|
################
|
|
@ -13,12 +13,12 @@ import json
|
||||||
|
|
||||||
import spacy
|
import spacy
|
||||||
import spacy.util
|
import spacy.util
|
||||||
from ...tokens import Token, Doc
|
from spacy.tokens import Token, Doc
|
||||||
from ...gold import GoldParse
|
from spacy.gold import GoldParse
|
||||||
from ...util import compounding, minibatch, minibatch_by_words
|
from spacy.util import compounding, minibatch, minibatch_by_words
|
||||||
from ...syntax.nonproj import projectivize
|
from spacy.syntax.nonproj import projectivize
|
||||||
from ...matcher import Matcher
|
from spacy.matcher import Matcher
|
||||||
from ... import displacy
|
from spacy import displacy
|
||||||
from collections import defaultdict, Counter
|
from collections import defaultdict, Counter
|
||||||
from timeit import default_timer as timer
|
from timeit import default_timer as timer
|
||||||
|
|
||||||
|
@ -28,9 +28,9 @@ import numpy.random
|
||||||
|
|
||||||
from . import conll17_ud_eval
|
from . import conll17_ud_eval
|
||||||
|
|
||||||
from ... import lang
|
from spacy import lang
|
||||||
from ...lang import zh
|
from spacy.lang import zh
|
||||||
from ...lang import ja
|
from spacy.lang import ja
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import torch
|
import torch
|
|
@ -9,8 +9,7 @@ if __name__ == "__main__":
|
||||||
import sys
|
import sys
|
||||||
from wasabi import Printer
|
from wasabi import Printer
|
||||||
from spacy.cli import download, link, info, package, train, pretrain, convert
|
from spacy.cli import download, link, info, package, train, pretrain, convert
|
||||||
from spacy.cli import init_model, profile, evaluate, validate
|
from spacy.cli import init_model, profile, evaluate, validate, debug_data
|
||||||
from spacy.cli import ud_train, ud_evaluate, debug_data
|
|
||||||
|
|
||||||
msg = Printer()
|
msg = Printer()
|
||||||
|
|
||||||
|
@ -21,9 +20,7 @@ if __name__ == "__main__":
|
||||||
"train": train,
|
"train": train,
|
||||||
"pretrain": pretrain,
|
"pretrain": pretrain,
|
||||||
"debug-data": debug_data,
|
"debug-data": debug_data,
|
||||||
"ud-train": ud_train,
|
|
||||||
"evaluate": evaluate,
|
"evaluate": evaluate,
|
||||||
"ud-evaluate": ud_evaluate,
|
|
||||||
"convert": convert,
|
"convert": convert,
|
||||||
"package": package,
|
"package": package,
|
||||||
"init-model": init_model,
|
"init-model": init_model,
|
||||||
|
|
|
@ -10,4 +10,3 @@ from .evaluate import evaluate # noqa: F401
|
||||||
from .convert import convert # noqa: F401
|
from .convert import convert # noqa: F401
|
||||||
from .init_model import init_model # noqa: F401
|
from .init_model import init_model # noqa: F401
|
||||||
from .validate import validate # noqa: F401
|
from .validate import validate # noqa: F401
|
||||||
from .ud import ud_train, ud_evaluate # noqa: F401
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user