> For the complete documentation index, see [llms.txt](https://seattle-university.gitbook.io/sdgne/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://seattle-university.gitbook.io/sdgne/gretel-evaluation.md).

# Gretel Evaluation

[Gretel.ai](https://gretel.ai/) is another tool that provides the functionality to generate synthetic tabular data. We also use their [Gretel Score](https://gretel.ai/blog/measure-the-quality-of-any-synthetic-dataset-with-gretel-evaluate) as an evaluation metric.

## Installing Gretel Client

```python
pip install gretel-client
```

{% hint style="info" %}
If you are using Jupyter Notebook or Google Colab, please restart your kernel after installing the package.
{% endhint %}

```python
from sdgne.evaluator.evaluator import GretelEvaluation

evaluator = GretelEvaluation(synthesized_data, minority_column_label, 
                                minority_class_label, gretel_api_key)
                                
report = evaluator.run_gretel_quality_report()
```

## Importing Gretel Evaluation

```python
from sdgne.evaluator.evaluator import GretelEvaluation
```

## Creating an evaluator

```python
report = evaluator.run_gretel_quality_report()   
```

### Return

A dictionary containing the quality report generated by Gretel AI [\[7\]](/sdgne/references.md).

{% hint style="success" %}
To generate Gretel Score for synthetic data using SDGnE, you'd require [Gretel API Key](https://console.gretel.ai/users/me/key/).&#x20;
{% endhint %}
