pulse2percept
pulse2percept copied to clipboard
[REF] Refactor Data/Stimulus/Percept
Stimulus and Percept both derive from Data, but currently Percept is underdeveloped w.r.t. Stimulus.
It would be useful for Percept to:
- allow for time axis interpolation (important for animating/storing percepts with uneven time step)
- allow for smart indexing (important for data manipulation)
- be created from an image, video, or file generated by an earlier
percept.save()call (improves usability)
The easiest way to support some of these is to move code from Stimulus to the underlying Data container.
In addition, there is an opportunity to refactor Percept into components that depend on space, time, or spacetime. For example, calling percept.plot() on a spatial percept should show an image, but on a temporal percept should show a line plot depicting how brightness evolves over time. A similar argument can be made for percept.play() and percept.save()