-
Notifications
You must be signed in to change notification settings - Fork 169
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
***DO NOT MERGE*** Adds SCCONFIG parameter to jigsaw #3612
Conversation
<item>OVEREXISTING</item> | ||
<item>SPKDEGREE</item> | ||
<item>SPKSOLVEDEGREE</item> | ||
<item>SPSOLVE</item> | ||
<!-- <item>TWIST</item> --> |
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.
For some reason, having this leads to the following error message when running jigsaw:
**USER ERROR** Parameter [TWIST] must be used if parameter [SCCONFIG] is used.
CAMERA_ANGULAR_VELOCITY_SIGMA, CAMERA_ANGULAR_ACCELERATION_SIGMA. An example | ||
template is located at $base/templates/jigsaw/SC_Parameters.pvl. | ||
</description> | ||
<parameter name="SCCONFIG"> | ||
<exclusions> |
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.
currently, I've only added parameters that the BOSS constructor populates into the exclusion list.
I'm sure there are other parameters that should be excluded, but I have a hard time figuring out which ones.
m_numberCamAngleCoefSolved = m_ckSolveDegree + 1; | ||
} | ||
|
||
m_anglesAprioriSigma.clear(); |
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.
This should be moved down to where it is actually set.
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.
is it even necessary to clear them? I'm guessing they are there from when this was implemented as the setFromPvl method, but since it's a constructor now this will be the first time that they are set anywhere
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.
that's correct these can just go away then.
m_numberCamPosCoefSolved = m_spkSolveDegree + 1; | ||
} | ||
|
||
m_positionAprioriSigma.clear(); |
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.
This should also be moved down to where it is actually set.
} | ||
} | ||
|
||
if (csolve != "NONE") { |
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.
This should be checking m_instrumentPointingSolveOption
(double)(scParameterGroup.findKeyword("CAMERA_ANGULAR_ACCELERATION_SIGMA"))); | ||
} | ||
|
||
if (ssolve != "NONE") { |
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.
Same here this should check m_instrumentPositionSolveOption
if (scParameterGroup.hasKeyword("CAMERA_ANGULAR_ACCELERATION_SIGMA")) | ||
m_anglesAprioriSigma.append( | ||
(double)(scParameterGroup.findKeyword("CAMERA_ANGULAR_ACCELERATION_SIGMA"))); | ||
} |
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.
based on setInstrumentPointingSettings
, the m_anglesAprioriSigma
list needs have m_numberCamAngleCoefSolved
elements and any sigmas that are not passed in should be set to ISIS::Null. So each of this ifs needs to have an else that appends a Null.
if (scParameterGroup.hasKeyword("SPACECRAFT_VELOCITY_SIGMA")) | ||
m_positionAprioriSigma.append((double)(scParameterGroup.findKeyword("SPACECRAFT_VELOCITY_SIGMA"))); | ||
if (scParameterGroup.hasKeyword("SPACECRAFT_ACCELERATION_SIGMA")) | ||
m_positionAprioriSigma.append((double)(scParameterGroup.findKeyword("SPACECRAFT_ACCELERATION_SIGMA"))); |
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.
Same as above, each if here should have an else that appends an ISIS::Null
if (scParameterGroup.hasKeyword("CAMERA_ANGULAR_ACCELERATION_SIGMA")) | ||
m_anglesAprioriSigma.append( | ||
(double)(scParameterGroup.findKeyword("CAMERA_ANGULAR_ACCELERATION_SIGMA"))); | ||
} |
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.
This should also look for ADDITIONAL_CAMERA_POINTING_SIGMAS
and append whatever is passed in to m_anglesAprioriSigma
if (scParameterGroup.hasKeyword("SPACECRAFT_VELOCITY_SIGMA")) | ||
m_positionAprioriSigma.append((double)(scParameterGroup.findKeyword("SPACECRAFT_VELOCITY_SIGMA"))); | ||
if (scParameterGroup.hasKeyword("SPACECRAFT_ACCELERATION_SIGMA")) | ||
m_positionAprioriSigma.append((double)(scParameterGroup.findKeyword("SPACECRAFT_ACCELERATION_SIGMA"))); |
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.
Same here, look for ADDITIONAL_SPACECRAFT_POSITION_SIGMAS
and append those to m_positionAprioriSigma
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.
Not sure how this would look. In the ADDITIONAL_SPACECRAFT_POSITION_SIGMAS
keyword, would it contain a list of doubles and then I would loop through that list and append them all? I'm also guessing I don't need to append null if this keyword isn't found
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.
It would be an array of doubles, you can use PvlKeyword::size
and PvlKeyword::operator[](int index)
to loop through the values and append them. It is purely for sigmas past the acceleration so if it's not there you don't need to pad.
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.
New BOSS constructor also needs a test
m_anglesAprioriSigma.append((double)(scParameterGroup.findKeyword("CAMERA_ANGLES_SIGMA"))); | ||
if (scParameterGroup.hasKeyword("CAMERA_ANGULAR_VELOCITY_SIGMA")) | ||
m_anglesAprioriSigma.append( | ||
if (m_instrumentPointingSolveOption) { |
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.
This is an enumeration I would check m_instrumentPointingSolveOption != NoPointingFactors
m_positionAprioriSigma.append((double)(scParameterGroup.findKeyword("SPACECRAFT_VELOCITY_SIGMA"))); | ||
if (scParameterGroup.hasKeyword("SPACECRAFT_ACCELERATION_SIGMA")) | ||
m_positionAprioriSigma.append((double)(scParameterGroup.findKeyword("SPACECRAFT_ACCELERATION_SIGMA"))); | ||
if (m_instrumentPositionSolveOption) { |
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.
Same as for pointing, check m_instrumentPositionSolveOption != NoPositionFactors
for (int i = 0; i < additionalSigmas.size(); i++ ) { | ||
m_positionAprioriSigma.append(toDouble(additionalSigmas[i])); | ||
} | ||
} |
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.
This is good, the pointing needs to have similar logic for ADDITIONAL_CAMERA_POINTING_SIGMAS
Pushed my changes with the nearly complete gtest for the BundleObservationSolveSettings class. As for the jigsaw stuff, we still need to update truth data of existing tests and add a couple of new ones after this PR is merged. |
See #3792 for the continuation of this PR as Aaron is not working on it. |
Description
Added SSCONFIG parameter to jigsaw.xml. This allows users to pass in a pvl file to set different parameters for different instruments. Added logic into jigsaw's main.cpp in order to facilitate the use of this new parameter.
Added a new BundleObservationSolveSettings constructor to build a BundleObservationSolveSettings given a pvl group.
Currently causing some existing tests to fail, and needs new tests to cover the changes we've implemented.
Related Issue
#3369
Motivation and Context
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist:
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: