Isis 3 Programmer Reference
|
Class for observations that use CSM camera models in bundle adjustment. More...
#include <CsmBundleObservation.h>
Public Member Functions | |
CsmBundleObservation () | |
Constructs a CsmBundleObservation initialized to a default state. More... | |
CsmBundleObservation (BundleImageQsp image, QString observationNumber, QString instrumentId, BundleTargetBodyQsp bundleTargetBody) | |
Constructs a CsmBundleObservation from a BundleImage, an instrument id, an observation number to assign to this CsmBundleObservation, and a target body. More... | |
CsmBundleObservation (const CsmBundleObservation &src) | |
Creates a copy of another CsmBundleObservation. More... | |
~CsmBundleObservation () | |
Destructor. More... | |
CsmBundleObservation & | operator= (const CsmBundleObservation &src) |
Assignment operator. More... | |
void | copy (const CsmBundleObservation &src) |
virtual bool | setSolveSettings (BundleObservationSolveSettings solveSettings) |
Set solve parameters. More... | |
int | numberParameters () |
Returns the number of total parameters there are for solving. More... | |
const BundleObservationSolveSettingsQsp | solveSettings () |
Accesses the solve settings. More... | |
bool | applyParameterCorrections (LinearAlgebra::Vector corrections) |
Applies the parameter corrections. More... | |
void | bundleOutputString (std::ostream &fpOut, bool errorPropagation) |
Takes in an open std::ofstream and writes out information which goes into the bundleout.txt file. More... | |
QString | bundleOutputCSV (bool errorPropagation) |
Creates and returns a formatted QString representing the bundle coefficients and parameters in csv format. More... | |
virtual QStringList | parameterList () |
Returns the list of observation parameter names. More... | |
bool | computeTargetPartials (LinearAlgebra::Matrix &coeffTarget, BundleMeasure &measure, BundleSettingsQsp &bundleSettings, BundleTargetBodyQsp &bundleTargetBody) |
Cannot compute target body parameters for a CSM observation, so always throws an exception. More... | |
bool | computeImagePartials (LinearAlgebra::Matrix &coeffImage, BundleMeasure &measure) |
Calculates the sensor partials with respect to the solve parameters and populates the coeffImage matrix. More... | |
bool | computePoint3DPartials (LinearAlgebra::Matrix &coeffPoint3D, BundleMeasure &measure, SurfacePoint::CoordinateType coordType) |
Calculates the ground partials for the line, sample currently set in the sensor model. More... | |
bool | computeRHSPartials (LinearAlgebra::Vector &coeffRHS, BundleMeasure &measure) |
Calculates the sample, line residuals between the values measured in the image and the ground-to-image sample, line calculated by the sensor model. More... | |
double | computeObservationValue (BundleMeasure &measure, double deltaVal) |
Returns the observed value in (sample, line) coordinates. More... | |
void | copy (const BundleObservation &src) |
virtual void | append (const BundleImageQsp &value) |
Appends a BundleImage shared pointer to the BundleObservation. More... | |
BundleImageQsp | imageByCubeSerialNumber (QString cubeSerialNumber) |
Returns the BundleImage shared pointer associated with the given serial number. More... | |
void | setIndex (int n) |
Sets the index for the observation. More... | |
int | index () |
Accesses the observation's index. More... | |
QString | instrumentId () |
Accesses the instrument id. More... | |
virtual LinearAlgebra::Vector & | parameterWeights () |
Accesses the solve parameter weights. More... | |
virtual LinearAlgebra::Vector & | parameterCorrections () |
Accesses the parameter corrections. More... | |
virtual LinearAlgebra::Vector & | aprioriSigmas () |
Accesses the a priori sigmas. More... | |
virtual LinearAlgebra::Vector & | adjustedSigmas () |
Accesses the adjusted sigmas. More... | |
virtual QStringList | imageNames () |
Access to image names for CorrelationMatrix to use. More... | |
Protected Attributes | |
QString | m_observationNumber |
The shared portion of the serial numbers of all images in the observation. More... | |
int | m_index |
Index of this observation in the set of observations. Map between cube serial number and BundleImage pointers. More... | |
QMap< QString, BundleImageQsp > | m_cubeSerialNumberToBundleImageMap |
QStringList | m_serialNumbers |
List of all cube serial numbers in observation. More... | |
QStringList | m_imageNames |
List of all cube names. More... | |
QString | m_instrumentId |
Spacecraft instrument id. More... | |
LinearAlgebra::Vector | m_weights |
Parameter weights. Cumulative parameter correction vector. More... | |
LinearAlgebra::Vector | m_corrections |
LinearAlgebra::Vector | m_aprioriSigmas |
A posteriori (adjusted) parameter sigmas. More... | |
LinearAlgebra::Vector | m_adjustedSigmas |
A posteriori (adjusted) parameter sigmas. More... | |
Private Member Functions | |
bool | initParameterWeights () |
Private Attributes | |
BundleObservationSolveSettingsQsp | m_solveSettings |
Solve settings for this observation. More... | |
std::vector< int > | m_paramIndices |
The indices of the parameters the observation is solving for. More... | |
Class for observations that use CSM camera models in bundle adjustment.
Definition at line 28 of file CsmBundleObservation.h.
Isis::CsmBundleObservation::CsmBundleObservation | ( | ) |
Constructs a CsmBundleObservation initialized to a default state.
Definition at line 33 of file CsmBundleObservation.cpp.
Isis::CsmBundleObservation::CsmBundleObservation | ( | BundleImageQsp | image, |
QString | observationNumber, | ||
QString | instrumentId, | ||
BundleTargetBodyQsp | bundleTargetBody | ||
) |
Constructs a CsmBundleObservation from a BundleImage, an instrument id, an observation number to assign to this CsmBundleObservation, and a target body.
image | QSharedPointer to the primary image in the observation |
observationNumber | Observation number of the observation |
instrumentId | Id of the instrument for the observation |
bundleTargetBody | QSharedPointer to the target body of the observation |
Definition at line 46 of file CsmBundleObservation.cpp.
References Isis::IException::User.
Isis::CsmBundleObservation::CsmBundleObservation | ( | const CsmBundleObservation & | src | ) |
Creates a copy of another CsmBundleObservation.
src | Reference to the CsmBundleObservation to copy |
Definition at line 60 of file CsmBundleObservation.cpp.
References m_paramIndices, and m_solveSettings.
Isis::CsmBundleObservation::~CsmBundleObservation | ( | ) |
Destructor.
Contained BundleImages will remain until all shared pointers are deleted.
Definition at line 71 of file CsmBundleObservation.cpp.
|
virtualinherited |
Accesses the adjusted sigmas.
Definition at line 207 of file BundleObservation.cpp.
|
virtualinherited |
Appends a BundleImage shared pointer to the BundleObservation.
If the pointer is valid, then the BundleImage and its serial number will be inserted into the serial number to BundleImage map.
value | The BundleImage to be appended. |
Definition at line 135 of file BundleObservation.cpp.
|
virtual |
Applies the parameter corrections.
corrections | Vector of corrections to apply |
IException::Unknown | "Instrument position is NULL, but position solve option is [not NoPositionFactors]" |
IException::Unknown | "Instrument position is NULL, but pointing solve option is [not NoPointingFactors]" |
IException::Unknown | "Unable to apply parameter corrections to CsmBundleObservation." |
Implements Isis::BundleObservation.
Definition at line 163 of file CsmBundleObservation.cpp.
References Isis::CSMCamera::applyParameterCorrection(), m_paramIndices, and Isis::IException::Programmer.
|
virtualinherited |
Accesses the a priori sigmas.
Definition at line 197 of file BundleObservation.cpp.
|
virtual |
Creates and returns a formatted QString representing the bundle coefficients and parameters in csv format.
errorPropagation | Boolean indicating whether or not to attach more information (corrections, sigmas, adjusted sigmas...) to the output QString |
Implements Isis::BundleObservation.
Definition at line 274 of file CsmBundleObservation.cpp.
References Isis::CSMCamera::getParameterValue(), Isis::BundleObservation::m_adjustedSigmas, Isis::BundleObservation::m_aprioriSigmas, m_paramIndices, and Isis::toString().
|
virtual |
Takes in an open std::ofstream and writes out information which goes into the bundleout.txt file.
fpOut | The open std::ofstream object which is passed in from BundleSolutionInfo::outputText() |
errorPropagation | Boolean indicating whether or not to attach more information (corrections, sigmas, adjusted sigmas...) to the output. |
Implements Isis::BundleObservation.
Definition at line 205 of file CsmBundleObservation.cpp.
References Isis::CSMCamera::getParameterName(), Isis::CSMCamera::getParameterUnits(), Isis::CSMCamera::getParameterValue(), Isis::IsSpecial(), Isis::BundleObservation::m_adjustedSigmas, Isis::BundleObservation::m_aprioriSigmas, m_paramIndices, numberParameters(), and Isis::toString().
|
virtual |
Calculates the sensor partials with respect to the solve parameters and populates the coeffImage matrix.
coeffImage | A matrix that will be populated with the sensor partials with respect to the solve parameters. |
measure | The measure that the partials are being computed for. |
Implements Isis::BundleObservation.
Definition at line 350 of file CsmBundleObservation.cpp.
References Isis::BundleControlPoint::adjustedSurfacePoint(), Isis::BundleMeasure::camera(), m_paramIndices, and Isis::BundleMeasure::parentControlPoint().
|
virtual |
Returns the observed value in (sample, line) coordinates.
This requires no modification for Csm.
measure | measure The measure that the partials are being computed for. |
deltaVal | The difference between the measured and calculate sample, line coordinates |
Implements Isis::BundleObservation.
Definition at line 481 of file CsmBundleObservation.cpp.
|
virtual |
Calculates the ground partials for the line, sample currently set in the sensor model.
coeffPoint3D | A matrix that will be populated with the (line, sample) partials with respect to the ground point. |
measure | The measure that the partials are being computed for. |
coordType | Not used in this class. Coordinates are x,y,z |
Implements Isis::BundleObservation.
Definition at line 381 of file CsmBundleObservation.cpp.
References Isis::BundleControlPoint::adjustedSurfacePoint(), Isis::BundleMeasure::camera(), Isis::CSMCamera::GroundPartials(), Isis::SurfacePoint::Latitudinal, Isis::SurfacePoint::LatitudinalDerivative(), Isis::BundleMeasure::parentControlPoint(), Isis::IException::Programmer, Isis::SurfacePoint::Rectangular, and Isis::toString().
|
virtual |
Calculates the sample, line residuals between the values measured in the image and the ground-to-image sample, line calculated by the sensor model.
coeffRHS | A vector that will contain the sample, line residuals. |
measure | The measure that the partials are being computed for. |
Implements Isis::BundleObservation.
Definition at line 441 of file CsmBundleObservation.cpp.
References Isis::BundleControlPoint::adjustedSurfacePoint(), Isis::BundleMeasure::camera(), Isis::BundleMeasure::cubeSerialNumber(), Isis::BundleControlPoint::id(), Isis::Camera::Line(), Isis::BundleMeasure::line(), Isis::BundleMeasure::parentControlPoint(), Isis::Camera::Sample(), Isis::BundleMeasure::sample(), Isis::Camera::SetGround(), and Isis::IException::User.
|
virtual |
Cannot compute target body parameters for a CSM observation, so always throws an exception.
coeffTarget | Matrix for target body partial derivatives |
measure | The measure that the partials are being computed for. |
bundleSettings | The settings for the bundle adjustment |
bundleTargetBody | QSharedPointer to the target body of the observation |
Implements Isis::BundleObservation.
Definition at line 329 of file CsmBundleObservation.cpp.
References Isis::IException::User.
|
inherited |
Returns the BundleImage shared pointer associated with the given serial number.
If no BundleImage with that serial number is contained a NULL pointer is returned.
cubeSerialNumber | The serial number of the cube to be returned. |
Definition at line 151 of file BundleObservation.cpp.
|
virtualinherited |
Access to image names for CorrelationMatrix to use.
Definition at line 237 of file BundleObservation.cpp.
|
inherited |
Accesses the observation's index.
Definition at line 227 of file BundleObservation.cpp.
Referenced by Isis::IsisBundleObservation::applyParameterCorrections(), Isis::IsisBundleObservation::computeImagePartials(), and Isis::IsisBundleObservation::computeTargetPartials().
|
inherited |
Accesses the instrument id.
Definition at line 167 of file BundleObservation.cpp.
|
virtual |
Returns the number of total parameters there are for solving.
The total number of parameters is equal to the number of position parameters and number of pointing parameters
Implements Isis::BundleObservation.
Definition at line 191 of file CsmBundleObservation.cpp.
References m_paramIndices.
Referenced by bundleOutputString().
CsmBundleObservation & Isis::CsmBundleObservation::operator= | ( | const CsmBundleObservation & | src | ) |
Assignment operator.
Assigns the state of the source CsmBundleObservation to this CsmBundleObservation
CsmBundleObservation | Reference to the source CsmBundleObservation to assign from |
Definition at line 84 of file CsmBundleObservation.cpp.
References m_paramIndices, and m_solveSettings.
|
virtualinherited |
Accesses the parameter corrections.
Definition at line 187 of file BundleObservation.cpp.
|
virtual |
Returns the list of observation parameter names.
This will always return at least one set of positions and pointings because we always output at least the center values even when not solving for them.
Implements Isis::BundleObservation.
Definition at line 305 of file CsmBundleObservation.cpp.
References Isis::CSMCamera::getParameterName(), and m_paramIndices.
|
virtualinherited |
Accesses the solve parameter weights.
Definition at line 177 of file BundleObservation.cpp.
|
inherited |
Sets the index for the observation.
n | Value to set the index of the observation to |
Definition at line 217 of file BundleObservation.cpp.
|
virtual |
Set solve parameters.
solveSettings | The solve settings to use |
Implements Isis::BundleObservation.
Definition at line 100 of file CsmBundleObservation.cpp.
References Isis::CSMCamera::getParameterCovariance(), Isis::CSMCamera::getParameterIndices(), Isis::BundleObservationSolveSettings::List, Isis::BundleObservation::m_adjustedSigmas, Isis::BundleObservation::m_aprioriSigmas, m_paramIndices, m_solveSettings, Isis::BundleObservation::m_weights, Isis::BundleObservationSolveSettings::Set, solveSettings(), and Isis::BundleObservationSolveSettings::Type.
|
virtual |
Accesses the solve settings.
Implements Isis::BundleObservation.
Definition at line 145 of file CsmBundleObservation.cpp.
Referenced by setSolveSettings().
|
protectedinherited |
A posteriori (adjusted) parameter sigmas.
Definition at line 108 of file BundleObservation.h.
Referenced by Isis::IsisBundleObservation::bundleOutputCSV(), bundleOutputCSV(), Isis::IsisBundleObservation::bundleOutputString(), bundleOutputString(), Isis::IsisBundleObservation::setSolveSettings(), and setSolveSettings().
|
protectedinherited |
A posteriori (adjusted) parameter sigmas.
Definition at line 106 of file BundleObservation.h.
Referenced by Isis::IsisBundleObservation::bundleOutputCSV(), bundleOutputCSV(), Isis::IsisBundleObservation::bundleOutputString(), bundleOutputString(), Isis::IsisBundleObservation::initParameterWeights(), Isis::IsisBundleObservation::setSolveSettings(), and setSolveSettings().
|
protectedinherited |
List of all cube names.
Definition at line 99 of file BundleObservation.h.
|
protectedinherited |
Index of this observation in the set of observations. Map between cube serial number and BundleImage pointers.
Definition at line 95 of file BundleObservation.h.
Referenced by Isis::BundleObservation::BundleObservation().
|
protectedinherited |
Spacecraft instrument id.
Definition at line 100 of file BundleObservation.h.
Referenced by Isis::BundleObservation::BundleObservation(), and Isis::BundleObservation::operator=().
|
protectedinherited |
The shared portion of the serial numbers of all images in the observation.
Definition at line 93 of file BundleObservation.h.
Referenced by Isis::BundleObservation::BundleObservation(), and Isis::BundleObservation::operator=().
|
private |
The indices of the parameters the observation is solving for.
Definition at line 74 of file CsmBundleObservation.h.
Referenced by applyParameterCorrections(), bundleOutputCSV(), bundleOutputString(), computeImagePartials(), CsmBundleObservation(), numberParameters(), operator=(), parameterList(), and setSolveSettings().
|
protectedinherited |
List of all cube serial numbers in observation.
Definition at line 98 of file BundleObservation.h.
Referenced by Isis::BundleObservation::BundleObservation(), and Isis::BundleObservation::operator=().
|
private |
Solve settings for this observation.
Definition at line 73 of file CsmBundleObservation.h.
Referenced by CsmBundleObservation(), operator=(), and setSolveSettings().
|
protectedinherited |
Parameter weights. Cumulative parameter correction vector.
Definition at line 102 of file BundleObservation.h.
Referenced by Isis::IsisBundleObservation::initParameterWeights(), Isis::IsisBundleObservation::setSolveSettings(), and setSolveSettings().