Skip to content

Conversation

@lspitler
Copy link
Member

@lspitler lspitler commented Jan 7, 2025

No description provided.

@lspitler lspitler self-assigned this Jan 7, 2025
Copy link

@bazkiaei bazkiaei left a comment

Choose a reason for hiding this comment

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

My comments contain some minor suggestions.

"Cannot specify pixel binning with calculation type 'per arcsecond squared'!")

if surface_brightness:
if surface_brightness is not None:

Choose a reason for hiding this comment

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

Maybe when defining extended_source_signal_noise at line 311, the parameter surface_brightness should have a default value on None?


if not isinstance(surface_brightness, u.Quantity):
brightness = brightness * u.ABmag
surface_brightness = surface_brightness * u.ABmag

Choose a reason for hiding this comment

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

Perhaps it is worth checking the unit of surface_brightness when it's a u.Quantity?

raise ValueError("This Imager has no filter '{}'!".format(filter_name))

if bool(bright_limit) == bool(shortest_exp_time):
if (bright_limit is not None and shortest_exp_time is not None) or (bright_limit is None and shortest_exp_time is None):

Choose a reason for hiding this comment

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

I feel the ValueError message is not for the second condition after "or".

Perhaps there should be another "if" block to raise ValueError when neither of bright_limit and shortest_exp_time are provided and have a different message that let the user know one of the two should be provided?


if bool(faint_limit) == bool(num_long_exp):
raise ValueError("one and only one of faint_limit and num_long_exp must be specified!")
if (faint_limit is not None and num_long_exp is not None) or (faint_limit is None and num_long_exp is None):

Choose a reason for hiding this comment

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

The same as the previous comment.

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.

3 participants