Git Product home page Git Product logo

di-flux-ratio-plot's Introduction

CGI-flux-ratio-plot

This contains the python code to plot the flux ratio vs separation plot. It also contains the text files with the contrast curves and planet flux ratio values. Each datafile has a full description on its comment section; a brief explanation (auto_caption.txt) is auto-generated by the script from these headers, including only those data you choose plot. See also Roman Coronagraph Exposure Time Calculator for complementary information about integration times given a specific flux ratio.

python requirements

  • python 3
  • matplotlib
  • astropy (tables, ascii, units)
  • numpy
  • yaml

Note: this code is only tested with miniconda + astroconda and python up to 3.9.11.

quickstart

If you would like to contribute to this repo, please fork it. Otherwise, simply download or clone and you're ready to go.

Copy example_files/default.yml to the same directory as plot_flux_ratio.py. Run python plot_flux_ratio.py Your figure and an auto-generated description will be created in the output folder.

Read the docs! See the documentation folder for an example plot and a complete description of the data and calculations.

Customizing your plot

YAML file

To customize what is plotted, place a YAML configuration file in the same directory as the script plot_flux_ratio.py. See the example_files directory for an example. The name of the config file will be appended to the output plot & caption filenames, so it's recommended to give your config file a descriptive name.

Plot options

Available modes for the Coronagraph Instrument aboard the Nancy Grace Roman Space Telescope:

  • imaging requirement (PLRA L1 TTTR5)

  • imaging & spectroscopy for two perfomance scenarios: optimistic and conservative

    • Optimistic: predictions assume instrumental and spacecraft performance close to optimal

    • Conservative: predictions with additional instrumental and spacecraft performance model uncertainty factors

  • Obsolete requirements (Phase B) are available for reference only

Available instruments:

  • Gemini GPI IFS
  • VLT SPHERE: IFS & IRDIS
  • Magellan VisAO
  • VLTI GRAVITY
  • generic ground-based (supersedes the above)
  • HST ACS
  • HST NICMOS
  • HST STIS
  • JWST NIRCam

Available planets:

  • known self-luminious directly imaged planets: measured H-band contrasts & predictions for CGI bandpasses
  • known RV planets: predicted reflected light brightness using either a simple 0.5 albedo model or predictions from the Imaging Mission Database
  • Earth & Jupiter at 10pc
  • Tau Ceti e & f

Other available plotting options:

  • color coding by bandpass: none, minimal color, simple color, full color

Data file format

Datafiles should be formatted in the following way to allow for auto import by astropy.io.ascii & auto generation of caption.txt:

#col_name1  col_name2
#Short caption: Write a short explanation, suitable for a figure caption. This line is automatically fed into "auto_caption.txt" when contrast_plot.py is run. This line must begin with the phrase "short caption:" & be all on one line (ie: no "return" characters).
#Full explanation: Optional. Any other info that you don't want to appear in auto_caption.
#References
#URLs or paper references or other source information
data11  data12
data21	data22
...

Submitting new data or features

Thanks for your help! Before you submit a pull request please:

  • Ensure that the script still runs with doc.yml and default.yml
  • If your changes affect flux_ratio_doc.png, place your new version in the documentation folder.
  • Update description.md in the `documentation' folder, if necessary.
  • Update the short caption header in any changed data files.

License and acknowledgements

Government sponsorship acknowledged. This work was carried out in part at the Jet Propulsion Laboratory, California Institute of Technology, under a contract with the National Aeronautics and Space Administration.

Copyright 2021 California Institute of Technology.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License in the LICENSE file or at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

di-flux-ratio-plot's People

Contributors

nasavbailey avatar hsergi avatar npourre avatar rzellem avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.