Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix nf in inverse matching #312

Merged
merged 5 commits into from
Oct 11, 2023
Merged

Fix nf in inverse matching #312

merged 5 commits into from
Oct 11, 2023

Conversation

giacomomagni
Copy link
Collaborator

Somehow the nf passed during the inverse matching is not correct:

see:

nf_match = op.nf - 1 if recipe.inverse else op.nf

[2] > /data/theorie/gmagni/N3PDF/eko_fhmv_private/src/eko/runner/parts.py(155)match()
-> nf_match = op.nf - 1 if recipe.inverse else op.nf
(Pdb++) recipe
Matching(scale=2.2801, hq=4, inverse=True)
(Pdb++) op.nf
3

This can be fixed by setting always:

 nf_match = op.nf

@giacomomagni giacomomagni added the bug Something isn't working label Oct 9, 2023
@giacomomagni giacomomagni self-assigned this Oct 9, 2023
@alecandido
Copy link
Member

Could you also provide a unit test?

@alecandido
Copy link
Member

This can be fixed by setting always:

 nf_match = op.nf

Btw, at this point it should not be worth to define nf_match at all. Just use op.nf.

Base automatically changed from lh-bench-23 to master October 10, 2023 13:49
Copy link
Member

@alecandido alecandido left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If there is no brilliant idea for any unit test in the short term, the benchmark is definitely good enough.

We can merge.

@giacomomagni giacomomagni merged commit f39b012 into master Oct 11, 2023
7 checks passed
@giacomomagni
Copy link
Collaborator Author

If there is no brilliant idea for any unit test in the short term, the benchmark is definitely good enough.

Thanks, indeed I had not a brilliant idea for a unit test, as this bug was mostly visible at PDF level.

@giacomomagni giacomomagni deleted the fix_matching_inversion_2 branch October 11, 2023 12:23
@felixhekhorn
Copy link
Contributor

If there is no brilliant idea for any unit test in the short term, the benchmark is definitely good enough.

Thanks, indeed I had not a brilliant idea for a unit test, as this bug was mostly visible at PDF level.

I do have some idea (call match with mocked ome.OME and check the outcome), but I can do in a separate PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants