Skip to content

Commit

Permalink
GnssParametrizationStaticPositions: ignored inputfileNoNetPositions.
Browse files Browse the repository at this point in the history
  • Loading branch information
tmayerguerr committed Apr 22, 2024
1 parent 8efecb8 commit 2c3d1f5
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 8 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
- New option: gnssParametrizationStaticPositions: no net scale constraint.
- Removed program: GnssPrn2SvnBlockVariables: This program will no longer work from the next release! See documentation for help.
- Removed program: NetCdf2PotentialCoefficients: Use NetCdf2GriddedDataTimeSeries and GriddedDataTimeSeries2PotentialCoefficients instead.
- Bugfix: GnssParametrizationStaticPositions: ignored inputfileNoNetPositions.
- Bugfix: SphericalHarmonicsFilter->DDK: corrected filter for level 4 onwards (Compatible with ICGEM definition).
- Bugfix: ObservationDeflections: fixed index bug.
- Bugfix: NormalEquationFile: corrected contribution computation.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,14 +92,14 @@ void GnssParametrizationStaticPositions::init(Gnss *gnss, Parallel::Communicator
if(sigmaNoNetRotation || sigmaNoNetTranslation || sigmaNoNetScale)
{
std::vector<const Platform*> platforms(gnss->receivers.size(), nullptr);
for(UInt idRecv=0; idRecv<gnss->receivers.size(); idRecv++)
if(gnss->receivers.at(idRecv)->useable())
platforms.at(idRecv) = &gnss->receivers.at(idRecv)->platform;
for(auto recv : gnss->receivers)
if(selectedReceivers.at(recv->idRecv()) && recv->useable())
platforms.at(recv->idRecv()) = &recv->platform;

// no net positions
noNetPos = pos;
if(!fileNameNoNetPositions.empty())
for(UInt idRecv=0; idRecv<selectedNoNetReceivers.size(); idRecv++)
for(UInt idRecv=0; idRecv<gnss->receivers.size(); idRecv++)
if(platforms.at(idRecv))
{
try
Expand All @@ -119,10 +119,6 @@ void GnssParametrizationStaticPositions::init(Gnss *gnss, Parallel::Communicator
}

selectedNoNetReceivers = selectNoNetReceivers->select(gnss->times.front(), gnss->times.back(), platforms);
for(auto recv : gnss->receivers)
if(selectedNoNetReceivers.at(recv->idRecv()) && !selectedReceivers.at(recv->idRecv()))
throw(Exception(recv->name()+" for no-net constraints must be selected for position estimation too"));

const UInt countStation = std::count(selectedNoNetReceivers.begin(), selectedNoNetReceivers.end(), TRUE);
logInfo<<" "<<countStation<<" stations contribute to the computation of net translation/rotation/scale"<<Log::endl;
if(!countStation)
Expand Down Expand Up @@ -277,6 +273,19 @@ void GnssParametrizationStaticPositions::constraints(const GnssNormalEquationInf
if(sigmaNoNetTranslation) logStatus<<"apply no-net translation to receiver positions, apriori ("<<1e3*x(idxNNT+0)%"%.1f, "s<<1e3*x(idxNNT+1)%"%.1f, "s<<1e3*x(idxNNT+2)%"%.1f) mm"s<<Log::endl;
if(sigmaNoNetRotation) logStatus<<"apply no-net rotation to receiver positions, apriori ("<<1e3*x(idxNNR+0)%"%.1f, "s<<1e3*x(idxNNR+1)%"%.1f, "s<<1e3*x(idxNNR+2)%"%.1f) mm"s<<Log::endl;
if(sigmaNoNetScale) logStatus<<"apply no-net scale to receiver positions, apriori ("<<1e3*x(idxNNS+0)%"%.1f) mm"s<<Log::endl;
if(sigmaNoNetRotation || sigmaNoNetTranslation || sigmaNoNetScale)
{
logWarning<<" no-net coordinate residuals rms = "<<1e3*rootMeanSquare(l-A*x)%"%.1f mm, "s<<Log::endl;
UInt i = 0;
if(sigma.size())
for(UInt idRecv=0; idRecv<gnss->receivers.size(); idRecv++)
if(selectedNoNetReceivers.at(idRecv) && index.at(idRecv))
{
if(sigma(i) > 1)
logWarning<<" "<<gnss->receivers.at(idRecv)->name()<<" outlier sigma = "<<sigma(i)%"%.2f"s<<Log::endl;
i++;
}
}

// weighted no-net constraints
GnssDesignMatrix Design(normalEquationInfo, x);
Expand Down

0 comments on commit 2c3d1f5

Please sign in to comment.