-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathP-pop_Photometry.py
executable file
·95 lines (79 loc) · 3.5 KB
/
P-pop_Photometry.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
"""
# =============================================================================
# P-POP PHOTOMETRY
# A photometry tool for P-POP
#
# Authors: Jens Kammerer, Sascha Quanz, Emile Fontanet
# Version: 5.0.0
# Last edited: 26.03.2021
# =============================================================================
#
# P-pop is introduced in Kammerer & Quanz 2018
# (https://ui.adsabs.harvard.edu/abs/2018A%26A...609A...4K/abstract). Please
# cite this paper if you use P-pop for your research.
#
# P-pop makes use of forecaster from Chen & Kipping 2017
# (https://ui.adsabs.harvard.edu/abs/2017ApJ...834...17C/abstract).
"""
# Don't print annoying warnings. Comment out if you want to see them.
import warnings
warnings.filterwarnings('ignore')
# =============================================================================
# IMPORTS
# =============================================================================
# Import your own filters and photometry tools here.
import PhotometryComputer
from Filters import SVO
from Star import Blackbody
from Planet import Thermal, Reflected
# =============================================================================
# SETUP
# =============================================================================
# Select the filters and photometry tools which you want to use here.
# Select the name of the planet population table for which the photometry
# should be computed here.
PathPlanetTable = '../P-pop/TestPlanetPopulation.txt' # str
# Select the filters for which the photometry should be computed here. You can
# simply use the filter names from the Spanish Virtual Observatory
# (http://svo2.cab.inta-csic.es/theory/fps/).
# list of str
SVOids = ['JWST/MIRI.F560W',\
'JWST/MIRI.F1000W',\
'JWST/MIRI.F1500W'] # used for LIFE
#SVOids = ['Paranal/SPHERE.ZIMPOL_V',\
# 'Paranal/SPHERE.IRDIS_B_J',\
# 'Paranal/SPHERE.IRDIS_B_H'] # used for HabEx/LUVOIR
# Select the photometry tools to compute the fluxes from the stars and the
# planets as well as their unit and the wavelength range in which the mission
# is operating here.
Sstar = [Blackbody] # list of Star
Splanet = [Thermal, Reflected] # list of Planet
Unit = 'uJy' # micro-Jansky
#Unit = 'ph' # photons per second per square meter
Mission = 'MIR' # use AgeomMIR for reflected light (used for LIFE)
#Mission = 'VIS' # use AgeomVIS for reflected light (used for HabEx/LUVOIR)
# Select whether you want to display summary plots after loading the filters
# and models selected above.
SummaryPlots = True
#SummaryPlots = False
#FigDir = None # if you don't want to save the summary plots
FigDir = 'Figures/' # should end with a slash ("/")
#block = True
block = False
# =============================================================================
# P-POP PHOTOMETRY
# =============================================================================
# Don't modify the following code.
Filters = []
for i in range(len(SVOids)):
Filters += [SVO.getFilter(SVOids[i], SummaryPlots, FigDir, block)]
PhotComp = PhotometryComputer.PhotometryComputer(PathPlanetTable,
Filters,
Sstar,
Splanet,
Unit,
Mission,
SummaryPlots,
FigDir,
block)
PhotComp.Run()