BlackrockNeurotech / Python-Utilities

A collection of scripts for loading and manipulating Blackrock Microsystems datafiles.
27 stars 16 forks source link

Spliting substes of time of a Ns3 file #28

Open G00Z-G00Z opened 1 year ago

G00Z-G00Z commented 1 year ago

Hello! I have a problem splitting the ns3 files.

So in my application, we are running some trials at specific time interfvals. However, we do not turn off the sensor when we are making the trials

For example:

  1. We turn on the sensor
t Action Duration
t=0 Take trial one 10secs
t=10 wait 40secs
t=50 Take trial two 10secs
t=60 Take trial three 10secs
t=70 wait 5secs
t=75 Take trial four 10secs
  1. Turn off the sensor

This produces a very large .nsx & .nev files due to the wait times. Using the python utilities, I already have the exact intervals of trials. However, we'd like to save subsets of nsxfiles with the specific time lenght of the trials:

E.g:

The Nsx api allows to save subsets of time, but not specific intervals of time.

Is there a way to save a specific interval of time? Also, another alternative using the subsets would be to create smaller substes and then combine them to generate the interval I need...

Thanks for your time