-
Notifications
You must be signed in to change notification settings - Fork 270
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
DataWriter should not write pointing info from each event #1562
Comments
A simple solution would be to implement a event_source = EventSource(input_url)
pointing_source = PointingSource(input_url)
writer = DL1Writer(output_file)
for event in source:
pointing_source(event)
proces(event)
for pointing in pointing_source:
writer.write_pointing(pointing) |
yeah, this was discussed in a few past Issues as well. see #1041 and the diagram here: #1165 (comment) |
I opened another one because this is partciluar about pointing and the "hack" we currently do in the DataWriter. For LST, this has the result of storing pointing info for every event although it would be sufficient to store the drive report values with a resolution of 2s. |
But right now, the DL1 writer does not write per-event pointing, I think, so it should be ok. Yes, the idea was to write drive reports ever few seconds, or even the average of them for real data. |
Because for LST real data the pointing (altaz, tracking ra/dec) is different for each event, it is written for every event. |
It depends a bit on the design: if we have event-wise (or at least rapidly updated pointing info), we could create a general You could add that as a sub-component of DL1Writer, e.g. That would be useful for other things we might want to reduce from Event → Monitoring stream. Basically having two components: a
|
For the lst data, that wouldn't make too much sense since the values come from the drive report with 2 s resolution, so it would make much more sense to just store these data values. |
Yes, even easier then, and no special code needed. So the question is how to write something at a different rate than the Event stream, when the writing happens in an event loop. Options:
I guess this is only a problem if you want to write DL1 data from LST1, which won't be a problem when DL0 is defined. DL1Writer would then do what it does now, and just copy the pointing from DL0. |
I'm a bit confused though: you said:
but also:
Which is it? I would separate pointing corrections from drive reports as well. I'd guess you only need:
From which you can generate per-event pointing on the fly. Also, a question: what data are include in pointing data?
|
Both actually. It writes the current measured zen/az and the nominal (not measured) ra/dec. |
I think all of this comes down to mixing a few things.
So the problem is not just writing back out what the drive reports give, that is DL0 - here we need a step that goes from DL0 → DL1, and puts the pointing in a common place. No RA/Dec is needed, only Alt/Az, by the way. So I would imagine we need containers for DL1 Event-wise and Monitored pointing info, and they should have at least fields of ( If you are implemeting an event source that goes from R0 → DL1 completely, you would need some conversion of the internal LST pointing into to this format, and we need a general tool to interpolate to event time. |
Anyhow, I think this requires a meeting and discussion offline, since it is a general and larger problem and already has several issues related to it. Adding a |
Exactly and this is why I opened this issue. We should implement another way to write the pointing info for simtel files so it does not mess with this. |
This was fixed in #2438 |
The
DataWriter
should not try to reconstruct the monitoring info by looking into unique pointings.Rather, it should have a
write_pointing
method, that gets the info that should be written.This requires a common way to store the monitoring info however.
The text was updated successfully, but these errors were encountered: