Skip to content

Commit 2dea1b1

Browse files
author
Val Brodsky
committed
Add explanation on how to supply data row ids to prediction_id_mapping
1 parent 873b659 commit 2dea1b1

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

tests/integration/annotation_import/conftest.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -605,6 +605,22 @@ def configured_project_with_one_data_row(client, ontology, rand_gen,
605605
# At the moment it expects only one feature per tool type and this creates unnecessary coupling between differet tests
606606
# In an example of a 'rectangle' we have extended to support multiple instances of the same tool type
607607
# TODO: we will support this approach in the future for all tools
608+
#
609+
"""
610+
Please note that this fixture now offers the flexibility to configure three different strategies for generating data row ids for predictions:
611+
Default(configured_project fixture):
612+
configured_project that generates a data row for each member of ontology.
613+
This makes sure each prediction has its own data row id. This is applicable to prediction upload cases when last label overwrites existing ones
614+
615+
Optimized Strategy (configured_project_with_one_data_row fixture):
616+
This fixture has only one data row and all predictions will be mapped to it
617+
618+
Custom Data Row IDs Strategy:
619+
Individuals can create their own fixture to supply data row ids.
620+
This particular fixture, termed "hardcoded_datarow_id," should be defined locally within a test file.
621+
"""
622+
623+
608624
@pytest.fixture
609625
def prediction_id_mapping(ontology, request):
610626
# Maps tool types to feature schema ids

0 commit comments

Comments
 (0)