sinabs
sinabs copied to clipboard
Make it easy to record events from hardware
Currently it is not straightforward to record data from hardware (either from the vision sensor or layer outputs) without providing any input.
For example, if I just want to record data from the speck sensor for a given duration, I would not know how to do this with sinabs-dynapcnn (without writing lower-level samna code).
There is a way that is probably not documented, nor tested:
- Instantiate a
DynapcnnNetworkwith a sequential that only contains aDVSLayer. - Deploy that network onto chip with the
tomethod, passingmonitor_layers = ["dvs"] - To record, call the
forwardmethod of theDynapcnnNetworkinstance. As argument pass a list with one single dummy event that has as timestamp the desired recording duration (in microseconds). - The return value will be a list of all events recorded from the DVS within the specified duration.
This issue could probably be solved by adding proper documentation to the procedure above and a unit test that ensures it works.
Good place to add to the docs: https://sinabs.readthedocs.io/en/v2.0.0/speck/the_basics.html