-
Notifications
You must be signed in to change notification settings - Fork 12
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
unit tests #38
unit tests #38
Conversation
Thank you @LiangJYu, following your note above, the test runs nicely. How did you prepare the SAFE zip file? I notice there are measurement folder and tiff files but with 0 in size. Maybe write this in a README.md file within the tests folder? |
The 0 size files were |
add README
Thus far, the checks for simple attributes have been implemented. I'm unsure how to test the following more complex attributes. orbit: Ensure all state vectors within sensing start and stop? Check if position actually above surface of the earth? Check if velocity fast enough? poly1D: These vary with burst so the verbose method would be to store and check order, std, mean, and coeffs of each. I can't think of a cleaner way. lut2D: Can this be skiped since this is derived from poly1d? |
check orbit state vector time
@LiangJYu One test that I can think of for orbit is the following where we compute the coordinates for the middle of the burst and it should fall within the burst border.
Even with the inaccurate orbit within the annotation file, we should be able to pass this test. |
@LiangJYu for the lut2d you can check if we are able to eval successfully compared to poly1d. For example :
t0 and r0 can be the same middle of swath in my previous comment. |
simplify key check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks @LiangJYu for addressing my comments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Thank you @LiangJYu.
Hi @LiangJYu @yunjunz I am about to merge the annotation reader in PR #48. The new implementation loads IPF version from |
This PR adds unit tests to the 3 modules in s1-reader. The tests are currently very sparse and serve as a frame to build on.
Usage:
unit_test
branch from my forktests
directorypytest
To do: