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-47368: Restrict when subtractImages sources selector raises #350

Merged
merged 1 commit into from
Nov 5, 2024

Conversation

isullivan
Copy link
Contributor

Do not raise an error in source selection if allowKernelSourceDetection=True

@@ -822,7 +822,8 @@ def _sourceSelector(self, sources, mask):
self.log.error("Too few sources to calculate the PSF matching kernel: "
"%i selected but %i needed for the calculation.",
len(selectSources), self.config.minKernelSources)
raise RuntimeError("Cannot compute PSF matching kernel: too few sources selected.")
if ~self.config.allowKernelSourceDetection:
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
if ~self.config.allowKernelSourceDetection:
if not self.config.allowKernelSourceDetection:

@isullivan isullivan merged commit dd07d4d into main Nov 5, 2024
2 checks passed
@isullivan isullivan deleted the tickets/DM-47368 branch November 5, 2024 02:58
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