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
refactor TRD digit class #5221
refactor TRD digit class #5221
Conversation
bazinski
commented
Jan 18, 2021
- Convert digits to store rob/mcm and not pad/row.
- The interface for pad row remains so code wont change.
- For shared pads the lower indexed mcm is returned. It is the users responsibility to check if its shared if needed for their purposes.
- The plan was to move digit to DataFormats, but there is a circular library, so postponed to later.
724d202
to
8cb4252
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the indicator for the shared pads is buggy and should be fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am happy with the Digit class changes.
Just a minor style comment: I prefer to read ROB instead of Rob, as in the Tracklet class (mROB
, getROB
, setROB
), to make the code more consistent and easier to browse.
8996a79
to
d51dbeb
Compare
@shahor02 shot for seeing, now fixed. |
53deaae
to
58692a2
Compare
void setROB(int row, int pad) { mROB = FeeParam::getROBfromPad(row, pad); } | ||
void setMCM(int mcm) { mMCM = mcm; } | ||
void setMCM(int row, int pad) { mMCM = FeeParam::getMCMfromPad(row, pad); } | ||
void setChannel(int channel) { mChannel = channel; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these setters actually used? I would expect that we always know at construction which pad these digits refer to.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I prefer keeping them for completeness; they are harmless.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added one or two more comments, but I think we can commit as it is.
@tdietel let me change the rob value to uint8_t that will have somewhat of an impact on the sizing of the output, assuming it does not get padded. |
@tdietel regarding the set methods, i dont use them, they are simply there for completeness. |
29112a6
to
62a7c80
Compare
It will be padded |
@shahor02 when you get a chance could you approve the change as per your request and merge? |