diff --git a/src/pineko/cli/convolute.py b/src/pineko/cli/convolute.py index ba6a2c70..3b1899e7 100644 --- a/src/pineko/cli/convolute.py +++ b/src/pineko/cli/convolute.py @@ -1,6 +1,7 @@ # -*- coding: utf-8 -*- """CLI entry point to convolution.""" import click +import eko import pineappl import rich @@ -41,6 +42,7 @@ def subcommand(grid_path, op_path, fktable, max_as, max_al, xir, xif, pdf, assum PDF is an optional PDF set compatible with the EKO to compare grid and FK table. """ grid = pineappl.grid.Grid.read(grid_path) + operators = eko.output.Output.load_tar(op_path) rich.print( rich.panel.Panel.fit("Computing ...", style="magenta", box=rich.box.SQUARE), f" {grid_path}\n", @@ -50,7 +52,7 @@ def subcommand(grid_path, op_path, fktable, max_as, max_al, xir, xif, pdf, assum ) _grid, _fk, comp = evolve.evolve_grid( grid, - op_path, + operators, fktable, max_as, max_al, diff --git a/src/pineko/evolve.py b/src/pineko/evolve.py index 2dbc5323..56760218 100644 --- a/src/pineko/evolve.py +++ b/src/pineko/evolve.py @@ -78,7 +78,7 @@ def write_operator_card(pineappl_grid, default_card, card_path, xif): def evolve_grid( grid, - eko_path, + operators, fktable_path, max_as, max_al, @@ -94,7 +94,7 @@ def evolve_grid( ---------- grid : pineappl.grid.Grid unconvoluted grid - eko_path : str + operators : eko.output.Output evolution operator fktable_path : str target path for convoluted grid @@ -114,7 +114,6 @@ def evolve_grid( if given, a comparison table (with / without evolution) will be printed """ _x_grid, _pids, mur2_grid, _muf2_grid = grid.axes() - operators = eko.output.Output.load_tar(eko_path) check.check_grid_and_eko_compatible(grid, operators, xif) # rotate to evolution (if doable and necessary) if np.allclose(operators["inputpids"], br.flavor_basis_pids): diff --git a/src/pineko/theory.py b/src/pineko/theory.py index 69091257..4a3806af 100644 --- a/src/pineko/theory.py +++ b/src/pineko/theory.py @@ -351,6 +351,7 @@ def fk(self, name, grid_path, tcard, pdf): xir = tcard["XIR"] xif = tcard["XIF"] ftr = tcard["fact_to_ren_scale_ratio"] + # loading grid grid = pineappl.grid.Grid.read(grid_path) if not np.isclose(xir, 1.0): check.contains_ren(grid) @@ -376,6 +377,8 @@ def fk(self, name, grid_path, tcard, pdf): astrong = sc.StrongCoupling.from_dict(tcard) # ocard = self.load_operator_card(name) # q2_grid = ocard["Q2grid"] + + # loading ekos operators = eko.output.Output.load_tar(eko_filename) q2_grid = operators["Q2grid"].keys() # PineAPPL wants alpha_s = 4*pi*a_s @@ -398,7 +401,7 @@ def fk(self, name, grid_path, tcard, pdf): ) _grid, _fk, comparison = evolve.evolve_grid( grid, - eko_filename, + operators, fk_filename, max_as, max_al,