Skip to content

Conversation

@sfendell-labelbox
Copy link
Contributor

No description provided.

@sfendell-labelbox sfendell-labelbox force-pushed the sfendell/SDK-503 branch 6 times, most recently from 0206379 to dfbc2f3 Compare January 3, 2024 23:04
data_row_uids, # sample of data row objects
5 # priority between 1(Highest) - 5(lowest)
)
labels = [create_label() for _ in range(5000)]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you considering running a full upload of 5,000 annotations for SDK integration testing? This could significantly impact performance and might even result in flakiness. I recall we previously reduced some tests due to similar concerns. Would you consider creating a method or perhaps patching the LABEL_LIMIT to a smaller number, like 2, specifically for integration tests to mitigate these issues?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm happy to patch to improve test performance, but I don't think LABEL_LIMIT has any impact on performance here. I did an experiment, results below:

Runtime with LABEL_LIMIT patched to 20 labels:

41.18s call tests/integration/annotation_import/test_bulk_import_request.py::test_below_annotation_limit_on_single_data_row
30.34s call tests/integration/annotation_import/test_bulk_import_request.py::test_above_annotation_limit_on_single_data_row
9.20s setup tests/integration/annotation_import/test_bulk_import_request.py::test_below_annotation_limit_on_single_data_row
5.96s setup tests/integration/annotation_import/test_bulk_import_request.py::test_above_annotation_limit_on_single_data_row
1.04s teardown tests/integration/annotation_import/test_bulk_import_request.py::test_below_annotation_limit_on_single_data_row
0.94s teardown tests/integration/annotation_import/test_bulk_import_request.py::test_above_annotation_limit_on_single_data_row

Runtimes with LABEL_LIMIT not patched:
43.55s call tests/integration/annotation_import/test_bulk_import_request.py::test_below_annotation_limit_on_single_data_row
31.41s call tests/integration/annotation_import/test_bulk_import_request.py::test_above_annotation_limit_on_single_data_row
9.22s setup tests/integration/annotation_import/test_bulk_import_request.py::test_below_annotation_limit_on_single_data_row
6.34s setup tests/integration/annotation_import/test_bulk_import_request.py::test_above_annotation_limit_on_single_data_row
1.13s teardown tests/integration/annotation_import/test_bulk_import_request.py::test_below_annotation_limit_on_single_data_row
1.09s teardown tests/integration/annotation_import/test_bulk_import_request.py::test_above_annotation_limit_on_single_data_row

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like to leave it as is, given that patching doesn't have impact on performance (and test results have been consistent in every run, so I don't think flakiness is an issue either).

@sfendell-labelbox sfendell-labelbox merged commit b3efc51 into develop Jan 4, 2024
@sfendell-labelbox sfendell-labelbox deleted the sfendell/SDK-503 branch January 4, 2024 20:28
sfendell-labelbox added a commit that referenced this pull request Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants