-
Notifications
You must be signed in to change notification settings - Fork 0
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
Roadmap for the paper #19
Comments
@marcorossi5 could you please take care of the first 2 points? |
I collected a lot of accuracy plots for different pdf sets, both about central and noncentral pdfs. |
I can take care of the GPU performance plots, I have access to a good number of different GPUs. |
I made accuracy plots and collected in this folder to be downloaded https://cernbox.cern.ch/index.php/s/AfTAO0tMf0p3xk0 |
I have place a pair of simple scripts in the paper repo (https://github.com/N3PDF/papers/pull/8). I don't understand why the code below is extremely slow in comparison to LHAPDF, and I was just wondering if multi-replica evaluation is something that we should consider implementing: #!/usr/bin/env python
import time
import pdfflow.pflow as pdf
import numpy as np
pdfs = [
pdf.mkPDF(f'NNPDF31_nlo_as_0118_1000/{i}', dirname='/opt/lhapdf/share/LHAPDF/')
for i in range(1001)
]
xgrids = np.loadtxt('xgrids.dat')
q2 = 1.65**2*np.ones(len(xgrids))
fls = [-5,-4,-3,-2,-1,0,1,2,3,4,5]
t0 = time.time()
for pdf in pdfs:
pdf.xfxQ2(fls, xgrids, q2)
print('total time (s):', time.time()-t0) |
Could it be because the first time you call xfxQ2, tf builds the graph? The first iteration is way slower than the others. Here you rebuild a graph for each of the 1000 pdfs |
Indeed, here some numbers for pdfflow vs lhapdf timings on CPU. We should think if there are possibilities to improve on that: LHAPDF
PDFFlow
|
As you said, multireplica implementation makes a lot of sense. There are some intermediate solutions, as making sure that it doesn't rebuild the graph replica to replica (checking what changes from one to the next and make it into a tensor instead of python/numpy variables). My guess is that option 2 will make option 1 easier in the future so there's that. |
Currently the graph is grid dependent. Every instance of pdf will create a new graph because of the shape of the grid. We abstracted just the shape of the query points. |
Yes, this is what I was thinking. And I don't think that using a placeholder which we fill in later will change anything for one-replica calls since the grids are not that big anyway. |
Can we insert a check that counts how many times the graph is being rebuilt? |
So, the only thing missing here is adding docs for the normal usage. (I'd do it myself but am in a -long- meeting so not sure when I'll have a time today before the paper gets sent at 8pm :P) Also, the section "General Usage" maybe should have another name. Maybe "Advance usage"... |
Do you mean in the paper? Outlook section? Or appendix? |
No, no, the documentation in this repository. So that before submiting the paper we generate the version 1 release of pdfflow. |
Ok, I was confused |
Sorry, I was writing here while paying attention to the voice of people :__ |
Ok then, it's clear. I'm going to create a new branch from master named docs, to include some typos I found and these new features. |
Following the development, here my wish list for the paper:
The text was updated successfully, but these errors were encountered: