[go: up one dir, main page]

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

Design of the Instrument class #10

Open
zonca opened this issue Jan 29, 2019 · 2 comments
Open

Design of the Instrument class #10

zonca opened this issue Jan 29, 2019 · 2 comments
Milestone

Comments

@zonca
Copy link
Member
zonca commented Jan 29, 2019

I believe it is a good idea, as it is now, to have the Model subclasses take care of the bandpass integration, see #9

However, I think it is convenient to have a Instrument class with a similar interface to PySM 2, it is a good way of grouping the instrument properties together that are otherwise just independent arrays like fwhms and bandpasses.

We can still provide the same observe method that calls get_integrated_emission of Sky and passes bandpasses.

Smoothing instead can just be implemented inside Instrument, I don't think there is any advantage in implementing it inside Model.

Finally Instrument will be able to generate white noise maps and also optionally write the outputs to disk. So it should process one channel at a time.

@zonca zonca changed the title Design of Instrument class Design of the Instrument class Jan 29, 2019
@zonca
Copy link
Member Author
zonca commented May 21, 2019

class Instrument:

  • channel label
  • bandpass
  • beam width
  • white noise level
  • hitmap (optional)

Possibly each channel is a dictionary with predefined keys, otherwise implement a Class

Instrument.generate_noise_map, gets a seed (optional) generates 1 noise map
we also need to have a simple hitmap weighted white noise map.

Instrument.generate_noise_realizations(number, sky=None) loop through channels and for let's say 100 realizations create noise maps and call the write_output with a suitable filename template.

Instrument.observe(sky : pysm.Sky), generates 1 sky bandpass integrated, smoothed and coordinate transform + noise

People can subclass for example to reimplement generate_noise_map with their own algorithm

@zonca
Copy link
Member Author
zonca commented May 21, 2019

need to specify a bandpass_units, for example if we have tophat assuming K_CMB we need to compute the conversion factor from K_RJ to K_CMB and apply it to the dimensionless weights

@zonca zonca added this to the 0.1.0 milestone May 21, 2019
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

No branches or pull requests

1 participant