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

Improve the transfers of DIGIs and clusters in Raw2Cluster #67

Closed
makortel opened this issue May 30, 2018 · 3 comments
Closed

Improve the transfers of DIGIs and clusters in Raw2Cluster #67

makortel opened this issue May 30, 2018 · 3 comments

Comments

@makortel
Copy link

Digis

After #62 the DIGIS+errors are still always transferred back to CPU. In the pixel tracking workflow they are not used, so it should be straightforward do make their transfer on-demand. Basically this requires moving the transfers

cudaCheck(cudaMemcpyAsync(pdigi_h, pdigi_d, wordCounter*sizeof(uint32_t), cudaMemcpyDefault, stream.id()));
cudaCheck(cudaMemcpyAsync(rawIdArr_h, rawIdArr_d, wordCounter*sizeof(uint32_t), cudaMemcpyDefault, stream.id()));
if (includeErrors) {
cudaCheck(cudaMemcpyAsync(error_h, error_d, vsize, cudaMemcpyDefault, stream.id()));
cudaStreamSynchronize(stream.id());
error_h->set_data(data_h);
int size = error_h->size();
cudaCheck(cudaMemcpyAsync(data_h, data_d, size*esize, cudaMemcpyDefault, stream.id()));
}
// End of Raw2Digi and passing data for cluserisation

from the kernel to the "transfer function"
void SiPixelRawToClusterHeterogeneous::convertGPUtoCPU(const SiPixelRawToClusterHeterogeneous::GPUProduct& gpu,
SiPixelRawToClusterHeterogeneous::CPUProduct& cpu) const {

On a longer term (going beyond the quadruplet pixel tracks), the error information will likely become useful, so one could think of splitting the DIGIs and the errors to two separate HeterogeneousProducts (with the cost of them having different product labels...).

Clusters

The clusters, on the other hand, are needed in the CPU for various reasons (RecHits need to make edm::Refs, MC matching relies on clusters etc). After #62 the CPU clusters are first put as part of HeterogeneousProduct, and then copied to a standard edmNew::DetSetVector<SiPixelCluster> by SiPixelClusterHeterogeneousConverter. Since the standard collection is needed anyway, it would be more optimal to produce it directly already by SiPixelRawToClusterHeterogeneous. (this will then lead to a funny situation of module siPixelDigis taking siPixelCluters as an input, but ok)

@cmsbot
Copy link

cmsbot commented May 30, 2018

A new Issue was created by @makortel Matti Kortelainen.

can you please review it and eventually sign/assign? Thanks.

cms-bot commands are listed here

@makortel
Copy link
Author

@felicepantaleo @VinInn

@makortel
Copy link
Author

With the approach of #100 this issue would get fixed automatically.

fwyzard pushed a commit that referenced this issue Feb 12, 2021
* Update Settings.h

* Update TrackletCalculatorDisplaced.cc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants