spacetelescope / astronify

Astronomical data sonification.
https://astronify.readthedocs.io
73 stars 15 forks source link

Updates to simulator. #29

Closed scfleming closed 4 years ago

scfleming commented 4 years ago
  1. Initial support for flares added to simulator.
  2. Updated simulator notebook to include flare examples.
  3. Simulator now adds flare, sinusoidal, and transit input parameters as FITS keywords to the primary header if saving to FITS.
  4. Simulator now automatically creates output directory when attempting to save a FITS file if it does not exist.

Known issue:

  1. The flare tail never approaches back down to zero level flux, even if the full half-width is contained within the index, but it gets close. Since there is typically noise added I'm not sure how important it is to fix. Perhaps could add a bit that does some linear interpolation from the end of the injected flare to make it match back down to zero flux level smoothly?
ceb8 commented 4 years ago

@scfleming I used your t_12 check to just make the flare go to the end of the light curve. I also switched from using math.exp to np.exp because the latter takes numpy arrays so we don't need the list comprehension. I also updated the notebook to fit with the namespace changes I made.

If you are OK with all these changes feel free to merge this PR, I think it's ready.

scfleming commented 4 years ago

Wonderful! I approve!