Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
c14b43e
Split math of status quo
felixhekhorn Jan 11, 2023
85c2da6
Move ads to new layout
felixhekhorn Jan 12, 2023
10d2240
Add pytest coverage
felixhekhorn Jan 12, 2023
bc4a967
adding LO splitting functions
adrianneschauss Jan 16, 2023
2ee69ec
test added
adrianneschauss Jan 16, 2023
71c7cb2
adding citation
giacomomagni Jan 16, 2023
a67b776
propagate polarized from op card to op.__init__
giacomomagni Jan 16, 2023
0af52cc
fix as1 tests
giacomomagni Jan 16, 2023
8fd5436
fix init name
giacomomagni Jan 16, 2023
04b64ba
Merge branch 'split-math-in-module' into polarized_implementation
giacomomagni Jan 16, 2023
4678da7
Start reshuffling OME
felixhekhorn Jan 16, 2023
694a239
Move ad benchmark
felixhekhorn Jan 16, 2023
ec04696
Move OME
felixhekhorn Jan 17, 2023
febd415
Add missing init file
felixhekhorn Jan 17, 2023
bb6af22
propagate polarized and time-like from op card to op.__init__
giacomomagni Jan 16, 2023
3db8696
Add switch for OME
felixhekhorn Jan 17, 2023
7a74ddb
Fix function names
felixhekhorn Jan 17, 2023
5191fb6
Merge branch 'split-math-in-module' into polarized_implementation
giacomomagni Jan 23, 2023
8e7f153
NLO polarized AD implemented
adrianneschauss Jan 25, 2023
22430dd
fix docstrings and prepare to NNLO
giacomomagni Jan 25, 2023
a37d3d4
some fixes in NLO ad
giacomomagni Jan 25, 2023
5d0c044
add NNLO ads
giacomomagni Jan 25, 2023
54f69ce
extend references
giacomomagni Jan 25, 2023
7f4d394
fix typo
giacomomagni Jan 25, 2023
5dda210
another small fix
giacomomagni Jan 25, 2023
1126089
Fix runcard translation
felixhekhorn Jan 26, 2023
ca62634
Merge branch 'split-math-in-module' into polarized_implementation
felixhekhorn Jan 26, 2023
ad9394f
Init benchmarks
felixhekhorn Jan 26, 2023
3e453ee
fix numba bug
giacomomagni Jan 27, 2023
5d283fb
guess a minus sign explicitly from Vogt convention. Will this be cor…
giacomomagni Jan 27, 2023
4f5f0e5
fix mius sign also in tests
giacomomagni Jan 27, 2023
8ab2d51
adding pegasus polarized LO bench
giacomomagni Jan 31, 2023
6cf3ca1
refactor NLO polarized ad and more tests
giacomomagni Jan 31, 2023
47d4025
make NLO benchmark passing
giacomomagni Jan 31, 2023
4ac28df
Lha polarized data
adrianneschauss Jan 31, 2023
0ca49bd
Merge branch 'polarized_implementation' of github.com:NNPDF/eko into …
adrianneschauss Jan 31, 2023
c1c9de5
make NNLO bench working
giacomomagni Jan 31, 2023
2cdb34e
Merge remote-tracking branch 'origin/master' into polarized_implement…
giacomomagni Jan 31, 2023
eaa8c11
incorporates Polarized
adrianneschauss Jan 31, 2023
07aede4
Merge branch 'polarized_implementation' of github.com:NNPDF/eko into …
adrianneschauss Jan 31, 2023
3864dbf
Minor bug to be fixed
adrianneschauss Jan 31, 2023
1798bd2
error to fix
adrianneschauss Feb 1, 2023
2ffce74
data table retrieval fixed
adrianneschauss Feb 1, 2023
b27a63f
Benchmark pol works, pre-commit issue
adrianneschauss Feb 3, 2023
64f19b3
last fix on LHA pol table
giacomomagni Feb 3, 2023
f758c25
pre-commit ad files
giacomomagni Feb 3, 2023
8c3c754
test ns sea ad3
giacomomagni Feb 3, 2023
b6d34fe
fix typo
giacomomagni Feb 3, 2023
ce02fff
some cleaning
giacomomagni Feb 3, 2023
5de82cb
some cleaning 2
giacomomagni Feb 3, 2023
42bb04c
remove some old inits
giacomomagni Feb 3, 2023
7942406
Merge branch 'master' into polarized_implementation
felixhekhorn Feb 15, 2023
73dac71
Update banana
felixhekhorn Feb 15, 2023
26f61c5
Fix LHA SV
felixhekhorn Feb 15, 2023
7496c8c
Fix tests
felixhekhorn Feb 15, 2023
0027f26
Update src/eko/evolution_operator/grid.py
giacomomagni Feb 16, 2023
b0f9469
Update src/ekomark/benchmark/external/LHA_utils.py
giacomomagni Feb 16, 2023
4343e3b
Add NNPDFpol bench
felixhekhorn Feb 16, 2023
a615c26
Add DSSV bench
felixhekhorn Feb 16, 2023
243146a
Do forward evln
felixhekhorn Feb 16, 2023
e498019
provide more tests
giacomomagni Feb 17, 2023
b444e8e
fix typo
giacomomagni Feb 17, 2023
65a81ee
recover full coverage
giacomomagni Feb 18, 2023
86dbd73
Document modified to describe pol AD
adrianneschauss Feb 19, 2023
c87714a
Merge branch 'polarized_implementation' into HEAD
adrianneschauss Feb 19, 2023
b5f242b
Revert "Document modified to describe pol AD"
adrianneschauss Feb 19, 2023
4fbef55
documentation on pol splitting functions
adrianneschauss Feb 19, 2023
6e0f233
Revert "documentation on pol splitting functions"
adrianneschauss Feb 19, 2023
0aa9059
documentation for pol splitting functions
adrianneschauss Feb 19, 2023
00810a0
added test to NLO pol AD
adrianneschauss Feb 20, 2023
14023e3
minor correction
adrianneschauss Feb 20, 2023
dfdf2ab
Revert "minor correction"
adrianneschauss Feb 20, 2023
b4d8b96
minor correction
adrianneschauss Feb 20, 2023
79745e9
Revert "minor correction"
adrianneschauss Feb 20, 2023
9c9b7b8
minor corrections
adrianneschauss Feb 20, 2023
3be9aae
move the docs uìone paragraph up and minor fixes
giacomomagni Feb 21, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions benchmarks/DSSV_bench.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
"""Benchmark DSSV pdf family.

Note that the PDF set is private, but can be obtained from the
authors upon request.
"""
import numpy as np
from banana import register

from eko import interpolation
from ekomark.benchmark.runner import Runner

register(__file__)


class BenchmarkDSSV(Runner):
"""Benchmark DSSV pdf family."""

external = "LHAPDF"

# Rotate to evolution basis
rotate_to_evolution_basis = True

def skip_pdfs(self, _theory):
return [-6, 6, 5, -5, 4, -4, 22, "ph", "T35", "V35", "T24", "V24", "T15", "V15"]

def benchmark(self, Q0=1.65, Q2grid=(100,)):
theory_card = {
"Qref": 1.0,
"mc": 1.4,
"mb": 4.75,
"mt": 175,
"kcThr": 1.0,
"kbThr": 1.0,
"ktThr": 1.0,
"alphas": 0.49127999999999999,
"FNS": "ZM-VFNS",
"ModEv": "EXA",
"Q0": Q0,
"PTO": 1,
"MaxNfPdf": 3,
"MaxNfAs": 3,
}

operator_card = {
"Q2grid": list(Q2grid),
"polarized": [True],
"interpolation_xgrid": interpolation.lambertgrid(50, 1e-5),
}
self.run([theory_card], [operator_card], ["DSSV_REP_LHAPDF6"])


if __name__ == "__main__":
low2 = 5**2
high2 = 30**2
dssv = BenchmarkDSSV()
dssv.benchmark(Q0=np.sqrt(low2), Q2grid=[high2])
40 changes: 36 additions & 4 deletions benchmarks/NNPDF_bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import numpy as np
from banana import register

from eko import interpolation
from ekomark.benchmark.runner import Runner

register(__file__)
Expand Down Expand Up @@ -90,14 +91,45 @@ def benchmark_nnlo(self, Q0=1.65, Q2grid=(100,)):
self.run([theory_card], [operator_card], ["NNPDF40_nnlo_as_01180"])


class BenchmarkNNPDFpol11(BenchmarkNNPDF):
"""Benchmark NNPDFpol11"""

def benchmark(self, Q0=1.65, Q2grid=(100,)):
theory_card = {
"Qref": 91.2,
"mc": 1.41421,
"mb": 4.75,
"mt": 175,
"kcThr": 1.0,
"kbThr": 1.0,
"ktThr": 1.0,
"alphas": 0.119002,
"alphaqed": 0.007496,
"FNS": "ZM-VFNS",
"ModEv": "TRN",
"Q0": Q0,
"PTO": 1,
}

operator_card = {
**base_operator,
"Q2grid": list(Q2grid),
"polarized": [True],
"interpolation_xgrid": interpolation.lambertgrid(50, 1e-5),
}
self.run([theory_card], [operator_card], ["NNPDFpol11_100"])


if __name__ == "__main__":
low2 = 4**2
low2 = 5**2
high2 = 30**2
# nn31 = BenchmarkNNPDF31()
# # test forward
# nn31.benchmark_nlo(Q0=np.sqrt(low2), Q2grid=[10])
# # test backward
# #nn31.benchmark_nlo(Q0=np.sqrt(high2), Q2grid=[low2])
nn40 = BenchmarkNNPDF40()
# nn40.benchmark_nnlo(Q2grid=[100])
nn40.benchmark_nnlo(Q0=np.sqrt(high2), Q2grid=[low2])
# nn40 = BenchmarkNNPDF40()
# # nn40.benchmark_nnlo(Q2grid=[100])
# nn40.benchmark_nnlo(Q0=np.sqrt(high2), Q2grid=[low2])
nnpol = BenchmarkNNPDFpol11()
nnpol.benchmark(Q0=np.sqrt(low2), Q2grid=[high2])
17 changes: 14 additions & 3 deletions benchmarks/apfel_bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,16 @@ def benchmark_plain(self, pto):
cartesian_product(th), operators.build(operators.apfel_config), ["ToyLH"]
)

def benchmark_plain_pol(self, pto):
"""Plain configuration"""

th = self.ffns_theory.copy()
th.update({"PTO": [pto]})
th["ModEv"] = ["EXA"] # TODO for the time one is sufficient
op = operators.apfel_config.copy()
op["polarized"] = [True]
self.run(cartesian_product(th), operators.build(op), ["ToyLH"])

def benchmark_sv(self, pto, svmode):
"""Scale Variation"""

Expand Down Expand Up @@ -189,10 +199,11 @@ def benchmark_sv(self, pto, svmode):

if __name__ == "__main__":

obj = BenchmarkVFNS()
# obj = BenchmarkFFNS()
# obj = BenchmarkVFNS()
obj = BenchmarkFFNS()

obj.benchmark_plain_pol(2)
# obj.benchmark_plain(2)
obj.benchmark_sv(2, "exponentiated")
# obj.benchmark_sv(2, "exponentiated")
# obj.benchmark_kthr(2)
# obj.benchmark_msbar(2)
30 changes: 27 additions & 3 deletions benchmarks/lha_paper_bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@
"""
import numpy as np
from banana import register
from banana.data import cartesian_product

from eko.interpolation import lambertgrid
from ekomark.benchmark.runner import Runner
from ekomark.data import operators

register(__file__)

Expand Down Expand Up @@ -219,12 +221,34 @@ def benchmark_sv(self, pto):
self.run_lha([low, high])


class BenchmarkFFNS_polarized(BenchmarkFFNS):
def run_lha(self, theory_updates):
"""Enforce operator grid and PDF.

Parameters
----------
theory_updates : list(dict)
theory updates
"""
self.run(
theory_updates,
[
{
"Q2grid": [1e4],
"ev_op_iterations": 10,
"interpolation_xgrid": lambertgrid(60).tolist(),
"polarized": True,
}
],
["ToyLH_polarized"],
)


if __name__ == "__main__":
# Benchmark to LHA
obj = BenchmarkVFNS()
obj = BenchmarkFFNS_polarized()
# obj = BenchmarkFFNS()

# obj.benchmark_plain(0)
# obj.benchmark_plain(1)
obj.benchmark_sv(1)

# # VFNS benchmarks with LHA settings
Expand Down
22 changes: 16 additions & 6 deletions benchmarks/pegasus_bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@ class BenchmarkVFNS(PegasusBenchmark):
"nfref": 3,
"nf0": 3,
}
zm_theory = tolist(zm_theory)
vfns_theory = tolist(zm_theory)

def benchmark_plain(self, pto):
"""Plain configuration"""

th = self.zm_theory.copy()
th = self.vfns_theory.copy()
th.update(
{
"PTO": [pto],
Expand All @@ -79,7 +79,7 @@ def benchmark_plain(self, pto):
def benchmark_sv(self, pto, svmode):
"""Scale Variation"""

th = self.zm_theory.copy()
th = self.vfns_theory.copy()
th.update(
{
"PTO": [pto],
Expand Down Expand Up @@ -125,6 +125,15 @@ def benchmark_plain(self, pto):
cartesian_product(th), operators.build(operators.pegasus_config), ["ToyLH"]
)

def benchmark_plain_pol(self, pto):
"""Plain polarized configuration"""

th = self.ffns_theory.copy()
th.update({"PTO": [pto]})
op = operators.pegasus_config.copy()
op["polarized"] = [True]
self.run(cartesian_product(th), operators.build(op), ["ToyLH_polarized"])

def benchmark_sv(self, pto, svmode):
"""Scale Variation"""

Expand All @@ -143,9 +152,10 @@ def benchmark_sv(self, pto, svmode):

if __name__ == "__main__":

obj = BenchmarkVFNS()
# obj = BenchmarkFFNS()
# obj = BenchmarkVFNS()
obj = BenchmarkFFNS()
obj.benchmark_plain_pol(1)
# obj.benchmark_plain(1)

obj.benchmark_sv(2, "exponentiated")
# obj.benchmark_sv(2, "exponentiated")
# vfns.benchmark_sv()
7 changes: 7 additions & 0 deletions doc/source/development/Benchmarks.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,13 @@ List of bugs in :cite:`Dittmar:2005ed`
- in table 15, part 1: :math:`xd_v(x=10^{-4}, \mu_F^2 = 10^4~\mathrm{GeV}^2) = 1.0699\cdot 10^{-4}` (wrong exponent) and
:math:`xg(x=10^{-4}, \mu_F^2 = 10^4~\mathrm{GeV}^2) = 9.9694\cdot 10^{2}` (wrong exponent)

- in table 16: the distribution :math:`L_{m}` is not vanishing despite the benchmark table is produced using the
toy PDF used, defined in :eqref:`4.57`, has :math:`\bar{u} = \bar{d}`. This means that :math:`T_3`
is not correct. The whole colum of :math:`L_{m}` should be set to 0, sine at |LO| it is not possible
to generate a difference between :math:`\bar{u}` and :math:`\bar{d}`

- in table 17: same as before :math:`L_{m}` is bugged.

LHAPDF
------

Expand Down
52 changes: 52 additions & 0 deletions doc/source/refs.bib
Original file line number Diff line number Diff line change
Expand Up @@ -776,3 +776,55 @@ @article{Albino:2000cp
pages = "93--102",
year = "2001"
}

@article{Gluck:1995yr,
author = "Gluck, M. and Reya, E. and Stratmann, M. and Vogelsang, W.",
title = "{Next-to-leading order radiative parton model analysis of polarized deep inelastic lepton - nucleon scattering}",
eprint = "hep-ph/9508347",
archivePrefix = "arXiv",
reportNumber = "DO-TH-95-13, RAL-TR-95-042",
doi = "10.1103/PhysRevD.53.4775",
journal = "Phys. Rev. D",
volume = "53",
pages = "4775--4786",
year = "1996"
}

@article{Floratos:1981hs,
author = "Floratos, E. G. and Kounnas, C. and Lacaze, R.",
title = "{Higher Order QCD Effects in Inclusive Annihilation and Deep Inelastic Scattering}",
reportNumber = "LPTENS-81-3",
doi = "10.1016/0550-3213(81)90434-X",
journal = "Nucl. Phys. B",
volume = "192",
pages = "417--462",
year = "1981"
}

@article{Moch:2015usa,
author = "Moch, S. and Vermaseren, J. A. M. and Vogt, A.",
title = "{On \ensuremath{\gamma}5 in higher-order QCD calculations and the NNLO evolution of the polarized valence distribution}",
eprint = "1506.04517",
archivePrefix = "arXiv",
primaryClass = "hep-ph",
reportNumber = "DESY-15-061, NIKHEF-15-018, LTH-1042",
doi = "10.1016/j.physletb.2015.07.027",
journal = "Phys. Lett. B",
volume = "748",
pages = "432--438",
year = "2015"
}

@article{Moch:2014sna,
author = "Moch, S. and Vermaseren, J. A. M. and Vogt, A.",
title = "{The Three-Loop Splitting Functions in QCD: The Helicity-Dependent Case}",
eprint = "1409.5131",
archivePrefix = "arXiv",
primaryClass = "hep-ph",
reportNumber = "DESY-14-157, NIKHEF-14-033, LTH-1023",
doi = "10.1016/j.nuclphysb.2014.10.016",
journal = "Nucl. Phys. B",
volume = "889",
pages = "351--400",
year = "2014"
}
40 changes: 40 additions & 0 deletions doc/source/theory/pQCD.rst
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,45 @@ coupling :math:`a_s(\mu^2)` and are given by :cite:`Moch:2004pa,Vogt:2004mw`

Note the additional minus in the definition of :math:`\gamma`.

Polarized Splitting Functions
-----------------------------

Polarized Altarelli-Parisi splitting kernels are implemented up to |NNLO| and expanded in powers of the strong coupling as in the previous section.
They are used to evolve longitudinally polarized parton distribution functions.
Unlike in the unpolarized case, where the probability of the splitting describes the momentum of parent and daughter partons with averaged spins,
the polarized splitting functions describe the parent and daughter momentums along with their spins
and thus take into account positive or negative helicities.
Throughout, the anomalous dimensions are defined as above and are represented with :math:`\gamma` and not :math:`\Delta\gamma` just like in the unpolarized case.

The |LO| and |NLO| kernels are given in :cite:`Gluck:1995yr` and the |NNLO| in :cite:`Moch:2014sna` and :cite:`Moch:2015usa`.

At |LO|, the non-singlet is the same in both the polarized and unpolarized case.
Due to helicity conservation, the first moment of the anomalous dimension is :math:`\gamma^{(0)}_{qq} (N=1) = \gamma^{(0)}_{qg} (N=1) = 0`.

At |NLO|, the singlet entry of the quark-quark anomalous dimension can be decomposed into the pure singlet
(consisting of the flavour independent quark-quark and quark-antiquark anomalous dimensions) and the plus flavour asymmetry non-singlet:

.. math ::
\gamma^{(1)}_{qq} =\gamma^{(1)}_{ps} + \gamma^{(1)}_{ns,+}

The non-singlet sector in the polarized case swaps the plus and minus non-singlet relative to the unpolarized case.
This is because the polarized non-singlet splitting functions are defined as the difference between the probability of the polarized parton splitting into daughter partons of the same flavour
and daughters splitting into a different flavours and opposite helicity. The first moments of the anomalous dimensions are:

.. math ::
\gamma^{(1)}_{ns,+} (N=1) &= 0 \\
\gamma^{(1)}_{qq} (N=1) &= 24 C_F T_R \\
\gamma^{(1)}_{qg} (N=1) &= 0 \\

At |NNLO| the non-singlet is further decomposed into the helicity difference quark-antiquark anomalous dimension called the valence polarized non-singlet and defined as:

.. math ::
\gamma^{(2)}_{ns,v} =\gamma^{(2)}_{ns,-} + \gamma^{(2)}_{ns,s}

where :math:`\gamma^{(2)}_{ns,-}` is the minus flavour asymmetry non-singlet and :math:`\gamma^{(2)}_{ns,s}` the sea-like polarized non-singlet.
The singlet entry :math:`\gamma^{(2)}_{qq}` is defined as above in the |NLO| case.


Unified Splitting Functions
---------------------------

Expand All @@ -83,6 +122,7 @@ where :math:`a = \alpha/(4\pi)`.
The expression of the pure |QED| and of the mixed |QED| :math:`\otimes` |QCD| splitting kernels are given in
:cite:`deFlorian:2015ujt,deFlorian:2016gvk`


Order specification
-------------------

Expand Down
Loading