Add progress notify

This commit is contained in:
kradchen
2023-09-12 09:53:30 +08:00
parent 1e6dfaf212
commit b2721db958
12 changed files with 118 additions and 25 deletions

View File

@@ -3,6 +3,7 @@
#include "Matrix.h"
#include "log/log.h"
#include "common/dataBlockCreation/removeDataFromArrays.h"
#include "log/notify.h"
#include "src/transmissionReconstruction/dataFilter/dataFilter.h"
#include "src/transmissionReconstruction/dataPreperation.h"
#include "src/common/getMeasurementMetaData.h"
@@ -25,21 +26,25 @@ TransmissionReconstructionResult Recon::startTransmissionReconstruction(const Au
{
RECON_INFO("Start getTransmissionData.");
auto transmissionData = getTransmissionData(aMotorPos, aMotoPosRef, aSlList, aSnList, aRlList, aRnList, aTemp, aTempRef,
aGeom, aGeomRef, aExpInfo, aExpInfoRef, aPreComputes, aParser, aParserRef);
aGeom, aGeomRef, aExpInfo, aExpInfoRef, aPreComputes, aParser, aParserRef);
Matrix dists = Recon::distanceBetweenTwoPoints(transmissionData.senderList, transmissionData.receiverList);
Matrix sosRef = Recon::temperatureToSoundSpeed(transmissionData.waterTempList, "marczak");
Recon::notifyProgress(17);
Matrix valid = Recon::checkTofDetections(transmissionData.tofDataTotal, dists, sosRef,
Recon::transParams::minSpeedOfSound,Recon::transParams::maxSpeedOfSound).valid;
Recon::notifyProgress(18);
if(transParams::qualityCheck)
{
qualityReview(sum(valid,Aurora::All)[0], transmissionData.dataInfo.numPossibleScans);
}
}
Recon::notifyProgress(19);
DiscretizePositionValues positionValues = Recon::discretizePositions(transmissionData.senderList, transmissionData.receiverList, Recon::transParams::numPixelXY);
Matrix tofData = removeDataFromArrays(transmissionData.tofDataTotal, valid);
Matrix attData = removeDataFromArrays(transmissionData.attDataTotal, valid);
Matrix senderList = removeDataFromArrays(positionValues.senderCoordList, valid);
Matrix reveiverList = removeDataFromArrays(positionValues.receiverCoordList, valid);
Recon::notifyProgress(20);
RECON_INFO("Start reconstructArt.");
auto transmissionReon = reconstructArt(tofData, attData, positionValues.dims, senderList, reveiverList, positionValues.res, aTemp.expectedSOSWater[0]);