Reproducing stimulation in Multimodal Characterization in Mouse Visual Cortex

Apologies if I have not been able to search hard enough but I have not been able to figure out exactly how to reproduce the current wave forms from the ephys characterization of the 4k neurons from their NWB files.

There are four types of stimuli I believe

[‘long_squares’, ‘short_squares’, ‘ramps’]

I think these correspond to 1 second, and 3ms, and 1 second?
Within long squares there are a variety of parameters that I assume determine the properties of stimulation, but I am not sure how to interpret them:

‘sweeps’, ‘v_baseline’, ‘rheobase_i’, ‘rheobase_sweep’, ‘spiking_sweeps’, ‘fi_fit_slope’, …

Is there code available to take a nwb dataset from the original study and reproduce the injected current waveform?

I am hoping to fit a GLM predicting spikes from current.

A related question, is there a resource that defines that variety of cell characterizations in the NWB file, for example from one recording, I don’t know for certain what many of these dictionary entries refer to.

{'avg_rate': 2.0000000000000004,
 'peak_deflect': (15.000001, 52034),
 'stim_amp': 150.0,
 'v_baseline': -71.72601318359375,
 'sag': -13.157281875610352,
 'adapt': nan,
 'latency': 0.020240000000000036,
 'isi_cv': 0.0,
 'mean_isi': 0.022179999999999866,
 'median_isi': 0.022179999999999866,
 'first_isi': 0.022179999999999866,
 'index': 34,
 'spikes': [{'threshold_index': 52012,
   'clipped': False,
   'threshold_t': 0.52024,
   'threshold_v': -35.5,
   'threshold_i': 150.0,
   'peak_index': 52034,
   'peak_t': 0.52068,
   'peak_v': 15.000000953674316,
   'peak_i': 150.0,
   'trough_index': 52080,
   'trough_t': 0.5216000000000001,
   'trough_v': -58.812503814697266,
   'trough_i': 150.0,
   'slow_trough_v': nan,
   'slow_trough_i': nan,
   'width': 0.0005800000000000249,
   'upstroke_downstroke_ratio': 1.0035529324670005}],
 'sweep_number': 50}

The types of stimulus protocols you mention (long squares, short squares, and ramps) are the three core stimulus protocols used in that data set.

The cell features you mention, however, are not directly related to the properties of the stimulus - those are features of the cell’s intrinsic properties, which are described in things like the electrophysiology white paper for the Cell Types Database.

The stimulus currents themselves are available in the NWB files. For example, if you use the IPFX software package to access the NWB files, you can get a Sweep object from a data set. It has an “i” (current) property that contains the time series of the current used as the stimulus for that sweep.