9 #include <QtAlgorithms>
12 #include <QMutexLocker>
15 #include <QScopedPointer>
20 #include <boost/numeric/ublas/symmetric.hpp>
21 #include <boost/numeric/ublas/io.hpp>
26 #include "ControlNetFile.h"
40 using namespace boost::numeric::ublas;
45 void ControlNet::nullify() {
48 cubeGraphNodes = NULL;
54 ControlNet::ControlNet() {
64 p_created = Application::DateTime();
65 p_modified = Application::DateTime();
69 ControlNet::ControlNet(
const ControlNet &other) {
77 for (
int cpIndex = 0; cpIndex < other.
GetNumPoints(); cpIndex++) {
103 ControlNet::ControlNet(
const QString &ptfile,
Progress *progress) {
115 ReadControl(ptfile, progress);
128 ControlNet::~ControlNet() {
133 delete cubeGraphNodes;
148 void ControlNet::clear() {
152 if (GetNumPoints() > 0) {
154 QHashIterator<QString, ControlPoint*> i(*points);
155 while (i.hasNext()) {
157 delete(*points)[i.key()];
158 (*points)[i.key()] = NULL;
165 if (cubeGraphNodes) {
166 QHashIterator< QString, ControlCubeGraphNode * > i(*cubeGraphNodes);
167 while (i.hasNext()) {
169 delete(*cubeGraphNodes)[i.key()];
170 (*cubeGraphNodes)[i.key()] = NULL;
172 cubeGraphNodes->clear();
205 throw IException(IException::Programmer,
"Ownership has already been taken",
214 for (
int i = 0; i < points.size(); i++) {
215 points[i]->parentNetwork = NULL;
243 void ControlNet::ReadControl(
const QString &filename,
Progress *progress) {
248 p_networkId = header.networkid().c_str();
249 if (header.has_targetname()) {
250 SetTarget(header.targetname().c_str());
256 p_userName = header.username().c_str();
257 p_created = header.created().c_str();
258 p_modified = header.lastmodified().c_str();
259 p_description = header.description().c_str();
264 if (fileDataPoints.size() > 0) {
265 if (progress != NULL) {
266 progress->
SetText(
"Loading Control Points...");
272 foreach(fileDataPoint, fileDataPoints) {
274 p_targetRadii[0], p_targetRadii[1], p_targetRadii[2]));
276 if (progress != NULL)
302 void ControlNet::Write(
const QString &ptfile,
bool pvl) {
307 header.set_networkid(p_networkId.toLatin1().data());
308 header.set_targetname(p_targetName.toLatin1().data());
309 header.set_username(p_userName.toLatin1().data());
310 header.set_created(p_created.toLatin1().data());
311 header.set_lastmodified(p_modified.toLatin1().data());
312 header.set_description(p_description.toLatin1().data());
317 for (
int i = 0; i < pointIds->size(); i++) {
321 fileDataPoints.append(pointFileEntry);
324 ControlNetVersioner::Write(ptfile, *fileData, pvl);
341 IString msg =
"Null pointer passed to ControlNet::AddPoint!";
345 if (ContainsPoint(point->
GetId())) {
346 IString msg =
"ControlPoint must have unique Id";
350 QString pointId = point->
GetId();
351 points->insert(pointId, point);
352 pointIds->append(pointId);
358 measureAdded(measure);
360 emit networkStructureModified();
379 IString msg =
"NULL measure passed to "
380 "ControlNet::AddControlCubeGraphNode!";
386 IString msg =
"Control measure with NULL parent passed to "
387 "ControlNet::AddControlCubeGraphNode!";
391 if (!ContainsPoint(point->
GetId())) {
392 QString msg =
"ControlNet does not contain the point [";
393 msg += point->
GetId() +
"]";
398 for (
int i = 0; i < point->GetNumMeasures(); i++) {
400 if (!cubeGraphNodes->contains(sn)) {
412 if (!point->IsIgnored() && !measure->IsIgnored()) {
413 for (
int i = 0; i < point->GetNumMeasures(); i++) {
415 if (!cm->IsIgnored()) {
419 if (neighborNode != node) {
420 node->addConnection(neighborNode, point);
421 neighborNode->addConnection(node, point);
443 IString msg =
"NULL measure passed to "
444 "ControlNet::AddControlCubeGraphNode!";
450 IString msg =
"Control measure with NULL parent passed to "
451 "ControlNet::AddControlCubeGraphNode!";
455 if (!ContainsPoint(point->
GetId())) {
456 QString msg =
"ControlNet does not contain the point [";
457 msg += point->
GetId() +
"]";
462 for (
int i = 0; i < point->GetNumMeasures(); i++) {
464 if (!cubeGraphNodes->contains(sn)) {
465 QString msg =
"Node does not exist for [";
471 if (!point->IsIgnored()) {
477 for (
int i = 0; i < point->GetNumMeasures(); i++) {
479 if (!cm->IsIgnored()) {
482 if (neighborNode != node) {
483 node->addConnection(neighborNode, point);
484 neighborNode->addConnection(node, point);
500 void ControlNet::UpdatePointReference(
ControlPoint *point, QString oldId) {
501 points->remove(oldId);
502 (*points)[point->
GetId()] = point;
503 (*pointIds)[pointIds->indexOf((QString) oldId)] = (QString)point->
GetId();
518 ASSERT(cubeGraphNodes->contains(serial));
522 if (!measure->IsIgnored() && !measure->Parent()->IsIgnored()) {
524 measureIgnored(measure);
529 node->removeMeasure(measure);
530 if (!node->getMeasureCount()) {
533 cubeGraphNodes->remove(serial);
540 IString msg =
"NULL measure passed to "
541 "ControlNet::AddControlCubeGraphNode!";
545 ControlPoint *point = measure->Parent();
547 IString msg =
"Control measure with NULL parent passed to "
548 "ControlNet::AddControlCubeGraphNode!";
549 throw IException(IException::Programmer, msg,
_FILEINFO_);
553 if (!cubeGraphNodes->contains(serial)) {
554 QString msg =
"Node does not exist for [";
556 throw IException(IException::Programmer, msg,
_FILEINFO_);
559 ControlCubeGraphNode *node = (*cubeGraphNodes)[serial];
562 for (
int i = 0; i < point->GetNumMeasures(); i++) {
563 QString sn = point->GetMeasure(i)->GetCubeSerialNumber();
564 if (cubeGraphNodes->contains(sn)) {
565 ControlCubeGraphNode *neighborNode = (*cubeGraphNodes)[sn];
566 if (node != neighborNode) {
567 neighborNode->removeConnection(node, point);
568 node->removeConnection(neighborNode, point);
575 void ControlNet::emitNetworkStructureModified() {
576 emit networkStructureModified();
597 for (
int i = 0; i < nodes.size(); i++)
598 searchList.insert(nodes[i],
false);
607 if (!results.contains(curNode)) {
609 results.insert(curNode);
610 searchList[curNode] =
true;
615 for (
int i = 0; i < neighbors.size(); i++)
616 q.enqueue(neighbors[i]);
620 return results.values();
630 for (
int i = list.size() - 1; i > 0; i--) {
633 int j = (int)(qrand() / (RAND_MAX + 1.0) * (i + 1));
634 qSwap(list[j], list[i]);
655 for (
int i = 0; i < serials.size(); i++)
656 ASSERT(cubeGraphNodes->contains(serials[i]));
661 for (
int i = 0; i < serials.size(); i++) {
664 for (
int j = 0; j < serials.size(); j++) {
667 int colDiff = abs(i - j);
668 if (node1->isConnected(node2) && colDiff > colWidth)
672 colWidths.append(colWidth);
677 int criticalEdges = 0;
678 foreach(
int width, colWidths) {
683 return qMakePair(bw, criticalEdges);
693 if (points->values().contains(point)) {
694 return DeletePoint(point->
GetId());
699 msg +=
"] does not exist in the network";
712 int ControlNet::DeletePoint(QString pointId) {
713 if (!points->contains(pointId)) {
714 IString msg =
"point Id [" + pointId +
"] does not exist in the network";
720 if (point->IsEditLocked())
721 return ControlPoint::PointLocked;
723 bool wasIgnored = point->IsIgnored();
727 measureDeleted(measure);
732 if (p_invalid && point->IsInvalid())
736 points->remove(pointId);
737 pointIds->removeAt(pointIds->indexOf(pointId));
748 for (
int i = 0; i < keys.size() && !p_invalid; i++) {
749 if (points->count(keys[i]) > 1)
755 emit networkStructureModified();
757 return ControlPoint::Success;
766 int ControlNet::DeletePoint(
int index) {
767 if (index < 0 || index >= pointIds->size()) {
772 return DeletePoint(pointIds->at(index));
781 bool ControlNet::ContainsPoint(QString pointId)
const {
782 return points->contains(pointId);
800 for (
int i = 0; i < islands.size(); i++) {
802 islandStrings.append(newIsland);
803 for (
int j = 0; j < islands[i].size(); j++)
804 islandStrings[i].append(islands[i][j]->getSerialNumber());
806 return islandStrings;
830 for (
int i = 0; i < island.size(); i++)
831 notYetFound.removeOne(island[i]);
834 islands.append(island);
836 while (notYetFound.size());
908 for (
int i = 0; i < island.size(); i++) {
911 forest.insert(node->getSerialNumber(),
new ControlVertex(node));
915 for (
int j = 0; j < measures.size(); j++) {
916 edges.append(measures[j]);
923 uniquePoints.insert(measures[j]->Parent(), 0);
928 qSort(edges.begin(), edges.end(), lessThan);
932 for (
int i = 0; i < pointList.size(); i++) {
940 int trees = forest.size();
944 while (trees > 1 && edges.size() > 0) {
951 QString pointId = leastEdge->Parent()->
GetId();
954 QString serialNum = leastEdge->ControlSN()->getSerialNumber();
962 ControlVertex::join(pointVertex, nodeVertex);
964 minimumTree.insert(leastEdge);
965 uniquePoints[pointVertex->
getPoint()]++;
974 for (
int i = 0; i < unprunedEdges.size(); i++) {
975 if (uniquePoints[unprunedEdges[i]->Parent()] < 2)
978 minimumTree.remove(unprunedEdges[i]);
984 for (
int i = 0; i < vertexList.size(); i++)
delete vertexList[i];
988 int n = island.size();
989 int e = minimumTree.size();
991 if (e < n || e > 2 * n) {
993 "] > 1 nodes must have a minimum spanning tree of e edges such that "
994 " n <= e <= 2n, but e = [" +
IString(e) +
"]";
1006 int ControlNet::getEdgeCount()
const {
1009 total += node->getAdjacentNodes().size();
1021 QString ControlNet::CubeGraphToString()
const {
1023 QHashIterator < QString, ControlCubeGraphNode * > i(*cubeGraphNodes);
1024 while (i.hasNext()) {
1026 serials << i.value()->getSerialNumber();
1031 for (
int i = 0; i < serials.size(); i++) {
1032 str +=
" " + serials[i] +
"\n"
1033 + (*cubeGraphNodes)[serials[i]]->connectionsToString() +
"\n";
1049 return cubeGraphNodes->keys();
1057 return cubeGraphNodes->values();
1067 void ControlNet::ValidateSerialNumber(QString serialNumber)
const {
1068 if (!cubeGraphNodes->contains(serialNumber)) {
1069 IString msg =
"Cube Serial Number [" + serialNumber +
"] not found in "
1082 ValidateSerialNumber(serialNumber);
1083 return (*cubeGraphNodes)[serialNumber]->getMeasures();
1095 if (
this != &other) {
1096 this->m_accessor = other.m_accessor;
1109 bool ControlNet::ControlMeasureLessThanFunctor::operator()
1112 return (a->*this->m_accessor)() < (b->*this->m_accessor)();
1125 double min,
double max) {
1131 int nObjPts = this->GetNumPoints();
1132 for (
int i=0;i<nObjPts;i++) {
1134 if (point->IsIgnored())
continue;
1137 int nObs = point->GetNumMeasures();
1138 for (
int j=0;j<nObs;j++) {
1140 if (measure->IsIgnored())
continue;
1141 double temp = (measure->*statFunc)();
1143 if (min <= temp && temp <= max) measures.push_back(measure);
1149 qSort(measures.begin(),measures.end(),lessThan);
1160 void ControlNet::DeleteMeasuresWithId(QString serialNumber) {
1161 ValidateSerialNumber(serialNumber);
1166 measure->Parent()->
Delete(measure);
1176 void ControlNet::ComputeResiduals() {
1179 QHashIterator< QString, ControlPoint * > i(*points);
1180 while (i.hasNext()) {
1182 i.value()->ComputeResiduals();
1192 void ControlNet::ComputeApriori() {
1194 QHashIterator< QString, ControlPoint * > i(*points);
1195 while (i.hasNext()) {
1198 if ( !point->IsIgnored() )
1210 double ControlNet::AverageResidual() {
1212 double avgResidual = 0.0;
1214 QHashIterator< QString, ControlPoint * > i(*points);
1215 while (i.hasNext()) {
1218 if (!point->IsIgnored()) {
1220 &ControlMeasure::GetResidualMagnitude).
Average();
1226 avgResidual /= count;
1240 return p_cameraList[index];
1251 QString ControlNet::CreatedDate()
const {
1261 QString ControlNet::Description()
const {
1262 return p_description;
1279 double sample,
double line) {
1280 if (!cubeGraphNodes->contains(serialNumber)) {
1281 QString msg =
"serialNumber [";
1282 msg += serialNumber;
1283 msg +=
"] not found in ControlNet";
1287 const double SEARCH_DISTANCE = 99999999.0;
1288 double minDist = SEARCH_DISTANCE;
1293 for (
int i = 0; i < measures.size(); i++) {
1297 double dx = fabs(sample - measureToCheck->GetSample());
1298 double dy = fabs(line - measureToCheck->GetLine());
1300 double dist = sqrt((dx * dx) + (dy * dy));
1302 if (dist < minDist) {
1304 closestPoint = measureToCheck->Parent();
1308 if (!closestPoint) {
1309 IString msg =
"No point found within ";
1310 msg +=
IString(SEARCH_DISTANCE);
1311 msg +=
"pixels of sample/line [";
1319 return closestPoint;
1324 bool ControlNet::IsValid()
const {
1335 double ControlNet::GetMaximumResidual() {
1338 double maxResidual = 0.0;
1341 &ControlMeasure::GetResidualMagnitude).
Maximum();
1342 if (residual > maxResidual)
1343 maxResidual = residual;
1350 QString ControlNet::GetNetworkId()
const {
1361 int ControlNet::GetNumEditLockMeasures() {
1362 int numLockedMeasures = 0;
1367 return numLockedMeasures;
1376 int ControlNet::GetNumEditLockPoints() {
1377 int editLockPoints = 0;
1379 if (p->IsEditLocked())
1383 return editLockPoints;
1393 int ControlNet::GetNumIgnoredMeasures() {
1394 int numIgnoredMeasures = 0;
1399 return numIgnoredMeasures;
1411 int ControlNet::GetNumberOfValidMeasuresInImage(
const QString &serialNumber) {
1412 return p_cameraValidMeasuresMap[serialNumber];
1421 int ControlNet::GetNumberOfJigsawRejectedMeasuresInImage(
const QString &serialNumber) {
1422 return p_cameraRejectedMeasuresMap[serialNumber];
1431 void ControlNet::ClearJigsawRejected() {
1442 void ControlNet::IncrementNumberOfRejectedMeasuresInImage(
const QString &serialNumber) {
1443 p_cameraRejectedMeasuresMap[serialNumber]++;
1451 void ControlNet::DecrementNumberOfRejectedMeasuresInImage(
const QString &serialNumber) {
1452 if (p_cameraRejectedMeasuresMap[serialNumber] > 0)
1453 p_cameraRejectedMeasuresMap[serialNumber]--;
1462 int ControlNet::GetNumMeasures()
const {
1463 int numMeasures = 0;
1465 numMeasures += p->GetNumMeasures();
1473 int ControlNet::GetNumPoints()
const {
1474 return points->size();
1487 int ControlNet::GetNumValidMeasures() {
1488 int numValidMeasures = 0;
1490 if (!p->IsIgnored())
1494 return numValidMeasures;
1503 int ControlNet::GetNumValidPoints() {
1504 int validPoints = 0;
1506 if (!p->IsIgnored())
1515 QString ControlNet::GetTarget()
const {
1516 return p_targetName;
1521 QString ControlNet::GetUserName()
const {
1530 for (
int i = 0; i < pointIds->size(); i++) {
1531 orderedPoints.append(GetPoint(i));
1534 return orderedPoints;
1549 void ControlNet::SetCreatedDate(
const QString &date) {
1559 void ControlNet::SetDescription(
const QString &newDescription) {
1560 p_description = newDescription;
1569 void ControlNet::SetImages(
const QString &imageListFile) {
1592 if (p_cameraList.size() > 0) {
1596 if (progress != NULL) {
1597 progress->
SetText(
"Setting input images...");
1602 for (
int i = 0; i < list.
size(); i++) {
1604 QString filename = list.
fileName(i);
1605 Cube cube(filename,
"r");
1609 p_cameraMap[serialNumber] = cam;
1610 p_cameraValidMeasuresMap[serialNumber] = 0;
1611 p_cameraRejectedMeasuresMap[serialNumber] = 0;
1612 p_cameraList.push_back(cam);
1615 QString msg =
"Unable to create camera for cube file ";
1620 if (progress != NULL)
1625 QHashIterator< QString, ControlPoint * > p(*points);
1626 while (p.hasNext()) {
1631 for (
int m = 0; m < serialNums.size(); m++) {
1636 curMeasure->
SetCamera(p_cameraMap[serialNumber]);
1639 if (!curMeasure->IsIgnored()) p_cameraValidMeasuresMap[serialNumber]++;
1644 "] does not have a cube with a matching serial number";
1657 void ControlNet::SetModifiedDate(
const QString &date) {
1669 void ControlNet::SetMutex(QMutex *mutex) {
1679 void ControlNet::SetNetworkId(
const QString &
id) {
1695 void ControlNet::SetTarget(
const QString &target) {
1696 QScopedPointer <QMutexLocker> locker;
1699 locker.reset(
new QMutexLocker(m_mutex));
1702 p_targetName = target;
1704 p_targetRadii.clear();
1706 PvlGroup pvlRadii = Target::radiiGroup(target);
1707 p_targetRadii.push_back(
Distance(pvlRadii[
"EquatorialRadius"],
1710 p_targetRadii.push_back(
Distance(pvlRadii[
"EquatorialRadius"],
1712 p_targetRadii.push_back(
Distance(pvlRadii[
"PolarRadius"],
1717 p_targetRadii.push_back(
Distance());
1718 p_targetRadii.push_back(
Distance());
1719 p_targetRadii.push_back(
Distance());
1731 void ControlNet::SetTarget(
Pvl label) {
1732 QScopedPointer <QMutexLocker> locker;
1735 locker.reset(
new QMutexLocker(m_mutex));
1739 p_targetRadii.
clear();
1743 mapping = label.
findGroup(
"Mapping", Pvl::Traverse);
1748 Distance equatorialRadius, polarRadius;
1752 mapping = Target::radiiGroup(label, mapping);
1756 equatorialRadius =
Distance(mapping[
"EquatorialRadius"], Distance::Meters);
1757 polarRadius =
Distance(mapping[
"PolarRadius"], Distance::Meters);
1759 p_targetRadii.push_back(equatorialRadius);
1760 p_targetRadii.push_back(equatorialRadius);
1761 p_targetRadii.push_back(polarRadius);
1765 p_targetRadii.push_back(
Distance());
1766 p_targetRadii.push_back(
Distance());
1767 p_targetRadii.push_back(
Distance());
1771 p_targetName = mapping[
"TargetName"][0];
1790 void ControlNet::SetTarget(
const QString &target,
1792 QScopedPointer <QMutexLocker> locker;
1795 locker.reset(
new QMutexLocker(m_mutex));
1798 if (radii.size() != 3) {
1800 "Unable to set target radii. The given list must have length 3.",
1804 p_targetName = target;
1805 p_targetRadii = radii.toStdVector();
1815 void ControlNet::SetUserName(
const QString &name) {
1835 std::swap(points, other.
points);
1837 std::swap(pointIds, other.pointIds);
1838 std::swap(m_mutex, other.m_mutex);
1853 QHashIterator< QString, ControlPoint * > i(*points);
1854 while (i.hasNext()) {
1855 i.next().value()->parentNetwork =
this;
1858 QHashIterator< QString, ControlPoint * > i2(*other.
points);
1859 while (i2.hasNext()) {
1860 i2.next().value()->parentNetwork = &other;
1874 if (
this != &other) {
1884 const ControlPoint *ControlNet::GetPoint(QString
id)
const {
1885 if (!points->contains(
id)) {
1886 IString msg =
"The control network has no control points with an ID "
1887 "equal to [" +
id +
"]";
1891 return points->value(
id);
1895 ControlPoint *ControlNet::GetPoint(QString
id) {
1896 if (!points->contains(
id)) {
1897 IString msg =
"The control network has no control points with an ID "
1898 "equal to [" +
id +
"]";
1899 throw IException(IException::Programmer, msg,
_FILEINFO_);
1902 return (*points)[id];
1906 const ControlPoint *ControlNet::GetPoint(
int index)
const {
1907 if (index < 0 || index >= pointIds->size()) {
1908 IString msg =
"Index [" + IString(index) +
"] out of range";
1909 throw IException(IException::Programmer, msg,
_FILEINFO_);
1912 return GetPoint(pointIds->at(index));
1916 ControlPoint *ControlNet::GetPoint(
int index) {
1917 if (index < 0 || index >= pointIds->size()) {
1918 IString msg =
"Index [" + IString(index) +
"] out of range";
1919 throw IException(IException::Programmer, msg,
_FILEINFO_);
1922 return GetPoint(pointIds->at(index));
1926 const ControlCubeGraphNode *ControlNet::getGraphNode(
1927 QString serialNumber)
const {
1928 if (!cubeGraphNodes->contains(serialNumber)) {
1929 IString msg =
"Serial Number [" + serialNumber +
"] does not exist in"
1931 throw IException(IException::Programmer, msg,
_FILEINFO_);
1934 return cubeGraphNodes->value(serialNumber);
1937 ControlCubeGraphNode *ControlNet::getGraphNode(
1938 QString serialNumber) {
1939 if (!cubeGraphNodes->contains(serialNumber)) {
1940 IString msg =
"Serial Number [" + serialNumber +
"] does not exist in"
1942 throw IException(IException::Programmer, msg,
_FILEINFO_);
1945 return cubeGraphNodes->value(serialNumber);
1954 std::vector<Distance> ControlNet::GetTargetRadii() {
1955 return p_targetRadii;
1959 const ControlPoint *ControlNet::operator[](QString
id)
const {
1960 return GetPoint(
id);
1964 ControlPoint *ControlNet::operator[](QString
id) {
1965 return GetPoint(
id);
1969 const ControlPoint *ControlNet::operator[](
int index)
const {
1970 return GetPoint(index);
1974 ControlPoint *ControlNet::operator[](
int index) {
1975 return GetPoint(index);
bool p_invalid
If the Control Network is currently invalid.
Serial Number with added functionality for Control Networks.
Encapsulation of a vertex in a minimum spanning tree.
void SetMaximumSteps(const int steps)
This sets the maximum number of steps in the process.
QString p_targetName
Name of the target.
PvlGroupIterator findGroup(const QString &name, PvlGroupIterator beg, PvlGroupIterator end)
Find a group with the specified name, within these indexes.
bool hasSerialNumber(QString sn)
Determines whether or not the requested serial number exists in the list.
Status ComputeApriori()
This method computes the apriori lat/lon for a point.
Statistics GetStatistic(double(ControlMeasure::*statFunc)() const) const
This function will call a given method on every control measure that this point has.
int size() const
How many serial number / filename combos are in the list.
std::vector< Distance > p_targetRadii
Radii of target body.
PvlObjectIterator findObject(const QString &name, PvlObjectIterator beg, PvlObjectIterator end)
Find the index of object with a specified name, between two indexes.
void ClearJigsawRejected()
Set jigsaw rejected flag for all measures to false and set the jigsaw rejected flag for the point its...
QString p_description
Textual Description of network.
QString serialNumber(const QString &filename)
Return a serial number given a filename.
ControlPoint * getPoint()
Get the point representation of this vertex.
std::vector< Isis::Camera * > p_cameraList
Vector of image number to camera.
int GetNumValidMeasures() const
QString p_networkId
The Network Id.
ControlNet * parentNetwork
List of Control Measures.
ControlNetFileHeaderV0002 & GetNetworkHeader()
Get the control network level information - things like NetworkID, TargetName, etc...
int GetNumPoints() const
Return the number of control points in the network.
Unless noted otherwise, the portions of Isis written by the USGS are public domain.
Distance measurement, usually in meters.
QString p_created
Creation Date.
void CheckStatus()
Checks and updates the status.
QString fileName(const QString &sn)
Return a filename given a serial number.
QList< ControlPointFileEntryV0002 > & GetNetworkPoints()
Get the control point data along with the log data.
Program progress reporter.
QString p_userName
The user who created the network.
QString GetId() const
Return the Id of the control point.
Status SetCamera(Isis::Camera *camera)
Set pointer to camera associated with a measure.
void SetText(const QString &text)
Changes the value of the text string reported just before 0% processed.
std::map< QString, int > p_cameraValidMeasuresMap
A map from serialnumber to #measures.
Contains multiple PvlContainers.
double Average() const
Computes and returns the average.
#define _FILEINFO_
Macro for the filename and line number.
void addMeasure(ControlMeasure *measure)
Adds a measure.
double Maximum() const
Returns the absolute maximum double found in all data passed through the AddData method.
std::map< QString, int > p_cameraRejectedMeasuresMap
A map from serialnumber to #rejected measures ...
ControlVertex * getRoot()
Get the root node, or greatest ancestor.
Container for cube-like labels.
QHash< QString, ControlPoint * > * points
hash ControlPoints by ControlPoint Id
bool hasObject(const QString &name) const
Returns a boolean value based on whether the object exists in the current PvlObject or not...
QList< ControlMeasure * > getMeasures(bool excludeIgnored=false) const
Adds specific functionality to C++ strings.
QString GetCubeSerialNumber() const
Return the serial number of the cube containing the coordinate.
Handle Binary Control Network Files version 2.
bool hasGroup(const QString &name) const
Returns a boolean value based on whether the object has the specified group or not.
int GetNumLockedMeasures() const
Returns the number of locked control measures.
int Delete(ControlMeasure *measure)
Remove a measurement from the control point, deleting reference measure is allowed.
QString p_modified
Date Last Modified.
Serial Number list generator.
const ControlMeasure * GetMeasure(QString serialNumber) const
Get a control measure based on its cube's serial number.
QList< QString > getCubeSerialNumbers() const
bool hasKeyword(const QString &name) const
Check to see if a keyword exists.
void clear()
Clears PvlKeywords.
std::map< QString, Isis::Camera * > p_cameraMap
A map from serialnumber to camera.
QHash< QString, ControlCubeGraphNode * > * cubeGraphNodes
hash ControlCubeGraphNodes by CubeSerialNumber
IO Handler for Isis Cubes.