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

Implement PhotoCalib ops that output to catalogs. #265

Merged
merged 1 commit into from Aug 11, 2017

Conversation

TallJimbo
Copy link
Member

Names used here will have to be updated when RFC-322 is adopted.

This PR is a new one (against master) that supercedes #262.

Copy link
Contributor

@r-owen r-owen left a comment

Choose a reason for hiding this comment

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

Looks great. One trivial suggestion (and related question) that applies to two places.

auto maggiesKey = sourceCatalog.getSchema().find<double>(outField + "_calFlux").key;
auto maggiesErrKey = sourceCatalog.getSchema().find<double>(outField + "_calFluxErr").key;
for (auto & record : sourceCatalog) {
auto result = instFluxToMaggies(record.get(instFluxKey), record.get(instFluxErrKey),
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider auto const.

I'm also curious if auto const & would be give better performance, but I hope the answer is "no".

Copy link
Member Author

Choose a reason for hiding this comment

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

It shouldn't change the performance, but we can't use it here anyway because we also call set.

auto magKey = sourceCatalog.getSchema().find<double>(outField + "_mag").key;
auto magErrKey = sourceCatalog.getSchema().find<double>(outField + "_magErr").key;
for (auto & record : sourceCatalog) {
auto result = instFluxToMagnitude(record.get(instFluxKey), record.get(instFluxErrKey),
Copy link
Contributor

Choose a reason for hiding this comment

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

Likewise

Names used here will have to be updated when RFC-322 is adopted.
@TallJimbo TallJimbo merged commit 2a3e2ee into master Aug 11, 2017
@ktlim ktlim deleted the tickets/DM-10729 branch August 25, 2018 06:43
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.

None yet

2 participants