-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheccentric_configuration.py
41 lines (37 loc) · 1.3 KB
/
eccentric_configuration.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
from sklearn.gaussian_process.kernels import RBF, WhiteKernel
from user_filepaths import LOCAL_REPOSITORY_DIRECTORY
TRAINING_METRIC_FILEPATH = LOCAL_REPOSITORY_DIRECTORY / "training_metrics.nc"
TEST_METRIC_FILEPATH = LOCAL_REPOSITORY_DIRECTORY / "test_metrics.nc"
RBF_KERNEL_PARAMETERS = dict(
length_scale=[1, 15, 0.05, 0.05],
length_scale_bounds=[[1e-10, 1e10], [1e-10, 1e10], [1e-10, 1e10], [1e-10, 1e10]],
)
WHITE_KERNEL_PARAMETERS = dict(noise_level=0.01, noise_level_bounds=[1e-30, 1e30])
GAUSSIAN_PROCESS_REGRESSION_PARAMETERS = dict(alpha=2e-2, normalize_y=True)
GPR_KWARGS = {
**dict(
kernel=RBF(**RBF_KERNEL_PARAMETERS) + WhiteKernel(**WHITE_KERNEL_PARAMETERS)
),
**GAUSSIAN_PROCESS_REGRESSION_PARAMETERS,
}
USE_POLAR = True
MAXIMUM_ECCENTRICITY = 0.225
COORDINATE_NAMES = [
"rotation_period",
"obliquity",
"eccentricity",
"longitude_at_periapse",
]
COORDINATE_NAMES_FOR_GRID = (
["rotation_period", "obliquity"] + ["ecc_cos_lon", "ecc_sin_lon"]
if USE_POLAR
else ["eccentricity", "longitude_at_periapse"]
)
COORDINATE_PRINT_NAMES = [
r"Rotation Period (days)",
r"Obliquity $\left(^\circ\right)$",
] + (
[r"$e \cos\phi_\mathrm{peri}$", r"$e \sin\phi_\mathrm{peri}$"]
if USE_POLAR
else ["$e$", r"$\phi_\mathrm{peri}$ $\left(^\circ\right)$"]
)