<filename>Data/Paltas/config_visualization.py
# Includes line-of-sight halos, subhalos, a PEMD deflector with external shear, 
# and COSMOS sources. Includes a simple observational effect model that roughly 
# matches HST effects Wide Field Camera 3 (WFC3) UVIS channel with the F814W 
# filter.

import numpy as np
from scipy.stats import norm, truncnorm, uniform
from paltas.Substructure.los_dg19 import LOSDG19
from paltas.Substructure.subhalos_dg19 import SubhalosDG19
from paltas.MainDeflector.simple_deflectors import PEMDShear
from paltas.Sources.sersic import SingleSersicSource
from paltas.Sampling import distributions

# Define the numerics kwargs.
kwargs_numerics = {'supersampling_factor':1}

# This is always the number of pixels for the CCD. If drizzle is used, the
# final image will be larger.
numpix = 128

# Define some general image kwargs for the dataset
mask_radius = 0.5
mag_cut = 2.0

# Define arguments that will be used multiple times
output_ab_zeropoint = 25.127

config_dict = {
	'subhalo':{
		'class': SubhalosDG19,
		'parameters':{
			'sigma_sub':norm(loc=2e-3,scale=1.1e-3).rvs,
			'shmf_plaw_index':uniform(loc=-1.92,scale=0.1).rvs,
			'm_pivot': 1e10,'m_min': 1e7,'m_max': 1e10,
			'c_0':uniform(loc=16,scale=2).rvs,
			'conc_zeta':uniform(loc=-0.3,scale=0.1).rvs,
			'conc_beta':uniform(loc=0.55,scale=0.3).rvs,
			'conc_m_ref': 1e8,
			'dex_scatter': uniform(loc=0.1,scale=0.06).rvs,
			'k1':0.0, 'k2':0.0
		}
	},
	'los':{
		'class': LOSDG19,
		'parameters':{
			'delta_los':norm(loc=1,scale=0.6).rvs,
			'm_min':1e7,'m_max':1e10,'z_min':0.01,
			'dz':0.01,'cone_angle':8.0,'r_min':0.5,'r_max':10.0,
			'c_0':uniform(loc=16,scale=2).rvs,
			'conc_zeta':uniform(loc=-0.3,scale=0.1).rvs,
			'conc_beta':uniform(loc=0.55,scale=0.3).rvs,
			'conc_m_ref': 1e8,
			'dex_scatter': uniform(loc=0.1,scale=0.06).rvs,
			'alpha_dz_factor':5.0
		}
	},
	'main_deflector':{
		'class': PEMDShear,
		'parameters':{
			'M200': 1e13,
			'z_lens': 0.5,
			'gamma': truncnorm(-20,np.inf,loc=2.0,scale=0.1).rvs,
			'theta_E': truncnorm(-1.1/0.15,np.inf,loc=1.1,scale=0.15).rvs,
			'e1': norm(loc=0.0,scale=0.1).rvs,
			'e2': norm(loc=0.0,scale=0.1).rvs,
			'center_x': norm(loc=0.0,scale=0.16).rvs,
			'center_y': norm(loc=0.0,scale=0.16).rvs,
			'gamma1': norm(loc=0.0,scale=0.05).rvs,
			'gamma2': norm(loc=0.0,scale=0.05).rvs,
			'ra_0':0.0, 'dec_0':0.0
		}
	},
	'source':{
		'class': SingleSersicSource,
		'parameters':{
			'z_source':truncnorm(-5,np.inf,loc=2.,scale=0.4).rvs,
			'magnitude':uniform(loc=20,scale=5).rvs,
			'output_ab_zeropoint':output_ab_zeropoint,
			'R_sersic':truncnorm(-2,2,loc=0.35,scale=0.05).rvs,
			'n_sersic':truncnorm(-6.,np.inf,loc=3.,scale=0.5).rvs,
			'e1':norm(loc=0.0,scale=0.1).rvs,
			'e2':norm(loc=0.0,scale=0.1).rvs,
			'center_x':norm(loc=0.0,scale=0.16).rvs,
			'center_y':norm(loc=0.0,scale=0.16).rvs}
	},
	'cosmology':{
		'parameters':{
			'cosmology_name': 'planck18'
		}
	},
	'psf':{
		'parameters':{
			'psf_type':'GAUSSIAN',
			'fwhm': 0.03
		}
	},
	'detector':{
		'parameters':{
			'pixel_scale':0.040,'ccd_gain':1.58,'read_noise':3.0,
			'magnitude_zero_point':output_ab_zeropoint,
			'exposure_time':1380,'sky_brightness':21.83,
			'num_exposures':4,'background_noise':None
		}
	},
	'cross_object':{
		'parameters':{
			'subhalo:c_0,los:c_0':distributions.Duplicate(
				dist=uniform(loc=16,scale=2).rvs),
			'subhalo:conc_zeta,los:conc_zeta':distributions.Duplicate(
				dist=uniform(loc=-0.3,scale=0.1).rvs),
			'subhalo:conc_beta,los:conc_beta':distributions.Duplicate(
				dist=uniform(loc=0.55,scale=0.3).rvs),
			'subhalo:dex_scatter,los:dex_scatter':distributions.Duplicate(
				dist=uniform(loc=0.1,scale=0.06).rvs)
		}
	}
}

<filename>Data/Paltas/config_visualization.py
# Includes line-of-sight halos, subhalos, a PEMD deflector with external shear, 
# and COSMOS sources. Includes a simple observational effect model that roughly 
# matches HST effects Wide Field Camera 3 (WFC3) UVIS channel with the F814W 
# filter.

import numpy as np
from scipy.stats import norm, truncnorm, uniform
from paltas.Substructure.los_dg19 import LOSDG19
from paltas.Substructure.subhalos_dg19 import SubhalosDG19
from paltas.MainDeflector.simple_deflectors import PEMDShear
from paltas.Sources.sersic import SingleSersicSource
from paltas.Sampling import distributions

# Define the numerics kwargs.
kwargs_numerics = {'supersampling_factor':1}

# This is always the number of pixels for the CCD. If drizzle is used, the
# final image will be larger.
numpix = 128

# Define some general image kwargs for the dataset
mask_radius = 0.5
mag_cut = 2.0

# Define arguments that will be used multiple times
output_ab_zeropoint = 25.127

config_dict = {
	'subhalo':{
		'class': SubhalosDG19,
		'parameters':{
			'sigma_sub':norm(loc=2e-3,scale=1.1e-3).rvs,
			'shmf_plaw_index':uniform(loc=-1.92,scale=0.1).rvs,
			'm_pivot': 1e10,'m_min': 1e7,'m_max': 1e10,
			'c_0':uniform(loc=16,scale=2).rvs,
			'conc_zeta':uniform(loc=-0.3,scale=0.1).rvs,
			'conc_beta':uniform(loc=0.55,scale=0.3).rvs,
			'conc_m_ref': 1e8,
			'dex_scatter': uniform(loc=0.1,scale=0.06).rvs,
			'k1':0.0, 'k2':0.0
		}
	},
	'los':{
		'class': LOSDG19,
		'parameters':{
			'delta_los':norm(loc=1,scale=0.6).rvs,
			'm_min':1e7,'m_max':1e10,'z_min':0.01,
			'dz':0.01,'cone_angle':8.0,'r_min':0.5,'r_max':10.0,
			'c_0':uniform(loc=16,scale=2).rvs,
			'conc_zeta':uniform(loc=-0.3,scale=0.1).rvs,
			'conc_beta':uniform(loc=0.55,scale=0.3).rvs,
			'conc_m_ref': 1e8,
			'dex_scatter': uniform(loc=0.1,scale=0.06).rvs,
			'alpha_dz_factor':5.0
		}
	},
	'main_deflector':{
		'class': PEMDShear,
		'parameters':{
			'M200': 1e13,
			'z_lens': 0.5,
			'gamma': truncnorm(-20,np.inf,loc=2.0,scale=0.1).rvs,
			'theta_E': truncnorm(-1.1/0.15,np.inf,loc=1.1,scale=0.15).rvs,
			'e1': norm(loc=0.0,scale=0.1).rvs,
			'e2': norm(loc=0.0,scale=0.1).rvs,
			'center_x': norm(loc=0.0,scale=0.16).rvs,
			'center_y': norm(loc=0.0,scale=0.16).rvs,
			'gamma1': norm(loc=0.0,scale=0.05).rvs,
			'gamma2': norm(loc=0.0,scale=0.05).rvs,
			'ra_0':0.0, 'dec_0':0.0
		}
	},
	'source':{
		'class': SingleSersicSource,
		'parameters':{
			'z_source':truncnorm(-5,np.inf,loc=2.,scale=0.4).rvs,
			'magnitude':uniform(loc=20,scale=5).rvs,
			'output_ab_zeropoint':output_ab_zeropoint,
			'R_sersic':truncnorm(-2,2,loc=0.35,scale=0.05).rvs,
			'n_sersic':truncnorm(-6.,np.inf,loc=3.,scale=0.5).rvs,
			'e1':norm(loc=0.0,scale=0.1).rvs,
			'e2':norm(loc=0.0,scale=0.1).rvs,
			'center_x':norm(loc=0.0,scale=0.16).rvs,
			'center_y':norm(loc=0.0,scale=0.16).rvs}
	},
	'cosmology':{
		'parameters':{
			'cosmology_name': 'planck18'
		}
	},
	'psf':{
		'parameters':{
			'psf_type':'GAUSSIAN',
			'fwhm': 0.03
		}
	},
	'detector':{
		'parameters':{
			'pixel_scale':0.040,'ccd_gain':1.58,'read_noise':3.0,
			'magnitude_zero_point':output_ab_zeropoint,
			'exposure_time':1380,'sky_brightness':21.83,
			'num_exposures':4,'background_noise':None
		}
	},
	'cross_object':{
		'parameters':{
			'subhalo:c_0,los:c_0':distributions.Duplicate(
				dist=uniform(loc=16,scale=2).rvs),
			'subhalo:conc_zeta,los:conc_zeta':distributions.Duplicate(
				dist=uniform(loc=-0.3,scale=0.1).rvs),
			'subhalo:conc_beta,los:conc_beta':distributions.Duplicate(
				dist=uniform(loc=0.55,scale=0.3).rvs),
			'subhalo:dex_scatter,los:dex_scatter':distributions.Duplicate(
				dist=uniform(loc=0.1,scale=0.06).rvs)
		}
	}
}

# Includes line-of-sight halos, subhalos, a PEMD deflector with external shear, # and COSMOS sources. Includes a simple observational effect model that roughly # matches HST effects Wide Field Camera 3 (WFC3) UVIS channel with the F814W # filter. # Define the numerics kwargs. # This is always the number of pixels for the CCD. If drizzle is used, the # final image will be larger. # Define some general image kwargs for the dataset # Define arguments that will be used multiple times