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

Tutorial confusion regarding trapTmax #48

Open
Jita22 opened this issue Jan 23, 2024 · 0 comments
Open

Tutorial confusion regarding trapTmax #48

Jita22 opened this issue Jan 23, 2024 · 0 comments
Labels
documentation Improvements or additions to documentation

Comments

@Jita22
Copy link

Jita22 commented Jan 23, 2024

Was digging around for the definition of trapTmax. The tutorial seems to have a nice illustration with the processor

        "trapTmax": {
            "function": "argmax",
            "module": "numpy",
            "args": ["wf_trap", 1, "trapTmax"],
            "kwargs": {"signature": "(n),()->()", "types": ["fi->i"]},
            "unit": "ns",
        }

that indicates that it should a time (note that it has units of ns). The attached image in the documentation also seems to show a vertical blue line that presumably corresponding to a time.

HOWEVER, digging through the config files in legend-dataflow-config (which now have short descriptions of the parameters), it is clear that trapTmax is the max of a fixed length long trap filter and should correspond to an uncalibrated energy. Here is the relevant section from a config file

    "trapTmax": {
      "description": "max of fixed length long trap filter",
      "function": "amax",
      "module": "numpy",
      "args": [
        "wf_trap[round(2*db.ttrap.rise+db.ttrap.flat, wf_pz.period):-round((2*db.ttrap.rise+db.ttrap.flat), wf_pz.period)]",
        1,
        "trapTmax"
      ],
      "kwargs": { "signature": "(n),()->()", "types": ["fi->f"] },
      "defaults": { "db.ttrap.rise": "10*us", "db.ttrap.flat": "3.008*us" },
      "unit": "ADC"
    }

Could we make the tutorial definition consistent with the processor being used for production?
Screen Shot 2024-01-23 at 3 34 12 PM

@gipert gipert added the documentation Improvements or additions to documentation label Mar 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants