Skip to content

Commit

Permalink
update pie-datasets to 0.4.0 (#147)
Browse files Browse the repository at this point in the history
* update pie-datasets to 0.4.0

* fix test_train_predict
  • Loading branch information
ArneBinder authored Nov 23, 2023
1 parent c6afd2b commit 8774467
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion configs/dataset/conll2003.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
_target_: pie_datasets.DatasetDict.load_dataset

path: pie/conll2003
revision: 0fa8689b44ca9885b77276205a7dab3b562266b9
revision: 95ee94f78010d00cb5a94c38ebbddd07273be8c0
2 changes: 1 addition & 1 deletion configs/dataset/conll2003_base.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ _target_: src.utils.execute_pipeline
input:
_target_: pie_datasets.DatasetDict.load_dataset
path: pie/conll2003
revision: 0fa8689b44ca9885b77276205a7dab3b562266b9
revision: 95ee94f78010d00cb5a94c38ebbddd07273be8c0
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# --------- pytorch-ie --------- #
pytorch-ie>=0.28.0,<0.30.0
pie-datasets>=0.3.1,<0.4.0
pie-datasets>=0.3.3,<0.5.0

# --------- hydra --------- #
hydra-core>=1.3.0
Expand Down
2 changes: 1 addition & 1 deletion tests/test_predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def test_train_predict(tmp_path, cfg_train, cfg_predict):
HydraConfig().set_config(cfg_predict)
_, object_dict = predict(cfg_predict)

predicted_entities = [list(doc.labeled_spans.predictions) for doc in object_dict["documents"]]
predicted_entities = [list(doc.entities.predictions) for doc in object_dict["documents"]]
num_predicted_entities = sum([len(preds) for preds in predicted_entities])
assert num_predicted_entities > 0

Expand Down

0 comments on commit 8774467

Please sign in to comment.