Coverage for src/galsbi/configs/config_Moser+24_intrinsic.py: 100%
43 statements
« prev ^ index » next coverage.py v7.6.9, created at 2024-12-13 03:24 +0000
« prev ^ index » next coverage.py v7.6.9, created at 2024-12-13 03:24 +0000
1# Copyright (C) 2024 ETH Zurich
2# Institute for Particle Physics and Astrophysics
3# Author: Silvan Fischbacher
4# created: Thu Aug 08 2024
6import os
8import numpy as np
9import ufig.config.common
10from cosmo_torrent import data_path
11from ivy.loop import Loop
12from ufig.workflow_util import FiltersStopCriteria
14import galsbi.ucat.config.common
17# Import all common settings from ucat and ufig as default
18def _update_globals(module, globals_):
19 globals_.update(
20 {k: v for k, v in module.__dict__.items() if not k.startswith("__")}
21 )
24_update_globals(galsbi.ucat.config.common, globals())
25_update_globals(ufig.config.common, globals())
27# Default size of the image
28sampling_mode = "healpix"
29healpix_map = np.zeros(12 * 64**2)
30healpix_map[0] = 1
32# Define the filters
33filters = ["g", "r", "i", "z", "y"]
34filters_full_names = {
35 "B": "SuprimeCam_B",
36 "g": "HSC_g",
37 "r": "HSC_r2",
38 "i": "HSC_i2",
39 "z": "HSC_z",
40 "y": "HSC_y",
41}
42reference_band = "i"
44# Define the plugins that should be used
45plugins = [
46 "ufig.plugins.multi_band_setup",
47 "galsbi.ucat.plugins.sample_galaxies",
48 Loop(
49 [
50 "ufig.plugins.single_band_setup_intrinsic_only",
51 "ufig.plugins.write_catalog",
52 ],
53 stop=FiltersStopCriteria(),
54 ),
55 "ivy.plugin.show_stats",
56]
58# Luminosity function
59lum_fct_z_res = 0.001
60lum_fct_m_max = -4
61lum_fct_z_max = 6
63# Sampling methods ucat
64nside_sampling = 4096
66# Magnitude limits
67stars_mag_max = 26
68gals_mag_max = 28
69stars_mag_min = 12
70gals_mag_min = 14
72# Filter throughputs
73filters_file_name = os.path.join(
74 data_path("HSC_tables"), "HSC_filters_collection_yfix.h5"
75)
77# Template spectra & integration tables
78n_templates = 5
79templates_file_name = os.path.join(
80 data_path("template_BlantonRoweis07"), "template_spectra_BlantonRoweis07.h5"
81)
83# Extinction
84extinction_map_file_name = os.path.join(
85 data_path("lambda_sfd_ebv"), "lambda_sfd_ebv.fits"
86)
88# magnitude table
89magnitude_calculation = "table"
90templates_int_tables_file_name = os.path.join(
91 data_path("HSC_tables"), "HSC_template_integrals_yfix.h5"
92)
94# Catalog precision
95catalog_precision = np.float32
97# Seed
98seed = 1996
101# Parameters that are specific to the Moser+24 model
102# Mainly the different parametrizations of the galaxy population model.
103# DO NOT CHANGE THESE VALUES IF YOU WANT TO USE THE GALAXY POPULATION MODEL OF MOSER+24
104# CHANGING THESE VALUES WILL LEAD TO A DIFFERENT MEANING OF SOME OF THE PARAMETERS
105lum_fct_parametrization = "logpower"
106ellipticity_sampling_method = "beta_mode_red_blue"
107sersic_sampling_method = "blue_red_betaprime"
108logr50_sampling_method = "red_blue"
109template_coeff_sampler = "dirichlet_alpha_mode"
110template_coeff_weight_blue = np.array([1.0, 1.0, 1.0, 1.0, 1.0])
111template_coeff_weight_red = np.array([1.0, 1.0, 1.0, 1.0, 1.0])
112template_coeff_z1_blue = 3
113template_coeff_z1_red = 3