import numpy as np import pickle, os, sys from bsfh import sps_basis, priors, sedmodel, elines from sedpy import attenuation import ggcdata #The speccal directory sdir = os.path.join(os.environ['PROJECTS'], 'speccal') sps = sps_basis.StellarPopBasis() nw = len(sps.ssp.wavelengths) if nw > 7000: lib = 'ckc' elif nw > 2000: lib = 'miles' sigma_library = 1.08 else: lib = 'basel' model_params = [] ###### Distance ########## model_params.append({ 'name': 'lumdist', 'N': 1, 'isfree': False, 'init': 0.01, 'units': 'Mpc', 'prior_function': None, 'prior_args': None })
import sys import numpy as np import matplotlib.pyplot as pl from matplotlib import gridspec import triangle import bsfh.read_results as diagnostics from bsfh.read_results import model_comp as mcomp from bsfh import sps_basis sps = sps_basis.StellarPopBasis(smooth_velocity=False) pardict = {} pardict['mass']=r'$m_*$ (M$_\odot$)' pardict['tage']=r'$t$ (Gyr)' pardict['zmet']=r'$\log Z/Z_\odot$' pardict['dust2']=r'$A_V$' pardict['sigma_smooth']=r'$\sigma \, (\AA)$' pardict['zred']=r'$z$' pardict['gp_jitter']=r'$s$' pardict['gp_amplitude']=r'$a$' pardict['gp_length']=r'$l \, (\AA)$' pardict['poly_coeffs1']=r'$c_1$' pardict['poly_coeffs2']=r'$c_2$' pardict['spec_norm']=r'$c_0$' pardict['emission_disp']= r'$\sigma_e \, (\AA)$' pardict['phot_jitter']=r'$s_{{phot}}$' def comp_samples(thetas, model, inlog=True, photflag=0): specvecs =[]