Model fitting 4: Only Synchrotron¶
import warnings
warnings.filterwarnings('ignore')
import matplotlib.pylab as plt
import jetset
from jetset.test_data_helper import test_SEDs
from jetset.data_loader import ObsData,Data
from jetset.plot_sedfit import PlotSED
from jetset.test_data_helper import test_SEDs
print(jetset.__version__)
1.2.2
test_SEDs
['/Users/orion/anaconda3/envs/jetset/lib/python3.8/site-packages/jetset/test_data/SEDs_data/SED_3C345.ecsv',
'/Users/orion/anaconda3/envs/jetset/lib/python3.8/site-packages/jetset/test_data/SEDs_data/SED_MW_Mrk421_EBL_DEABS.ecsv',
'/Users/orion/anaconda3/envs/jetset/lib/python3.8/site-packages/jetset/test_data/SEDs_data/SED_MW_Mrk501_EBL_ABS.ecsv',
'/Users/orion/anaconda3/envs/jetset/lib/python3.8/site-packages/jetset/test_data/SEDs_data/SED_MW_Mrk501_EBL_DEABS.ecsv']
Loading data¶
see the data_format user guide for further information about loading data
print(test_SEDs[1])
data=Data.from_file(test_SEDs[1])
/Users/orion/anaconda3/envs/jetset/lib/python3.8/site-packages/jetset/test_data/SEDs_data/SED_MW_Mrk421_EBL_DEABS.ecsv
%matplotlib inline
sed_data=ObsData(data_table=data)
sed_data.group_data(bin_width=0.2)
sed_data.add_systematics(0.1,[10.**6,10.**29])
p=sed_data.plot_sed()
================================================================================ * binning data * ---> N bins= 89 ---> bin_widht= 0.2 ================================================================================
sed_data.save('Mrk_401.pkl')
Phenomenological model constraining¶
see the Phenomenological model constraining: application user guide for further information about loading data
Spectral indices¶
from jetset.sed_shaper import SEDShape
my_shape=SEDShape(sed_data)
my_shape.eval_indices(silent=True)
p=my_shape.plot_indices()
p.setlim(y_min=1E-15,y_max=1E-6)
================================================================================ * evaluating spectral indices for data * ================================================================================
Sed shaper¶
mm,best_fit=my_shape.sync_fit(check_host_gal_template=False,
Ep_start=None,
minimizer='lsb',
silent=True,
fit_range=[10., 21.])
================================================================================ * Log-Polynomial fitting of the synchrotron component * ---> first blind fit run, fit range: [10.0, 21.0] ---> class: HSPTable length=4
model name | name | val | bestfit val | err + | err - | start val | fit range min | fit range max | frozen |
---|---|---|---|---|---|---|---|---|---|
LogCubic | b | -1.545300e-01 | -1.545300e-01 | 9.534795e-03 | -- | -1.000000e+00 | -1.000000e+01 | 0.000000e+00 | False |
LogCubic | c | -1.023245e-02 | -1.023245e-02 | 1.433073e-03 | -- | -1.000000e+00 | -1.000000e+01 | 1.000000e+01 | False |
LogCubic | Ep | 1.672267e+01 | 1.672267e+01 | 4.139942e-02 | -- | 1.667039e+01 | 0.000000e+00 | 3.000000e+01 | False |
LogCubic | Sp | -9.491659e+00 | -9.491659e+00 | 2.515285e-02 | -- | -1.000000e+01 | -3.000000e+01 | 0.000000e+00 | False |
---> sync nu_p=+1.672267e+01 (err=+4.139942e-02) nuFnu_p=-9.491659e+00 (err=+2.515285e-02) curv.=-1.545300e-01 (err=+9.534795e-03)
================================================================================
my_shape.IC_fit(fit_range=[23., 29.],minimizer='minuit',silent=True)
p=my_shape.plot_shape_fit()
p.setlim(y_min=1E-15)
================================================================================ * Log-Polynomial fitting of the IC component * ---> fit range: [23.0, 29.0] ---> LogCubic fitTable length=4
model name | name | val | bestfit val | err + | err - | start val | fit range min | fit range max | frozen |
---|---|---|---|---|---|---|---|---|---|
LogCubic | b | -2.098186e-01 | -2.098186e-01 | 3.133032e-02 | -- | -1.000000e+00 | -1.000000e+01 | 0.000000e+00 | False |
LogCubic | c | -4.661868e-02 | -4.661868e-02 | 2.178352e-02 | -- | -1.000000e+00 | -1.000000e+01 | 1.000000e+01 | False |
LogCubic | Ep | 2.524926e+01 | 2.524926e+01 | 1.147759e-01 | -- | 2.529412e+01 | 0.000000e+00 | 3.000000e+01 | False |
LogCubic | Sp | -1.011085e+01 | -1.011085e+01 | 3.498963e-02 | -- | -1.000000e+01 | -3.000000e+01 | 0.000000e+00 | False |
---> IC nu_p=+2.524926e+01 (err=+1.147759e-01) nuFnu_p=-1.011085e+01 (err=+3.498963e-02) curv.=-2.098186e-01 (err=+3.133032e-02)
================================================================================
Model constraining¶
from jetset.obs_constrain import ObsConstrain
from jetset.model_manager import FitModel
from jetset.minimizer import fit_SED
sed_obspar=ObsConstrain(beaming=25,
B_range=[0.001,0.1],
distr_e='lppl',
t_var_sec=3*86400,
nu_cut_IR=1E12,
SEDShape=my_shape)
prefit_jet=sed_obspar.constrain_SSC_model(electron_distribution_log_values=False,silent=True)
prefit_jet.save_model('prefit_jet.pkl')
================================================================================ * constrains parameters from observable *Table length=12
model name | name | par type | units | val | phys. bound. min | phys. bound. max | log | frozen |
---|---|---|---|---|---|---|---|---|
jet_leptonic | R | region_size | cm | 3.112712e+16 | 1.000000e+03 | 1.000000e+30 | False | False |
jet_leptonic | R_H | region_position | cm | 1.000000e+17 | 0.000000e+00 | -- | False | True |
jet_leptonic | B | magnetic_field | gauss | 5.050000e-02 | 0.000000e+00 | -- | False | False |
jet_leptonic | NH_cold_to_rel_e | cold_p_to_rel_e_ratio | 1.000000e-01 | 0.000000e+00 | -- | False | True | |
jet_leptonic | beam_obj | beaming | lorentz-factor* | 2.500000e+01 | 1.000000e-04 | -- | False | False |
jet_leptonic | z_cosm | redshift | 3.080000e-02 | 0.000000e+00 | -- | False | False | |
jet_leptonic | gmin | low-energy-cut-off | lorentz-factor* | 4.697542e+02 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | gmax | high-energy-cut-off | lorentz-factor* | 1.373160e+06 | 1.000000e+00 | 1.000000e+15 | False | False |
jet_leptonic | N | emitters_density | 1 / cm3 | 9.060842e-01 | 0.000000e+00 | -- | False | False |
jet_leptonic | gamma0_log_parab | turn-over-energy | lorentz-factor* | 3.188500e+04 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | s | LE_spectral_slope | 2.181578e+00 | -1.000000e+01 | 1.000000e+01 | False | False | |
jet_leptonic | r | spectral_curvature | 7.726502e-01 | -1.500000e+01 | 1.500000e+01 | False | False |
================================================================================
pl=prefit_jet.plot_model(sed_data=sed_data)
pl.add_residual_plot(prefit_jet,sed_data)
pl.setlim(y_min=1E-15,x_min=1E7,x_max=1E29)
Model fitting only Synchorotron component¶
Note
With the new implementation of composite model (FitModel class) to set parameters you have to specify the model component, this is different from versions<1.1.2, and this holds also for the freeze method and for setting fit_range intervals, and for the methods relate to parameters setting in general. See the Composite Models and depending pars user guide for further information about the new implementation of FitModel, in particular for parameter setting
Model fitting with Minuit¶
from jetset.jet_model import Jet
jet_minuit=Jet.load_model('prefit_jet.pkl')
jet_minuit.set_gamma_grid_size(200)
model name | name | par type | units | val | phys. bound. min | phys. bound. max | log | frozen |
---|---|---|---|---|---|---|---|---|
jet_leptonic | gmin | low-energy-cut-off | lorentz-factor* | 4.697542e+02 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | gmax | high-energy-cut-off | lorentz-factor* | 1.373160e+06 | 1.000000e+00 | 1.000000e+15 | False | False |
jet_leptonic | N | emitters_density | 1 / cm3 | 9.060842e-01 | 0.000000e+00 | -- | False | False |
jet_leptonic | gamma0_log_parab | turn-over-energy | lorentz-factor* | 3.188500e+04 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | s | LE_spectral_slope | 2.181578e+00 | -1.000000e+01 | 1.000000e+01 | False | False | |
jet_leptonic | r | spectral_curvature | 7.726502e-01 | -1.500000e+01 | 1.500000e+01 | False | False | |
jet_leptonic | R | region_size | cm | 3.112712e+16 | 1.000000e+03 | 1.000000e+30 | False | False |
jet_leptonic | R_H | region_position | cm | 1.000000e+17 | 0.000000e+00 | -- | False | True |
jet_leptonic | B | magnetic_field | gauss | 5.050000e-02 | 0.000000e+00 | -- | False | False |
jet_leptonic | NH_cold_to_rel_e | cold_p_to_rel_e_ratio | 1.000000e-01 | 0.000000e+00 | -- | False | True | |
jet_leptonic | beam_obj | beaming | lorentz-factor* | 2.500000e+01 | 1.000000e-04 | -- | False | False |
jet_leptonic | z_cosm | redshift | 3.080000e-02 | 0.000000e+00 | -- | False | False |
we switch off the IC component
jet_minuit.spectral_components.SSC.state='off'
jet_minuit.show_model()
--------------------------------------------------------------------------------
model description:
--------------------------------------------------------------------------------
type: Jet
name: jet_leptonic
electrons distribution:
type: lppl
gamma energy grid size: 201
gmin grid : 4.697542e+02
gmax grid : 1.373160e+06
normalization: True
log-values: False
ratio of cold protons to relativistic electrons: 1.000000e-01
radiative fields:
seed photons grid size: 100
IC emission grid size: 100
source emissivity lower bound : 1.000000e-120
spectral components:
name:Sum, state: on
name:Sync, state: self-abs
name:SSC, state: off
external fields transformation method: blob
SED info:
nu grid size jetkernel: 1000
nu size: 500
nu mix (Hz): 1.000000e+06
nu max (Hz): 1.000000e+30
flux plot lower bound : 1.000000e-30
--------------------------------------------------------------------------------
model name | name | par type | units | val | phys. bound. min | phys. bound. max | log | frozen |
---|---|---|---|---|---|---|---|---|
jet_leptonic | gmin | low-energy-cut-off | lorentz-factor* | 4.697542e+02 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | gmax | high-energy-cut-off | lorentz-factor* | 1.373160e+06 | 1.000000e+00 | 1.000000e+15 | False | False |
jet_leptonic | N | emitters_density | 1 / cm3 | 9.060842e-01 | 0.000000e+00 | -- | False | False |
jet_leptonic | gamma0_log_parab | turn-over-energy | lorentz-factor* | 3.188500e+04 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | s | LE_spectral_slope | 2.181578e+00 | -1.000000e+01 | 1.000000e+01 | False | False | |
jet_leptonic | r | spectral_curvature | 7.726502e-01 | -1.500000e+01 | 1.500000e+01 | False | False | |
jet_leptonic | R | region_size | cm | 3.112712e+16 | 1.000000e+03 | 1.000000e+30 | False | False |
jet_leptonic | R_H | region_position | cm | 1.000000e+17 | 0.000000e+00 | -- | False | True |
jet_leptonic | B | magnetic_field | gauss | 5.050000e-02 | 0.000000e+00 | -- | False | False |
jet_leptonic | NH_cold_to_rel_e | cold_p_to_rel_e_ratio | 1.000000e-01 | 0.000000e+00 | -- | False | True | |
jet_leptonic | beam_obj | beaming | lorentz-factor* | 2.500000e+01 | 1.000000e-04 | -- | False | False |
jet_leptonic | z_cosm | redshift | 3.080000e-02 | 0.000000e+00 | -- | False | False |
--------------------------------------------------------------------------------
fit_model_minuit=FitModel( jet=jet_minuit, name='Only-Synch-best-fit-minuit')
fit_model_minuit.freeze('jet_leptonic','z_cosm')
fit_model_minuit.freeze('jet_leptonic','R_H')
fit_model_minuit.freeze('jet_leptonic','R')
fit_model_minuit.freeze('jet_leptonic','gmax')
fit_model_minuit.jet_leptonic.parameters.R.fit_range=[10**15.5, 10**17.5]
fit_model_minuit.jet_leptonic.parameters.beam_obj.fit_range=[5., 50.]
from jetset.minimizer import fit_SED,ModelMinimizer
model_minimizer_minuit=ModelMinimizer('minuit')
best_fit_minuit=model_minimizer_minuit.fit(fit_model_minuit,sed_data,10.0**15,10**20.0,fitname='SSC-best-fit-minuit',repeat=3)
filtering data in fit range = [1.000000e+15,1.000000e+20] data length 13 ================================================================================ * start fit process * ----- fit run: 0
0it [00:00, ?it/s]
- best chisq=1.36478e+00
fit run: 1
- old chisq=1.36478e+00
0it [00:00, ?it/s]
- best chisq=1.36477e+00
fit run: 2
- old chisq=1.36477e+00
0it [00:00, ?it/s]
- best chisq=1.36477e+00
-------------------------------------------------------------------------
Fit report
Model: SSC-best-fit-minuit
model name | name | par type | units | val | phys. bound. min | phys. bound. max | log | frozen |
---|---|---|---|---|---|---|---|---|
jet_leptonic | gmin | low-energy-cut-off | lorentz-factor* | 9.157430e+02 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | gmax | high-energy-cut-off | lorentz-factor* | 1.373160e+06 | 1.000000e+00 | 1.000000e+15 | False | True |
jet_leptonic | N | emitters_density | 1 / cm3 | 1.850602e+00 | 0.000000e+00 | -- | False | False |
jet_leptonic | gamma0_log_parab | turn-over-energy | lorentz-factor* | 4.329106e+04 | 1.000000e+00 | 1.000000e+09 | False | False |
jet_leptonic | s | LE_spectral_slope | 2.159322e+00 | -1.000000e+01 | 1.000000e+01 | False | False | |
jet_leptonic | r | spectral_curvature | 6.029154e-01 | -1.500000e+01 | 1.500000e+01 | False | False | |
jet_leptonic | R | region_size | cm | 3.112712e+16 | 1.000000e+03 | 1.000000e+30 | False | True |
jet_leptonic | R_H | region_position | cm | 1.000000e+17 | 0.000000e+00 | -- | False | True |
jet_leptonic | B | magnetic_field | gauss | 2.090652e-02 | 0.000000e+00 | -- | False | False |
jet_leptonic | NH_cold_to_rel_e | cold_p_to_rel_e_ratio | 1.000000e-01 | 0.000000e+00 | -- | False | True | |
jet_leptonic | beam_obj | beaming | lorentz-factor* | 2.326797e+01 | 1.000000e-04 | -- | False | False |
jet_leptonic | z_cosm | redshift | 3.080000e-02 | 0.000000e+00 | -- | False | True |
converged=True
calls=95
mesg=
FCN = 1.365 | Nfcn = 95 | |||
EDM = 2.08e-05 (Goal: 0.0002) | ||||
Valid Minimum | Valid Parameters | No Parameters at limit | ||
Below EDM threshold (goal x 10) | Below call limit | |||
Covariance | Hesse ok | APPROXIMATE | NOT pos. def. | FORCED |
Name | Value | Hesse Error | Minos Error- | Minos Error+ | Limit- | Limit+ | Fixed | |
---|---|---|---|---|---|---|---|---|
0 | par_0 | 0.92e3 | 0.27e3 | 1 | 1E+09 | |||
1 | par_1 | 1.9 | 0.5 | 0 | ||||
2 | par_2 | 43e3 | 8e3 | 1 | 1E+09 | |||
3 | par_3 | 2.16 | 0.06 | -10 | 10 | |||
4 | par_4 | 0.60 | 0.08 | -15 | 15 | |||
5 | par_5 | 0.0209 | 0.0023 | 0 | ||||
6 | par_6 | 23.3 | 1.6 | 5 | 50 |
par_0 | par_1 | par_2 | par_3 | par_4 | par_5 | par_6 | |
---|---|---|---|---|---|---|---|
par_0 | 7.19e+04 | -87.1 (-0.604) | 9.91e+04 (0.044) | 4.55 (0.297) | -4.59 (-0.228) | -0.0167 (-0.028) | -174 (-0.398) |
par_1 | -87.1 (-0.604) | 0.289 | 90.4 (0.020) | 0.00427 (0.139) | -0.00639 (-0.159) | -0.000193 (-0.160) | -0.105 (-0.120) |
par_2 | 9.91e+04 (0.044) | 90.4 (0.020) | 7.15e+07 | 224 (0.464) | 427 (0.674) | 0.75 (0.039) | 294 (0.021) |
par_3 | 4.55 (0.297) | 0.00427 (0.139) | 224 (0.464) | 0.00327 | -0.000393 (-0.092) | 7.76e-06 (0.060) | 0.00549 (0.059) |
par_4 | -4.59 (-0.228) | -0.00639 (-0.159) | 427 (0.674) | -0.000393 (-0.092) | 0.00562 | 6.13e-05 (0.364) | 0.0139 (0.114) |
par_5 | -0.0167 (-0.028) | -0.000193 (-0.160) | 0.75 (0.039) | 7.76e-06 (0.060) | 6.13e-05 (0.364) | 5.06e-06 | -0.00146 (-0.397) |
par_6 | -174 (-0.398) | -0.105 (-0.120) | 294 (0.021) | 0.00549 (0.059) | 0.0139 (0.114) | -0.00146 (-0.397) | 2.66 |
dof=6
chisq=1.364771, chisq/red=0.227462 null hypothesis sig=0.967966
best fit pars
model name | name | val | bestfit val | err + | err - | start val | fit range min | fit range max | frozen |
---|---|---|---|---|---|---|---|---|---|
jet_leptonic | gmin | 9.157430e+02 | 9.157430e+02 | 2.681484e+02 | -- | 4.697542e+02 | 1.000000e+00 | 1.000000e+09 | False |
jet_leptonic | gmax | 1.373160e+06 | -- | -- | -- | 1.373160e+06 | 1.000000e+00 | 1.000000e+15 | True |
jet_leptonic | N | 1.850602e+00 | 1.850602e+00 | 5.363195e-01 | -- | 9.060842e-01 | 0.000000e+00 | -- | False |
jet_leptonic | gamma0_log_parab | 4.329106e+04 | 4.329106e+04 | 8.457976e+03 | -- | 3.188500e+04 | 1.000000e+00 | 1.000000e+09 | False |
jet_leptonic | s | 2.159322e+00 | 2.159322e+00 | 5.717871e-02 | -- | 2.181578e+00 | -1.000000e+01 | 1.000000e+01 | False |
jet_leptonic | r | 6.029154e-01 | 6.029154e-01 | 7.496457e-02 | -- | 7.726502e-01 | -1.500000e+01 | 1.500000e+01 | False |
jet_leptonic | R | 3.112712e+16 | -- | -- | -- | 3.112712e+16 | 3.162278e+15 | 3.162278e+17 | True |
jet_leptonic | R_H | 1.000000e+17 | -- | -- | -- | 1.000000e+17 | 0.000000e+00 | -- | True |
jet_leptonic | B | 2.090652e-02 | 2.090652e-02 | 2.250326e-03 | -- | 5.050000e-02 | 0.000000e+00 | -- | False |
jet_leptonic | NH_cold_to_rel_e | 1.000000e-01 | -- | -- | -- | 1.000000e-01 | 0.000000e+00 | -- | True |
jet_leptonic | beam_obj | 2.326797e+01 | 2.326797e+01 | 1.628276e+00 | -- | 2.500000e+01 | 5.000000e+00 | 5.000000e+01 | False |
jet_leptonic | z_cosm | 3.080000e-02 | -- | -- | -- | 3.080000e-02 | 0.000000e+00 | -- | True |
-------------------------------------------------------------------------
================================================================================
%matplotlib inline
fit_model_minuit.set_nu_grid(1E6,1E30,200)
fit_model_minuit.eval()
p2=fit_model_minuit.plot_model(sed_data=sed_data)
p2.setlim(y_min=1E-11,x_min=1E15,y_max=1E-9,x_max=3E19)
try:
c=model_minimizer_minuit.minimizer.draw_contour('r','s')
except:
pass
m=model_minimizer_minuit.minimizer.draw_profile('r')
best_fit_minuit.save_report('SSC-best-fit-minuit.pkl')
model_minimizer_minuit.save_model('model_minimizer_minuit.pkl')
fit_model_minuit.save_model('fit_model_minuit.pkl')
MCMC sampling¶
from jetset.mcmc import McmcSampler
from jetset.minimizer import ModelMinimizer
We used a flat prior centered on the best fit value. Setting
bound=5.0
and bound_rel=True
means that:
the prior interval will be defined as [best_fit_val - delta_m , best_fit_val + delta_p]
with delta_p=delta_m=best_fit_val*bound
If we set bound_rel=False
then delta_p = delta_m =
best_fit_err*bound
It is possible to define asymmetric boundaries e.g. bound=[2.0,5.0]
meaning that
for
bound_rel=True
delta_p = best_fit_val*bound[1]
delta_m =b est_fit_val*bound[0]
for
bound_rel=False
delta_p = best_fit_err*bound[1]
delta_m = best_fit_err*bound[0]
In the next release a more flexible prior interface will be added, including different type of priors
Given the large parameter space, we select a sub sample of parameters
using the use_labels_dict
. If we do not pass the ‘use_labels_dict’
the full set of free parameters will be used
model_minimizer_minuit = ModelMinimizer.load_model('model_minimizer_minuit.pkl')
mcmc=McmcSampler(model_minimizer_minuit)
labels=['N','B','beam_obj','s','gamma0_log_parab']
model_name='jet_leptonic'
use_labels_dict={model_name:labels}
mcmc.run_sampler(nwalkers=128,burnin=10,steps=50,bound=5.0,bound_rel=True,threads=None,walker_start_bound=0.005,use_labels_dict=use_labels_dict)
mcmc run starting
0%| | 0/50 [00:00<?, ?it/s]
mcmc run done, with 1 threads took 232.73 seconds
print(mcmc.acceptance_fraction)
0.52171875
p=mcmc.plot_model(sed_data=sed_data,fit_range=[1E15, 1E20],size=100)
p.setlim(y_min=1E-14,x_min=1E6,x_max=2E20)
p=mcmc.plot_model(sed_data=sed_data,fit_range=[1E15, 1E20],size=100,quantiles=[0.05,0.95])
p.setlim(y_min=1E-14,x_min=1E6,x_max=2E20)
f=mcmc.plot_chain(‘s’,log_plot=False)
f=mcmc.corner_plot()
mcmc.get_par('N')
(array([1.82210412, 1.84695012, 1.80917268, ..., 1.91776914, 1.76293129,
1.91006206]),
0)
f=mcmc.plot_par('beam_obj')
f=mcmc.plot_par('gamma0_log_parab',log_plot=True)
Save and reuse MCMC¶
mcmc.save('mcmc_sampler.pkl')
from jetset.mcmc import McmcSampler
from jetset.data_loader import ObsData
from jetset.plot_sedfit import PlotSED
from jetset.test_data_helper import test_SEDs
sed_data=ObsData.load('Mrk_401.pkl')
ms=McmcSampler.load('mcmc_sampler.pkl')
ms.model.name
'Only-Synch-best-fit-minuit'
p=ms.plot_model(sed_data=sed_data,fit_range=[1E15, 1E20],size=50)
p.setlim(y_min=1E-14,x_min=1E6,x_max=2E20)
p=ms.plot_model(sed_data=sed_data,fit_range=[1E15, 1E20],size=100,quantiles=[0.05,0.95])
p.setlim(y_min=1E-14,x_min=1E6,x_max=2E20)
f=ms.plot_par('beam_obj',log_plot=False)
f=ms.plot_par('B',log_plot=True)
f=mcmc.plot_chain('s',log_plot=False)
f=mcmc.corner_plot()
mcmc.samples.shape
(5120, 5)
mcmc.calls_tot
6400
5120/6400
0.8