Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed unused code identified by clang-tidy and me #308

Merged
merged 2 commits into from
Jul 23, 2020

Conversation

krlberry
Copy link
Contributor

@krlberry krlberry commented Jul 23, 2020

Also fixed a focalPlaneY that should have been a focalPlaneX.
Also fixes logging file environment variable name #299.

@krlberry krlberry requested a review from jessemapel July 23, 2020 20:11
return csm::ImageVector(m_nLines, m_nSamples);
}

//---------------------------------------------------------------------------
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed because this was commented-out, and getSensorModelState() was updated to getModelState() in the 3.0.3 version of the CSM API.

(detectorSample + m_detectorSampleOrigin - m_startingDetectorSample) /
m_detectorSampleSumming;

double precision =
Copy link
Contributor Author

@krlberry krlberry Jul 23, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed this because it wasn't used, but I find the lack of any logic in here determining whether achievedPrecision is true or not confusing. Any ideas?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The next block reports the final achieved precision.

double& achieved_precision,
const double& desired_precision) const;

// Intersects the los with a specified plane.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not used.

@@ -521,7 +521,6 @@ csm::EcefCoord UsgsAstroSarSensorModel::imageToGround(
// Compute the spacecraft position in the new coordinate system
// The cross-track unit vector is orthogonal to the position so we ignore it
double nadirComp = dot(spacecraftPosition, tHat);
double inTrackComp = dot(spacecraftPosition, vHat);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jessemapel Just want to double check that this wasn't needed in the calculation somewhere? It's not used right now.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope I just rechecked Randy's notes and it's not used.

@krlberry
Copy link
Contributor Author

krlberry commented Jul 23, 2020

Partial fix to #304 and Fixes #299

@jessemapel jessemapel merged commit ad28052 into DOI-USGS:dev Jul 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants