Skip to content

PWGCF: Update lambdaR2Correlation.cxx - #6829

Merged
victor-gonzalez merged 4 commits into
AliceO2Group:masterfrom
yashpatley:lambdacorr-update
Jul 13, 2024
Merged

PWGCF: Update lambdaR2Correlation.cxx#6829
victor-gonzalez merged 4 commits into
AliceO2Group:masterfrom
yashpatley:lambdacorr-update

Conversation

@yashpatley

Copy link
Copy Markdown
Contributor

Some major changes made in this PR are as follows,

  1. Replaced the pseudo-rapidity and rapidity column in table producer task with only one variable based on type of analysis.
  2. Added the lambda selection in the table producer task itself.
  3. Added analyzeSingles and analyzePairs method in the correlation task.

Rest of the changes can be inferred from the code itself.

Comment on lines +303 to +333
case kPion:
if (track.hasTOF()) {
if (fabs(track.tofNSigmaPi()) < cfg_tof_nsigma) {
selTOFv0type = true;
}
if (fabs(track.tpcNSigmaPi()) < cfg_tpc_nsigma) {
selTPCv0type = true;
}
} else {
selTOFv0type = true;
if (fabs(track.tpcNSigmaPi()) < cfg_tpc_nsigma) {
selTPCv0type = true;
}
}
break;

case kProton:
if (track.hasTOF()) {
if (fabs(track.tofNSigmaPr()) < cfg_tof_nsigma) {
selTOFv0type = true;
}
if (fabs(track.tpcNSigmaPr()) < cfg_tpc_nsigma) {
selTPCv0type = true;
}
} else {
selTOFv0type = true;
if (fabs(track.tpcNSigmaPr()) < cfg_tpc_nsigma) {
selTPCv0type = true;
}
}
break;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Please don't move back to replicate code
I suggested to store the TOF and TPC nsigma at the beginning of the routine because that is the only differentiated treatment you have to do for the different species. After that everything is the same
Have it in mind for the next iteration

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes I agree, I repeated the replication. I have changed this now.

@alibuild

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/o2 for dd7972d at 2024-07-11 18:53:

## sw/BUILD/O2Physics-latest/log
/sw/SOURCES/O2Physics/6829-slc7_x86-64/0/PWGCF/TwoParticleCorrelations/Tasks/lambdaR2Correlation.cxx:624:83: error: unused parameter 'lambdas' [-Werror=unused-parameter]
ninja: build stopped: subcommand failed.

Full log here.

Comment on lines +478 to +483
selV0Particle<kLambda, kProton, kPion, kCentralWindow>(collision, v0, postrack, negtrack, tracks);
selV0Particle<kLambda, kProton, kPion, kLeftWindow>(collision, v0, postrack, negtrack, tracks);
selV0Particle<kLambda, kProton, kPion, kRightWindow>(collision, v0, postrack, negtrack, tracks);
selV0Particle<kAntiLambda, kPion, kProton, kCentralWindow>(collision, v0, postrack, negtrack, tracks);
selV0Particle<kAntiLambda, kPion, kProton, kLeftWindow>(collision, v0, postrack, negtrack, tracks);
selV0Particle<kAntiLambda, kPion, kProton, kRightWindow>(collision, v0, postrack, negtrack, tracks);

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

In here for the same v0 each of the possibilities is tried although only one will succeed (I guess they are mutually exclusive)
For the next iteration I would suggest simplify this a bit. Most probably the extraction of the invariant mass window should be immediate
Also, as the tracks table is passed it is not needed to additionally pass postrack and `negtrack

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Dear @victor-gonzalez, I am sorry but I didn't get the first part of this comment. Could you please elaborate ?

@alibuild

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/o2 for 6c30f4f at 2024-07-11 18:58:

## sw/BUILD/O2Physics-latest/log
/sw/SOURCES/O2Physics/6829-slc7_x86-64/0/PWGCF/TwoParticleCorrelations/Tasks/lambdaR2Correlation.cxx:624:83: error: unused parameter 'lambdas' [-Werror=unused-parameter]
ninja: build stopped: subcommand failed.

Full log here.

@victor-gonzalez victor-gonzalez left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for addressing my comments
I've put a few more for your consideration in the next iteration

@victor-gonzalez

Copy link
Copy Markdown
Collaborator

And, yes, you have to fix your code warnings that now are treated as errors
See https://mattermost.web.cern.ch/alice/pl/pha7ccshitf8jn1pai3ewwn7pr announcement by Vit today

@yashpatley yashpatley closed this Jul 12, 2024
@yashpatley
yashpatley deleted the lambdacorr-update branch July 12, 2024 06:21
@yashpatley
yashpatley restored the lambdacorr-update branch July 12, 2024 06:21
Comment on lines +416 to +418
if (!selPIDTrack<pos_prong>(postrack) || !selPIDTrack<neg_prong>(negtrack)) {
return;
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This will allow to say if it is a Lambda, antiLambda, or something else, right? So it should be first

Comment on lines +440 to +445
if (mass > mass_map_min[masswin] && mass < mass_map_max[masswin]) {
if (masswin == kCentralWindow) {
fillQALambda<v0part>(collision, v0track, tracks);
}
lambdaTrackTable(lambdaCollisionTable.lastIndex(), v0track.pt(), rap, v0track.phi(), mass, postrack.index(), negtrack.index(), v0part, masswin);
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

A loop on the three mass windows with a break when found will allow to get the proper mass window

Comment on lines +468 to +473
selV0Particle<kLambda, kProton, kPion, kCentralWindow>(collision, v0, tracks);
selV0Particle<kLambda, kProton, kPion, kLeftWindow>(collision, v0, tracks);
selV0Particle<kLambda, kProton, kPion, kRightWindow>(collision, v0, tracks);
selV0Particle<kAntiLambda, kPion, kProton, kCentralWindow>(collision, v0, tracks);
selV0Particle<kAntiLambda, kPion, kProton, kLeftWindow>(collision, v0, tracks);
selV0Particle<kAntiLambda, kPion, kProton, kRightWindow>(collision, v0, tracks);

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Why it is needed to do the six combinations if only one will be valid?
Check my comments on the routine

@victor-gonzalez victor-gonzalez left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for considering my comment
Have a look at the new ones if you want to consider them for the next iteration

@victor-gonzalez
victor-gonzalez merged commit 7b46536 into AliceO2Group:master Jul 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants