Skip to content
Snippets Groups Projects

TRD2D Unpacker in cbm::algo.

Merged Dominik Smith requested to merge d.smith/cbmroot:Trd2dUnpackAlgo into master

Implemented cbm::algo::UnpackTrd2d and related classes.

Correctness was verified on first timeslice of 2391_node8_0_0008.tsa with caveats, see below.

@v.friese @a.bercuci

Edit: Rebased to include changes from !1169 (merged)

Edited by Dominik Smith

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Dominik Smith requested review from @v.friese

    requested review from @v.friese

  • assigned to @v.friese

  • Dominik Smith changed the description

    changed the description

    • Author Maintainer
      Resolved by Dominik Smith

      @a.bercuci @v.friese

      This MR supplies a port of CbmTrdUnpackFaspAlgo to cbm::algo. The initialization of the parameters is wrapped in CbmTaskUnpack::InitTrd2dReadoutConfig(), where a set of input parameters corresponding to run 2391 are currently hardcoded.

      This means, that the "crob_map" (which maps the pair (crobId, moduleID) to the equipment ID) from run_unpack_tsa.C is currently hard-coded, as well as the setup specific files, which are trd_v22h_mcbm.digi.par and trd_v22h_mcbm.asic.par.

      The output of the new implementation was verified against the original one. The MR is marked as draft, as it differs from the original one in two ways, which need to be discussed:

      1. The original unpacker contains a map fFaspMap which is used in a statement of the form: if (fFaspMap) fasp_id = ((*fFaspMap)[mod_id])[fasp_id];. So it basically reshuffles the ASIC IDs within one module. In the class header, this has a comment "FASP mapping update wrt the default setting". Presumably, this is remapping is something that can be absorbed into the parameter files. It is not clear to me whether or not we should support this in cbm::algo. Perhaps @a.bercuci can comment.

      2. The unpacker includes a function FinalizeComponent(), which in the original version is called for each "timeslice component" at the end of the "microslice loop". Therein, any remaining digis in the buffers are processed. This implies, that a certain number of partially completed digis are carried over from microslice to microslice withing each component. This is a problem, as the current paradigm of cbm::algo is that unpacking should be parallelizable across "microslice components" (not "timeslice component"), i.e. each microslice within each component should in principle be independent. In this MR, FinalizeComponent() is hence called once for each "microslice component", and indeed, this leads to a certain (small) number of digis being lost. So, some feedback from @v.friese and @a.bercuci is required, how to proceed here. In principle, it is, in the present implementation, not so hard to move the finalization to the end of the MS loop (thereby sacrificing this part of the parallelizability).

      Also, the "crob_map" ((crobId, moduleID) -> equipID)) which is hard-coded here only contains one module ID (=5). This isn't a problem, but moduleIDs are also separately supplied by the .digi file, and there is nothing in principle preventing these two definitions from contradicting. Here we catch such cases explicitly, but one might ask whether this situation can somehow be cleaned up in the future.

  • Dominik Smith
  • Author Maintainer

    @v.friese GitLab will not let me designate @a.bercuci as the reviewer.

  • Author Maintainer

    Also: the copyright headers probably need to be updated.

  • Dominik Smith added 1 commit

    added 1 commit

    • 23054b69 - Implemented cbm::algo::UnpackTrd2d.

    Compare with previous version

  • Dominik Smith added 1 commit

    added 1 commit

    • 3d2104d3 - CbmTaskUnpack: Implemented TRD2D FASP remapping.

    Compare with previous version

  • Dominik Smith added 1 commit

    added 1 commit

    • 627efd84 - CbmTaskUnpack: Implemented TRD2D FASP remapping. Cleanup.

    Compare with previous version

  • Dominik Smith marked this merge request as ready

    marked this merge request as ready

  • Dominik Smith added 1 commit

    added 1 commit

    • 30a8ea40 - CbmTaskUnpack: Implemented TRD2D FASP remapping. Cleanup. Fixed copyright headers.

    Compare with previous version

  • Dear @f.uhlig, @v.friese, @p.-a.loizeau,

    you have been identified as code owner of at least one file which was changed with this merge request.

    Please check the changes and approve them or request changes.

  • Dominik Smith added 24 commits

    added 24 commits

    • 30a8ea40...c0bd88f9 - 21 commits from branch computing:master
    • 1456e126 - Added print() functions to monitoring structs of cbm::algo unpackers.
    • 57eb4253 - Implemented cbm::algo::UnpackTrd2d.
    • fb23aeac - CbmTaskUnpack: Implemented TRD2D FASP remapping. Cleanup. Fixed copyright headers.

    Compare with previous version

  • Author Maintainer

    @v.friese Can we merge this? Or should I implement a version where FinalizeComponent() is moved to the end of the MS loop (hence breaking MS parallelizability)?

  • Dominik Smith changed the description

    changed the description

  • Dominik Smith added 1 commit

    added 1 commit

    • 19eb2f40 - UnpackTrd2d: Added monitoring print() function.

    Compare with previous version

  • Dominik Smith added 4 commits

    added 4 commits

    • 3d818b39 - Updated monitoring structs off cbm::algo unpackers.
    • e2267f7f - Implemented cbm::algo::UnpackTrd2d.
    • 01e0fcda - CbmTaskUnpack: Implemented TRD2D FASP remapping. Cleanup. Fixed copyright headers.
    • 3071fce1 - UnpackTrd2d: Added monitoring print() function.

    Compare with previous version

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading