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

2.5D Occlusion and Testing Update #3757

Merged
merged 22 commits into from
Mar 18, 2020
Merged

2.5D Occlusion and Testing Update #3757

merged 22 commits into from
Mar 18, 2020

Conversation

acpaquette
Copy link
Collaborator

@acpaquette acpaquette commented Mar 13, 2020

Allows cam2map to account for occlusion when projecting images. Also updates cam2map with the application changes and test, and the application change for map2cam.

Description

Allows cam2map to account for occluded portions of images when they are map projected. This option can only be used with the reverse patch algorithm and is turned off by default to keep any currently used pipelines for generating map projected products to remain the same.

This PR also updates cam2map and map2cam to be callable as functions. The tests for cam2map where also updated with additional fixtures as well as a few new mocks.

Related Issue

This is related to a larger occlusion project with no specific issues on the ISIS repo.

Motivation and Context

This allows ISIS to more accurately project highly oblique images, so long as the image is accurately coregistered to its associated DEM.

How Has This Been Tested?

This has been tested with the current ISIS tests along with a new set of gtests.

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Documentation change (update to the documentation; no code change)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have read and agree to abide by the Code of Conduct
  • I have read the CONTRIBUTING document.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Licensing

This project is mostly composed of free and unencumbered software released into the public domain, and we are unlikely to accept contributions that are not also released into the public domain. Somewhere near the top of each file should have these words:

This work is free and unencumbered software released into the public domain. In jurisdictions that recognize copyright laws, the author or authors of this software dedicate any and all copyright interest in the software to the public domain.

  • I dedicate any and all copyright interest in this software to the public domain. I make this dedication for the benefit of the public at large and to the detriment of my heirs and successors. I intend this dedication to be an overt act of relinquishment in perpetuity of all present and future rights to this software under copyright law.

Copy link
Collaborator Author

@acpaquette acpaquette left a comment

Choose a reason for hiding this comment

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

There are two notable changes in cam2map that I have outlined so people can discuss them if necessary. The rest of cam2map should be the same as what was previously in the cam2map/main.cpp

Comment on lines +329 to +334
int patchSize = ui.GetInteger("PATCHSIZE");
int minPatchSize = 4;
if (patchSize < minPatchSize) {
patchSize = minPatchSize;
}
p.SetTiling(patchSize, patchSize);
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Originally:

int minPatchSize = 4;
if (patchSize < minPatchSize) {
    minPatchSize = patchSize;
}
p.SetTiling(patchSize, minPatchSize);

Comment on lines +34 to +37
void cam2map(Cube *icube, Pvl &userMap, PvlGroup &userGrp, UserInterface &ui, Pvl *log) {
ProcessRubberSheet p;
cam2map(icube, userMap, userGrp, p, ui, log);
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

New method so a mocked process object can be injected into the test.

Comment on lines +545 to +549
if (p_occlusion){
if (abs(lat - p_incam->UniversalLatitude()) > 0.00001 || abs(lon - p_incam->UniversalLongitude()) > 0.00001) {
return false;
}
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Also the actual occlusion handling in the cam2mapReverse Xform

@jessemapel jessemapel deleted the occlusion branch June 9, 2020 21:06
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.

3 participants