Skip to content

Commit

Permalink
Merge pull request #123 from ArneBinder/use_annotations_from_pytorch_ie
Browse files Browse the repository at this point in the history
brat: use annotation types from pytorch-ie
  • Loading branch information
ArneBinder authored Apr 17, 2024
2 parents fcb66a0 + 876a7f0 commit 02f782a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 10 deletions.
8 changes: 4 additions & 4 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ classifiers = [

[tool.poetry.dependencies]
python = "^3.9"
pytorch-ie = ">=0.29.4,<0.31.0"
pytorch-ie = ">=0.30.3,<0.31.0"
# <2.16.0 because of https://github.com/ArneBinder/pie-datasets/issues/93
datasets = ">=2.14.0,<2.16.0"
# this was manually added because we get a conflict with pyarrow otherwise
Expand Down
5 changes: 2 additions & 3 deletions src/pie_datasets/builders/brat.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@
from typing import Any, Dict, List, Optional, Tuple, Union

import datasets
from pie_modules.annotations import BinaryRelation, LabeledMultiSpan, LabeledSpan
from pytorch_ie import Document
from pytorch_ie.core import Annotation, AnnotationList, annotation_field
from pytorch_ie.annotations import BinaryRelation, LabeledMultiSpan, LabeledSpan
from pytorch_ie.core import Annotation, AnnotationList, Document, annotation_field
from pytorch_ie.documents import TextBasedDocument

from pie_datasets import GeneratorBasedBuilder
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/builder/test_brat_builder.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from typing import Any

import pytest
from pie_modules.annotations import BinaryRelation, LabeledMultiSpan, LabeledSpan
from pytorch_ie import Annotation
from pytorch_ie.annotations import BinaryRelation, LabeledMultiSpan, LabeledSpan
from pytorch_ie.core import Annotation
from pytorch_ie.documents import TextBasedDocument

from pie_datasets.builders.brat import BratAttribute, BratBuilder
Expand Down

0 comments on commit 02f782a

Please sign in to comment.