Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Canonical unit test examples: Segmentations for matching, and matched graphs without divisions #171

Merged
merged 9 commits into from
Dec 9, 2024

Conversation

cmalinmayor
Copy link
Collaborator

Proposed Change

Add code and documentation for canonical unit test fixtures. Includes segmentations for matching, and matched graphs without divisions (divisions coming in future PR). There are minimal examples in the IOU tests to show how to use the fixtures, including automatically iterating over multiple examples of the same type of error.

Types of Changes

What types of changes does your code introduce? Delete those that do not apply.

  • Tests and benchmarks

Which topics does your change affect? Delete those that do not apply.

  • Matchers
  • Track Errors
  • Metrics

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the developer/contributing docs.
  • I have added tests that prove that my feature works in various situations or tests the bugfix (if appropriate).
  • I have checked that I maintained or improved code coverage.
  • I have checked the benchmarking action to verify that my changes did not adversely affect performance.
  • I have written docstrings and checked that they render correctly in the Read The Docs build (created after the PR is opened).
  • I have updated the general documentation including Metric descriptions and example notebooks if necessary.

Further Comments

Next steps include actually using the fixtures to test our matchers and metrics, and adding division examples.

Copy link
Collaborator

@msschwartz21 msschwartz21 left a comment

Choose a reason for hiding this comment

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

At some point, we should consider switching over to a sphinx-gallery for the test documentation. The advantage is that it runs every time the docs are built so the images won't get out of sync with the actual test functions. The downside is the images won't be available locally unless the docs have been built locally. But it will always be up to date on read the docs.

Ready to merge if @cmalinmayor agrees with my docstrings about the matching type

@cmalinmayor
Copy link
Collaborator Author

At some point, we should consider switching over to a sphinx-gallery for the test documentation. The advantage is that it runs every time the docs are built so the images won't get out of sync with the actual test functions. The downside is the images won't be available locally unless the docs have been built locally. But it will always be up to date on read the docs.

Ready to merge if @cmalinmayor agrees with my docstrings about the matching type

Agree. The docstrings look good!

@cmalinmayor cmalinmayor merged commit 6212b53 into main Dec 9, 2024
13 checks passed
@cmalinmayor cmalinmayor deleted the unit_tests branch December 9, 2024 20:47
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.

2 participants