epic-open-source / seismometer

AI model evaluation with a focus on healthcare
https://epic-open-source.github.io/seismometer/
BSD 3-Clause "New" or "Revised" License
156 stars 15 forks source link

Expectations for events frame are not apparent #40

Open diehlbw opened 4 days ago

diehlbw commented 4 days ago

Problem Summary

With the ability to set up data from preloaded frames instead of going through a full load pipeline, there are gaps in expectations.

Specifically, when loading events from file, we can do a post load transform step to set up for merging into a single predictions frame. However when loading from in-memory frames we expect that the are completely ready to go. This means if a Seismogram session is being initiated from separate preloaded event and prediction data they default merging may not work because those post load steps (such as mapping of columns) may not have occured.

Impact

Error using setup with preloaded events data, and uninformative "KeyError"

Possible Solution

Catch the key errors in the default event.post_transform_fn and provide more information.
Possibly still best to raise the error, but provide info directing users toward the expectation columns are already renamed (Time, Type, Value)