**SEMPS** is a python tool designed to compute the non-linear matter power spectrum for a wide range of cosmological models, and redshifts.

It is built using supervised machine learning algorithm, called **gradient boosting machine (GBM)**. The model for SEMPS is described in details in our paper.

The salient features of SEMPS are

- The matter power specturm estimates are accurate to 5-10% upto k ~ 10mpc/h.
- The computation, facilitated by a trained machine learning model, is instantaneous. It can perform upto 500 computations within a second.
- SEMPS is lightweight, and is very easy to use.

**Dependencies**

**Example Python Code**

```
from numpy import linspace
import semps
Omega_m = 0.3
sigma8 = 0.8
h = 0.7
n_s = 0.96
Omega_b = 0.046
w = -1.0
# cosmological parameters
cosmological_model = [Omega_m, sigma8, h, n_s, Omega_b, w]
# redshift
redshift = 0.0
# make k array, logarithmically spaced between 0.001 and 10.
k = linspace(-3,1,1000)
k = 10**k
# load SEMPS
ML_model = semps.PowerSpectrum('blackbox')
# compute the matter power spectrum
pk = ML_model.predict(cosmological_model, redshift, k)
# plot the power spectra for all the k-values
from matplotlib.pylot import loglog, show, xlabel, ylabel
loglog(k,pk,'b',lw=2)
xlabel('$\mathtt{k\ [h/Mpc]}$',fontsize=22)
ylabel('$\mathtt{P(k)\ [Mpc/h]^3}$',fontsize=22)
show()
```

```
```

**Maintained by:**

Janu Verma -
j.verma5@gmail.com

Irshad Mohammed -
irshad@physik.uzh.ch

**Example**

See the `example.py`

file in SEMPS directory.

**Citation**

Irshad Mohammed, and Janu Verma *A supervised machine learning estimator for non-linear matter power spectrum - SEMPS.
arXiv:1507.04622*