Isis 3 Programmer Reference
|
#include <LidarData.h>
Public Types | |
enum | Format { Binary , Json , Test } |
Enumerates the file formats for serializing the LidarData class. More... | |
Public Member Functions | |
LidarData () | |
Default constructor. | |
void | insert (QSharedPointer< LidarControlPoint > point) |
Adds a LidarControlPoint to the LidarData. | |
QSharedPointer< LidarControlPoint > | point (QString pointId) const |
Gets a single LidarDataPoint by ID. | |
QList< QSharedPointer< LidarControlPoint > > | points (bool sort=false) const |
Gets the list of Lidar data points optionally sorted . | |
void | SetImages (SerialNumberList &list, Progress *progress=0) |
Creates the ControlNet's image camera's based on the list of Serial Numbers. | |
void | SetImages (ControlNet &controlNet, Progress *progress=0) |
TODO: more detail below... | |
void | read (FileName) |
Unserialize LidarData. | |
void | write (FileName, Format) |
Serializes LidarData. | |
int | numberLidarPoints () |
Returns number of Lidar data points. | |
int | numberSimultaneousMeasures () |
Returns number of simultaneous lidar measures. | |
int | numberAsynchronousMeasures () |
Returns number of non-simultaneous lidar measures. | |
int | numberMeasures () |
Returns total number of lidar measures. | |
bool | ValidateSerialNumber (QString serialNumber) const |
Does a check to ensure that the given serial number is contained within the network. | |
QList< ControlMeasure * > | GetMeasuresInCube (QString serialNumber) |
Get all the measures pertaining to a given cube serial number. | |
QList< ControlMeasure * > | GetValidMeasuresInCube (QString serialNumber) |
Get all the valid measures pertaining to a given cube serial number. | |
int | GetNumberOfValidMeasuresInImage (const QString &serialNumber) |
Return the number of measures in image specified by serialNumber. | |
int | GetNumberOfJigsawRejectedMeasuresInImage (const QString &serialNumber) |
Return the number of jigsaw rejected measures in image specified by serialNumber. | |
Private Attributes | |
QHash< QString, QSharedPointer< LidarControlPoint > > | m_points |
hash of LidarControlPoints | |
QMap< QString, Isis::Camera * > | p_cameraMap |
camera | |
QMap< QString, int > | p_cameraValidMeasuresMap |
#measures | |
QMap< QString, int > | p_cameraRejectedMeasuresMap |
#rejected measures | |
QVector< Isis::Camera * > | p_cameraList |
vector of image# to camera | |
int | m_numSimultaneousMeasures |
int | m_numAsynchronousMeasures |
LidarData class.
2018-01-29 Ian Humphrey - original version.
2018-01-31 Tyler Wilson - Implemented Lidar::read(Filename &).
2018-01-31 Ian Humphrey - Added insert method to insert a LidarControlPoint into the LidarData. Added documentation for m_points.
2018-02-03 Ian Humphrey - Renamed read to readCsv. read() and write() methods support JSON or binary serialization. Added documentation to new Format enumeration.
2018-03-19 Debbie A. Cook - Added simultaneousImages, apriori variance/covariance matrix, adjusted point coordinates, and adjusted variance/covariance matrix to the read and write methods. Ref #5343.
2018-06-14 Ken Edmundson - Added typedef for QSharedPointer to LidarData object.
2019-02-23 Debbie A. Cook - Added sorting option to points() method with default being to not sort. References #5343.
Definition at line 49 of file LidarData.h.
Enumerates the file formats for serializing the LidarData class.
Enumerator | |
---|---|
Binary | Serializes to a binary (QByteArray) .dat file. |
Json | Serializes to a JSON .json file. |
Test | Serializes to an ordered JSON .json file for comparing to truth data. |
Definition at line 53 of file LidarData.h.
Isis::LidarData::LidarData | ( | ) |
Default constructor.
Definition at line 38 of file LidarData.cpp.
QList< ControlMeasure * > Isis::LidarData::GetMeasuresInCube | ( | QString | serialNumber | ) |
Get all the measures pertaining to a given cube serial number.
Definition at line 682 of file LidarData.cpp.
References m_points, point(), Isis::IException::Programmer, and ValidateSerialNumber().
Referenced by GetValidMeasuresInCube().
int Isis::LidarData::GetNumberOfJigsawRejectedMeasuresInImage | ( | const QString & | serialNumber | ) |
Return the number of jigsaw rejected measures in image specified by serialNumber.
Definition at line 653 of file LidarData.cpp.
References p_cameraRejectedMeasuresMap.
int Isis::LidarData::GetNumberOfValidMeasuresInImage | ( | const QString & | serialNumber | ) |
Return the number of measures in image specified by serialNumber.
Definition at line 639 of file LidarData.cpp.
References GetValidMeasuresInCube(), p_cameraList, and p_cameraValidMeasuresMap.
QList< ControlMeasure * > Isis::LidarData::GetValidMeasuresInCube | ( | QString | serialNumber | ) |
Get all the valid measures pertaining to a given cube serial number.
Definition at line 662 of file LidarData.cpp.
References GetMeasuresInCube().
Referenced by GetNumberOfValidMeasuresInImage().
void Isis::LidarData::insert | ( | QSharedPointer< LidarControlPoint > | point | ) |
Adds a LidarControlPoint to the LidarData.
QSharedPointer<LidarControlPoint> | point LidarControlPoint to add. |
Definition at line 49 of file LidarData.cpp.
References m_points, and point().
Referenced by read().
int Isis::LidarData::numberAsynchronousMeasures | ( | ) |
Returns number of non-simultaneous lidar measures.
Definition at line 121 of file LidarData.cpp.
int Isis::LidarData::numberLidarPoints | ( | ) |
Returns number of Lidar data points.
Definition at line 102 of file LidarData.cpp.
References m_points.
int Isis::LidarData::numberMeasures | ( | ) |
Returns total number of lidar measures.
Definition at line 131 of file LidarData.cpp.
int Isis::LidarData::numberSimultaneousMeasures | ( | ) |
Returns number of simultaneous lidar measures.
Definition at line 112 of file LidarData.cpp.
QSharedPointer< LidarControlPoint > Isis::LidarData::point | ( | QString | pointId | ) | const |
Gets a single LidarDataPoint by ID.
pointId | The ID of the LidarDataPoint |
Definition at line 60 of file LidarData.cpp.
References m_points, point(), and Isis::IException::Programmer.
Referenced by GetMeasuresInCube(), insert(), and point().
QList< QSharedPointer< LidarControlPoint > > Isis::LidarData::points | ( | bool | sort = false | ) | const |
Gets the list of Lidar data points optionally sorted .
sort | An option to sort the list. The default is false (no sort). |
Definition at line 81 of file LidarData.cpp.
void Isis::LidarData::read | ( | FileName | lidarDataFile | ) |
Unserialize LidarData.
This method unserializes LidarData from a JSON or binary (QByteArray) file. It will automatically determine if it is JSON or binary formatted data.
IException::User | Throws User exception if it cannot open the file passed. |
Definition at line 281 of file LidarData.cpp.
References Isis::ControlPoint::Constrained, Isis::Angle::Degrees, insert(), Isis::Distance::Kilometers, p_cameraMap, and Isis::IException::User.
void Isis::LidarData::SetImages | ( | ControlNet & | controlNet, |
Progress * | progress = 0 ) |
TODO: more detail below...
Assigns Isis::Camera pointers to LidarControlPoint measures.
controlNet | Input ControlNet |
progress | A pointer to the progress of creating the cameras |
Isis::iException::User | - "Lidar Control point measure does not have a cube with a matching serial number" |
Definition at line 148 of file LidarData.cpp.
References Isis::ControlNet::Camera(), Isis::ControlMeasure::GetCubeSerialNumber(), m_points, p_cameraList, p_cameraMap, p_cameraRejectedMeasuresMap, p_cameraValidMeasuresMap, and Isis::IException::User.
void Isis::LidarData::SetImages | ( | SerialNumberList & | list, |
Progress * | progress = 0 ) |
Creates the ControlNet's image camera's based on the list of Serial Numbers.
list | The list of Serial Numbers |
progress | A pointer to the progress of creating the cameras |
Isis::iException::System | - "Unable to create camera for cube file" |
Isis::iException::User | - "Control point measure does not have a cube with a matching serial number" |
2009-01-06 Jeannie Walldren - Fixed typo in exception output.
2016-10-13 Ian Humphrey - Added initial check to see if cameras have already been set, and immediately return if yes. References #4293.
Definition at line 210 of file LidarData.cpp.
References Isis::Progress::CheckStatus(), Isis::CameraFactory::Create(), Isis::SerialNumberList::fileName(), Isis::ControlMeasure::GetCubeSerialNumber(), Isis::SerialNumberList::hasSerialNumber(), m_points, p_cameraList, p_cameraMap, p_cameraRejectedMeasuresMap, p_cameraValidMeasuresMap, Isis::SerialNumberList::serialNumber(), Isis::Progress::SetMaximumSteps(), Isis::Progress::SetText(), Isis::SerialNumberList::size(), Isis::IException::Unknown, and Isis::IException::User.
bool Isis::LidarData::ValidateSerialNumber | ( | QString | serialNumber | ) | const |
Does a check to ensure that the given serial number is contained within the network.
serialNumber | the cube serial number to validate |
Definition at line 626 of file LidarData.cpp.
References p_cameraMap.
Referenced by GetMeasuresInCube().
void Isis::LidarData::write | ( | FileName | outputFile, |
LidarData::Format | format ) |
Serializes LidarData.
This method serializes the LidarData to either a JSON or binary (QByteArray) file. If JSON, the file extension will be .json; otherwise (if binary), the file extension will be .dat.
FileName | outputFile Name of the file to serialize to. |
LidarData::Format | format Format of the serialized file (Json or Binary). |
IException::User | Throws User exception if it cannot open the file for writing. |
Definition at line 486 of file LidarData.cpp.
References Isis::Angle::Degrees, Isis::SurfacePoint::GetLatitude(), Isis::SurfacePoint::GetLocalRadius(), Isis::SurfacePoint::GetLongitude(), Json, Isis::Distance::kilometers(), Isis::Latitude::planetocentric(), points(), Isis::Longitude::positiveEast(), Test, and Isis::IException::User.
|
private |
Definition at line 95 of file LidarData.h.
|
private |
Definition at line 94 of file LidarData.h.
|
private |
hash of LidarControlPoints
maps between serial# and...
Definition at line 85 of file LidarData.h.
Referenced by GetMeasuresInCube(), insert(), numberLidarPoints(), point(), points(), SetImages(), and SetImages().
|
private |
vector of image# to camera
Definition at line 92 of file LidarData.h.
Referenced by GetNumberOfValidMeasuresInImage(), SetImages(), and SetImages().
|
private |
camera
Definition at line 88 of file LidarData.h.
Referenced by read(), SetImages(), SetImages(), and ValidateSerialNumber().
|
private |
#rejected measures
Definition at line 90 of file LidarData.h.
Referenced by GetNumberOfJigsawRejectedMeasuresInImage(), SetImages(), and SetImages().
|
private |
#measures
Definition at line 89 of file LidarData.h.
Referenced by GetNumberOfValidMeasuresInImage(), SetImages(), and SetImages().