AllenNeuralDynamics / AllenNeuralDynamics/aind-dynamic-foraging-bfm-wrapper

Planning: FIP data loader

Offen
#38 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
Python
Sterne
0
Forks
1
Ø Merge
4 Std. 5 Min.
Gemergte PRs (30 T.)
24

Beschreibung

I'm starting to fit the disrnn models with FIP data inputs. This will require either a new data loader, or modification of the mice data loader. This is a place to record some planning notes

### Requirements
I need to specify the following information in the hydra model

For each input feature:
- Which fiber (0-3)
- Which channel (G, R, Iso)
- Which processing method (many possible)
- What time window (eg, 0-2s) around what time event (eg, goCue). This may involve prev/current choice indexing.

### First pass implementation
I added a new data loader that builds the FIP dataframe, z-scores the channels, and gets the average signal window

```python
fiber = 0
channel = 'G'
method='dff-bright_mc-iso-IRLS'
full_channel_name = f'{channel}_{fiber}_{method}'

nwb.df_fip = nu.create_df_fip(nwb,verbose=False)
nwb.df_fip = ed.zscore_fip(nwb.df_fip)
nwb.df_trials = tm.get_average_signal_window(
nwb,
alignment_event='goCue_start_time_in_session',
offsets = [0,2],
channel=full_channel_name,
data_column = 'data_z',
output_col='NE_FIP'
)
```

### Details to work out
- How to deal with NaNs, or missing values? It looks like one session has a single NaN. Its not clear where this is coming from. For now, I'm just filling it in with a 0 (z-scored data). But we should have a more robust checking and filling method

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.