# Evaluating the CE model¶

We are now ready to evaluate a CE model constructed from the initial 10
calculations. The evaluation of the CE model is performed using `CEBulk`

class, and it supports 3 different linear regression schemes: Bayesian
Compressive Sensing (BCS), \(\ell_1\) and \(\ell_2\) regularization.
We will be trying out \(\ell_1\) and \(\ell_2\) regularization schemes
to see how they perform using the script below. The script is written to use
\(\ell_1\) regularization as a fitting scheme (i.e., fitting_scheme=’l1’),
and you can change the fitting scheme to \(\ell_2\) simply by changing it
to ‘l2’.

For this tutorial, we use `EMT`

calculator to
demonstrate how one can run calculations on the structures generated using
CLEASE and update database with the calculation results for further evaluation
of the CE model. Here is a simple example script that runs the calculations
for all structures that are not yet converged

```
>>> from clease import Evaluate
>>> import clease.plot_post_process as pp
>>> import matplotlib.pyplot as plt
>>>
>>> eva = Evaluate(settings=settings, scoring_scheme='k-fold', nsplits=10)
>>> # scan different values of alpha and return the value of alpha that yields
>>> # the lowest CV score
>>> eva.set_fitting_scheme(fitting_scheme='l1')
>>> alpha = eva.plot_CV(alpha_min=1E-7, alpha_max=1.0, num_alpha=50)
>>>
>>> # set the alpha value with the one found above, and fit data using it.
>>> eva.set_fitting_scheme(fitting_scheme='l1', alpha=alpha)
>>> eva.fit() # Run the fit with these settings.
>>>
>>> fig = pp.plot_fit(eva)
>>> plt.show()
>>>
>>> # plot ECI values
>>> fig = pp.plot_eci(eva)
>>> plt.show()
>>> # save a dictionary containing cluster names and their ECIs
>>> eva.save_eci(fname='eci_l1')
```

For more information, see `Evaluate`

.