Converter¶
-
class
managers.operatorsSignaling.converter.Converter¶ Available methods:
Method name Method type determine_signalsign_from_threshold()static method voltage_to_spiketrain()class method NOTE:
determine_signalsign_from_thresholdreturns “+” or “-“voltage_to_spiketrainreturns array of times when spikes occured
-
static
determine_signalsign_from_threshold(thresh)¶ Returns signal sign “+” or “-” given a threshold number value.
-
classmethod
voltage_to_spiketrain(model, recordings)¶ Transforms voltage recordings into spikes.
Arguments:
Ordered argument Value type - model instance
instantiated model - response recording
dictionary NOTE:
- the model has the attribute ‘regions’
- recordings is a product after running the model
Use case:
First we set up as follows
>> sm = SimulationManager()>> rm = RecordManager()>> rec = {"time": None, "response": None, "stimulus": None}>> par = {"dt": 0.1, "celsius": 30, "tstop": 10, "v_init": 65}>> sm.prepare_model_NEURON(parameters=par, chosenmodel=chosenmodel)>> rec["time"], rec["response"], rec["stimulus"] = rm.prepare_recording_NEURON(chosenmodel)>> sm.engage_NEURON>> co = Converter()Then,
>> spikes = co.voltage_to_spiketrain(chosenmodel, rec)