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

Time Like Splitting Functions #232

Merged
merged 45 commits into from
Apr 5, 2023
Merged

Time Like Splitting Functions #232

merged 45 commits into from
Apr 5, 2023

Conversation

t7phy
Copy link
Member

@t7phy t7phy commented Mar 25, 2023

No description provided.

@t7phy
Copy link
Member Author

t7phy commented Mar 25, 2023

This PR is almost final and ready to be merged, however there is just one thing left that needs to be checked but I am facing a problem in that once I modify the gamma functions, it seems to me that NUMBA is not recompiling them. How do I force NUMBA to recompile after any change I make?

@alecandido
Copy link
Member

alecandido commented Mar 26, 2023

This PR is almost final and ready to be merged, however there is just one thing left that needs to be checked but I am facing a problem in that once I modify the gamma functions, it seems to me that NUMBA is not recompiling them. How do I force NUMBA to recompile after any change I make?

Cancel the __pycache__ directories.

https://numba.pydata.org/numba-doc/dev/developer/caching.html#cache-clearing

@t7phy
Copy link
Member Author

t7phy commented Mar 26, 2023

This PR is almost final and ready to be merged, however there is just one thing left that needs to be checked but I am facing a problem in that once I modify the gamma functions, it seems to me that NUMBA is not recompiling them. How do I force NUMBA to recompile after any change I make?

Cancel the __pycache__ directories.

https://numba.pydata.org/numba-doc/dev/developer/caching.html#cache-clearing

I actually did delete them in the directory where the as files are stored, however that did not force recompile.

@alecandido
Copy link
Member

alecandido commented Mar 26, 2023

If you want to just remove Numba cached files, you can filter them with:

find . -type f | grep '\.nb[i|c]$' | xargs rm -f

(.nbi is a cache index file, and .nbc is a pickled Numba object, so a compiled function)

However, this would not fix your problem here:

I actually did delete them in the directory where the as files are stored, however that did not force recompile.

Can you explicitly write exactly which directory you canceled?

@t7phy
Copy link
Member Author

t7phy commented Mar 26, 2023

If you want to just remove Numba cached files, you can filter them with:

find . -type f | grep '\.nb[i|c]$' | xargs rm -f

However, this would not fix your problem here:

I actually did delete them in the directory where the as files are stored, however that did not force recompile.

Can you explicitly write exactly which directory you canceled?

eko/src/ekore/anomalous_dimensions/unpolarized/time_like/__pycache__

@alecandido
Copy link
Member

eko/src/ekore/anomalous_dimensions/unpolarized/time_like/__pycache__

In principle, it is the correct one. However, try to cancel them all, at least inside anomalous_dimensions.

Worst case solution is of course to reclone the repo in a new location. However, that might work for multiple reasons: Numba objects have to be stored somewhere, but that somewhere might be local, but also non-local to the project (e.g. in case you didn't install EKO in development mode, or if you set Numba to use a global cache).

But, as a first attempt, if deleting is not working, you can try to edit the file you want to recompile. I'm not sure if Numba uses the time-stamp or a file hash, but changing the file content will change both of them.

@t7phy
Copy link
Member Author

t7phy commented Mar 26, 2023

eko/src/ekore/anomalous_dimensions/unpolarized/time_like/__pycache__

In principle, it is the correct one. However, try to cancel them all, at least inside anomalous_dimensions.

Worst case solution is of course to reclone the repo in a new location. However, that might work for multiple reasons: Numba objects have to be stored somewhere, but that somewhere might be local, but also non-local to the project (e.g. in case you didn't install EKO in development mode, or if you set Numba to use a global cache).

I had installed in as per documentations for installing EKO for development.

But, as a first attempt, if deleting is not working, you can try to edit the file you want to recompile. I'm not sure if Numba uses the time-stamp or a file hash, but changing the file content will change both of them.

That is indeed the problem. Modifying the file should lead numba to recompile but it is not doing that. Yesterday, I literally deleted the entire content of as2.py and saved it, then I ran NLO benchmarks and they still ran. So something very weird is happening, which I don't understand.

@felixhekhorn
Copy link
Contributor

You may not be responsible for everything, but for the major part yes: please run always pre-commit

We have finally the CI check back! so I can stop complaining personally and let the red cross speak ...

@t7phy
Copy link
Member Author

t7phy commented Apr 5, 2023

You may not be responsible for everything, but for the major part yes: please run always pre-commit

We have finally the CI check back! so I can stop complaining personally and let the red cross speak ...

but it has always been active for me. I do not know why it never checked the test files or the doc files, but I have no reason to disable it.

@felixhekhorn
Copy link
Contributor

but it has always been active for me. I do not know why it never checked the test files or the doc files, but I have no reason to disable it.

well, the red cross says something different - and for the fixes in the last two commits and did nothing more then add a random new line somewhere and run pre-commit - so my local version is the CI version ...

in any case I will not attempt the docstyle fixes here to not further spoil this PR, but open a new dedicated one

@t7phy
Copy link
Member Author

t7phy commented Apr 5, 2023

but it has always been active for me. I do not know why it never checked the test files or the doc files, but I have no reason to disable it.

well, the red cross says something different - and for the fixes in the last two commits and did nothing more then add a random new line somewhere and run pre-commit - so my local version is the CI version ...

in any case I will not attempt the docstyle fixes here to not further spoil this PR, but open a new dedicated one

So I think everything in this PR is fine now?

@felixhekhorn
Copy link
Contributor

So I think everything in this PR is fine now?

let me run the benchmarks first ... no idea how you managed without 7e325cf and 193afc8 : they are strictly necessary ...

@t7phy
Copy link
Member Author

t7phy commented Apr 5, 2023

So I think everything in this PR is fine now?

let me run the benchmarks first ... no idea how you managed without 7e325cf and 193afc8 : they are strictly necessary ...

I ran all benchmarks before the shift was made from Q2 to mu.

Copy link
Contributor

@felixhekhorn felixhekhorn left a comment

Choose a reason for hiding this comment

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

I believe this is ok now

two remarks

  • I think this is significant slower than space-like counterparts because here is no reuse of harmonic sums at all (which proves they are a bottleneck) ... the problem can be tackled in Caching harmonic sums #202
  • at NNLO V has a bigger error O(0.2%) than S O(0.04%) in the small x region (where small here x=0.01) which is a bit odd, but fine

@alecandido
Copy link
Member

After isolated benchmarks completion feel free to merge. Problems with pre-commit are not caused by this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request physics new physics features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants