Fix DocBin.merge() example (#4599)

This commit is contained in:
adrianeboyd 2019-11-07 11:26:48 +01:00 committed by Matthew Honnibal
parent 5563c42ef5
commit 0f8678c0b1
1 changed files with 2 additions and 2 deletions

View File

@ -109,8 +109,8 @@ raise an error if the pre-defined attrs of the two `DocBin`s don't match.
> doc_bin1.add(nlp("Hello world")) > doc_bin1.add(nlp("Hello world"))
> doc_bin2 = DocBin(attrs=["LEMMA", "POS"]) > doc_bin2 = DocBin(attrs=["LEMMA", "POS"])
> doc_bin2.add(nlp("This is a sentence")) > doc_bin2.add(nlp("This is a sentence"))
> merged_bins = doc_bin1.merge(doc_bin2) > doc_bin1.merge(doc_bin2)
> assert len(merged_bins) == 2 > assert len(doc_bin1) == 2
> ``` > ```
| Argument | Type | Description | | Argument | Type | Description |