Optimize transmission preprocess and adapt new cuda version.
This commit is contained in:
@@ -13,7 +13,6 @@
|
||||
#include "common/getMeasurementMetaData.h"
|
||||
#include "config/config.h"
|
||||
#include "calculateBankDetectAndHilbertTransformation.hpp"
|
||||
#include "transmissionReconstruction/detection/detection.cuh"
|
||||
|
||||
using namespace Aurora;
|
||||
namespace Recon {
|
||||
@@ -415,39 +414,34 @@ namespace Recon {
|
||||
return result;
|
||||
}
|
||||
|
||||
DetectResult transmissionDetection(const Aurora::CudaMatrix &AscanBlock,
|
||||
const Aurora::CudaMatrix &AscanRefBlock,
|
||||
const Aurora::CudaMatrix &distBlock,
|
||||
const Aurora::CudaMatrix &distRefBlock,
|
||||
DetectResult transmissionDetection(const Aurora::Matrix &AscanBlock,
|
||||
const Aurora::Matrix &AscanRefBlock,
|
||||
const Aurora::Matrix &distBlock,
|
||||
const Aurora::Matrix &distRefBlock,
|
||||
const Aurora::Matrix &sosWaterBlock,
|
||||
const Aurora::Matrix &sosWaterRefBlock,
|
||||
float expectedSOSWater) {
|
||||
auto _sosWaterBlock = temperatureToSoundSpeed(sosWaterBlock, "marczak").toDeviceMatrix();
|
||||
auto _sosWaterRefBlock = temperatureToSoundSpeed(sosWaterRefBlock, "marczak").toDeviceMatrix();
|
||||
auto _sosWaterBlock = temperatureToSoundSpeed(sosWaterBlock, "marczak");
|
||||
auto _sosWaterRefBlock = temperatureToSoundSpeed(sosWaterRefBlock, "marczak");
|
||||
switch (Recon::transParams::version) {
|
||||
// case 1: {
|
||||
// return detectTofAndAttMex(
|
||||
// AscanBlock, AscanRefBlock, distBlock, distRefBlock,
|
||||
// _sosWaterBlock, _sosWaterRefBlock, Recon::transParams::resampleFactor, Recon::transParams::nThreads,
|
||||
// expectedSOSWater, Recon::transParams::useTimeWindowing,
|
||||
// Recon::transParams::aScanReconstructionFrequency, Recon::transParams::detectionWindowATT,
|
||||
// Recon::transParams::offsetElectronic, Recon::transParams::detectionWindowSOS, Recon::transParams::minSpeedOfSound,
|
||||
// Recon::transParams::maxSpeedOfSound, Recon::transParams::gaussWindow);
|
||||
// }
|
||||
// case 2:
|
||||
default:
|
||||
auto r = detectTofAndAtt(
|
||||
case 1: {
|
||||
return detectTofAndAttMex(
|
||||
AscanBlock, AscanRefBlock, distBlock, distRefBlock,
|
||||
_sosWaterBlock, _sosWaterRefBlock, Recon::transParams::resampleFactor, Recon::transParams::nThreads,
|
||||
expectedSOSWater, Recon::transParams::useTimeWindowing,
|
||||
Recon::transParams::aScanReconstructionFrequency, Recon::transParams::detectionWindowATT,
|
||||
Recon::transParams::offsetElectronic, Recon::transParams::detectionWindowSOS, Recon::transParams::minSpeedOfSound,
|
||||
Recon::transParams::maxSpeedOfSound, Recon::transParams::gaussWindow);
|
||||
}
|
||||
case 2:
|
||||
default:
|
||||
return detectTofAndAtt(
|
||||
AscanBlock, AscanRefBlock, distBlock, distRefBlock,
|
||||
_sosWaterBlock, _sosWaterRefBlock, Recon::transParams::resampleFactor, Recon::transParams::nThreads,
|
||||
expectedSOSWater, Recon::transParams::useTimeWindowing,
|
||||
Recon::transParams::aScanReconstructionFrequency, Recon::transParams::detectionWindowATT,
|
||||
Recon::transParams::offsetElectronic, Recon::transParams::detectionWindowSOS, Recon::transParams::minSpeedOfSound,
|
||||
Recon::transParams::maxSpeedOfSound, Recon::transParams::gaussWindow);
|
||||
DetectResult ret;
|
||||
ret.att = r.att.toHostMatrix();
|
||||
ret.sosValue = r.sosValue.toHostMatrix();
|
||||
ret.tof = r.tof.toHostMatrix();
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user