Grafana, Elasticsearch datasource and option script

Try specifying this in the script field:

_value / doc[‘system.cpu.cores’].value