mirror of https://github.com/explosion/spaCy.git
accuracy -> performance
This commit is contained in:
parent
6836b66433
commit
88e54caa12
|
@ -91,7 +91,9 @@ def info_model(model: str, *, silent: bool = True) -> Dict[str, Any]:
|
|||
meta["source"] = str(model_path.resolve())
|
||||
else:
|
||||
meta["source"] = str(model_path)
|
||||
return {k: v for k, v in meta.items() if k not in ("accuracy", "speed")}
|
||||
return {
|
||||
k: v for k, v in meta.items() if k not in ("accuracy", "performance", "speed")
|
||||
}
|
||||
|
||||
|
||||
def get_markdown(data: Dict[str, Any], title: Optional[str] = None) -> str:
|
||||
|
|
|
@ -182,8 +182,7 @@ class ModelMetaSchema(BaseModel):
|
|||
sources: Optional[Union[List[StrictStr], List[Dict[str, str]]]] = Field(None, title="Training data sources")
|
||||
vectors: Dict[str, Any] = Field({}, title="Included word vectors")
|
||||
labels: Dict[str, List[str]] = Field({}, title="Component labels, keyed by component name")
|
||||
accuracy: Dict[str, Union[float, Dict[str, float]]] = Field({}, title="Accuracy numbers")
|
||||
speed: Dict[str, Union[float, int]] = Field({}, title="Speed evaluation numbers")
|
||||
performance: Dict[str, Union[float, Dict[str, float]]] = Field({}, title="Accuracy and speed numbers")
|
||||
spacy_git_version: StrictStr = Field("", title="Commit of spaCy version used")
|
||||
# fmt: on
|
||||
|
||||
|
|
|
@ -518,7 +518,7 @@ source of truth** used for loading a pipeline.
|
|||
> "ner": ["PERSON", "ORG", "PRODUCT"],
|
||||
> "textcat": ["POSITIVE", "NEGATIVE"]
|
||||
> },
|
||||
> "accuracy": {
|
||||
> "performance": {
|
||||
> "ents_f": 82.7300930714,
|
||||
> "ents_p": 82.135523614,
|
||||
> "ents_r": 83.3333333333,
|
||||
|
|
|
@ -117,7 +117,7 @@ function formatModelMeta(data) {
|
|||
license: data.license,
|
||||
labels: isEmptyObj(data.labels) ? null : data.labels,
|
||||
vectors: formatVectors(data.vectors),
|
||||
accuracy: formatAccuracy(data.accuracy),
|
||||
accuracy: formatAccuracy(data.performance),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue