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

DM-13243: PhotoCalTask must only match with DirectMatchTask #80

Merged
merged 1 commit into from Feb 1, 2018

Conversation

ctslater
Copy link
Member

Add extra DirectMatch config with no refObjLoader.

Copy link
Contributor

@PaulPrice PaulPrice left a comment

Choose a reason for hiding this comment

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

Nice solution!

Some trivial comments.

refObjLoader = ConfigurableField(target=LoadIndexedReferenceObjectsTask, doc="Load reference objects")
class DirectMatchConfigWithoutLoader(Config):
"""Configuration for DirectMatchTask when an already-initialized
refObjLoader will be passed to this task. """
Copy link
Contributor

Choose a reason for hiding this comment

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

Excess space in docstring.

matchRadius = Field(dtype=float, default=0.25, doc="Matching radius, arcsec")
sourceSelection = ConfigurableField(target=ScienceSourceSelectorTask,
doc="Selection of science sources")
referenceSelection = ConfigurableField(target=ReferenceSourceSelectorTask,
doc="Selection of reference sources")

class DirectMatchConfig(DirectMatchConfigWithoutLoader):
Copy link
Contributor

Choose a reason for hiding this comment

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

Two lines between classes, please.

This config can be used when DirectMatchTask will be supplied a refObjLoader at
initialization, and thus it need not accept a configuration for its own loader.
Using the DirectMatchConfig in this situation is permissible (to maintain
compatibility) but the refObjLoader settings will be silently ignored.
@ctslater ctslater merged commit cf9427f into master Feb 1, 2018
@ktlim ktlim deleted the tickets/DM-13243 branch August 25, 2018 06:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants