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

Created SNR vs Wavelength notebook #104

Merged
merged 4 commits into from
Aug 26, 2022
Merged

Created SNR vs Wavelength notebook #104

merged 4 commits into from
Aug 26, 2022

Conversation

jenniferzzhang
Copy link
Contributor

No description provided.

@jenniferzzhang jenniferzzhang added this to the V1.0 milestone Aug 18, 2022
@jenniferzzhang jenniferzzhang requested a review from DM1122 August 18, 2022 23:26
@jenniferzzhang jenniferzzhang self-assigned this Aug 18, 2022
@jenniferzzhang jenniferzzhang linked an issue Aug 18, 2022 that may be closed by this pull request
3 tasks
Copy link
Collaborator

@DM1122 DM1122 left a comment

Choose a reason for hiding this comment

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

Excellent job! You solved a very tough problem, you can pat yourself on the back for that. There's just a couple cleanup things to resolve and then we're good to merge. Let's get this bread!


a_i = math.pi * (self.d_i / 2) ** 2
a_i = math.pi * (self.image_diameter / 2) ** 2
Copy link
Collaborator

Choose a reason for hiding this comment

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

It looks like this method already exists on line 40. Let's remove this duplicate.

Comment on lines 105 to 108

# print("n well", self.n_well)
# print("n bit", self.n_bit)

Copy link
Collaborator

Choose a reason for hiding this comment

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

Let's remove unused print statements to keep the code clean.

Comment on lines 76 to 77
"""Get the ratio of the light passing through slit to the image of the
foreoptic."""
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggestion:

Get the ratio of the light area passing through the slit to the area of the image of the foreoptic.

Comment on lines 100 to 113
# print("wavelength", wavelength)
# print("ratio", self.get_ratio_cropped_light_through_slit())
# print("pixel area", self.sensor.get_pixel_area())
# print("f num", self.foreoptic.get_f_number())
# print("QE", self.sensor.efficiency(wavelength).decompose() * unit.electron)
# print("efficiency", self.sensor.efficiency(wavelength))
# print("transmittance", self.get_transmittance())
# print("area", self.slit.get_area())
# print("radiance", radiance(wavelength))
# print("sensor dt", self.sensor.dt)
# print("n bin", self.sensor.n_bin)
# print("dark noise", self.sensor.get_dark_noise())
# print("quantization noise", self.sensor.get_quantization_noise())
# print("noise read", self.sensor.noise_read)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Let's remove commented code once its no longer needed.

LOG.info(f"SNR: {snr}")


def test_get_f_number_units():
Copy link
Collaborator

Choose a reason for hiding this comment

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

Let's add a docstring here for clarity.

@DM1122 DM1122 merged commit 9944ac0 into dev Aug 26, 2022
@DM1122 DM1122 deleted the feature/snr branch August 26, 2022 14:39
@jenniferzzhang jenniferzzhang restored the feature/snr branch October 1, 2022 13:39
@DM1122 DM1122 deleted the feature/snr branch November 8, 2022 18:59
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.

SNR vs wavelength trade
2 participants