microsoft / yardl

Tooling for streaming instrument data
https://microsoft.github.io/yardl/
MIT License
30 stars 5 forks source link

Add RelativeTime? #67

Open KrisThielemans opened 1 year ago

KrisThielemans commented 1 year ago

It seems useful to have a RelativeTime, i.e. offset w.r.t. some defined DateTime, such as a scan start. This would be quite useful in de-identifying some data. In some cases, the time of scan needs to be removed from the data, but it'd be painful to have to adjust all times in the file.

johnstairs commented 1 year ago

Are you thinking a RelativeTime is linked (via pointer) to a specific DateTime? Or standalone like Python's timedelta?

KrisThielemans commented 1 year ago

I think standalone would be best. You could have a lot of RelativeTime entries (e.g. a vector). If they all need to link to a DateTime, that'd be a ton of overhead. Which DateTime it is relative to would then be part of the semantics of the model described by the yardl file.