project8 / psyllid

Data acquisition package for the ROACH2 system
Other
0 stars 1 forks source link

Add indication of which frequency bin triggered in trigger_flag #81

Open nsoblath opened 6 years ago

nsoblath commented 6 years ago

Might have two trigger flag classes, one with frequency bin indication, one without.

cclaessens commented 6 years ago

We came to the conclusion that we want just one trigger flag class that has both a flag for "was there any bin above threshold in this record" and an array of booleans with true at the positions of these bins and false elsewhere.

cclaessens commented 6 years ago

to do:

nsoblath commented 6 years ago

@cclaessens can you remind me, did we specifically want the trigger flags as a bitset so that we can apply masks to it or other logical operations? Or did we not necessarily want that, in which case I could include the flag for each trigger along with the node type and threshold information.

cclaessens commented 6 years ago

I am not totally sure about what you mean by "each trigger". I think you mean each trigger-flag object (that nodes create for every record). Alternative interpretations would be: only trigger-flag object containing a flag set to true, or: every bin in the record that made it above threshold.

Anyway, I think that every trigger-flag needs to contain 3 position sensitive list-like objects. One for node-types, one for threshold information and one for the boolean flags. At least I don't know how we could otherwise make sure that all the information makes it to the triggered writer.

The or-nodes and the event-builder will receive several trigger-flag objects per record (/in_stream command) that they then have to combine to a single trigger-flag. In the end the triggered writer will only get one trigger-flag per record and that needs to contain all the information that goes into the egg- and record- headers.