Skip to content

01 Example Scripts

A J Eldorado Riggs edited this page Nov 22, 2021 · 4 revisions

Simple WFSC Examples

Please look at files in the folder falco-python/examples/ starting with EXAMPLE_main_* to see several working example scripts of what FALCO can do. All the scripts in this folder use a toy full model that includes only the key planes for the coronagraph. These are useful for coronagraph design or basic testing of an optical system. To see an example that includes all the optics with aberrations, read the next section.

Simple Function Demonstrations

To learn how some key functions work and see their outputs, please look at and run files in the folder falco-python/examples/ starting withdemo_*.

Roman Coronagraph Instrument Examples

The paper describing all the Roman CGI coronagraph mask configurations is available for free here.

The script to run high-order WFSC (HOWFSC) with the Roman Coronagraph Instrument (CGI) model is provided in the folder falco-python/roman/. After installing FALCO, follow these steps to run the Roman CGI example script:

  1. Download roman_phasec_v*.zip and its PDF manual from the CGISim package. Follow the brief Python installation instructions in the roman_phasec manual.
  2. Go into the subdirectory falco-python/roman/. You should be able to run EXAMPLE_main_Roman_CGI_any.py. To switch among the different mask configurations, uncomment the config file (actually another script) named for the mode you want. For example, to run the HLC in Band 1:
  • from EXAMPLE_config_Roman_CGI_HLC_NFOV_Band1 import mp
  • # from EXAMPLE_config_Roman_CGI_SPC_Bowtie_Band2 import mp
  • # from EXAMPLE_config_Roman_CGI_SPC_Bowtie_Band3 import mp
  • # from EXAMPLE_config_Roman_CGI_SPC_WFOV_Band4 import mp