-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbasic_full_pipeline.py
More file actions
54 lines (51 loc) · 1.84 KB
/
basic_full_pipeline.py
File metadata and controls
54 lines (51 loc) · 1.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
from auditory_model.src.modules.neurons.izhikevich import MultiChannelIzhikevichModel
from auditory_model.src.modules.neurons.spike_detection import SpikeThresholding
from auditory_model.src.modules.plots.plot_raw_signal import PlotRawSignal
from auditory_model.src.modules.plots.psth import HistogramPlotter
from auditory_model.src.modules.preprocess import PreprocessLoadAudioLibrosa
from auditory_model.src.modules.neurons.normalize_audio import NormalizeAudioToVoltage
from auditory_model.src.modules.utils.aggregation import AggregatePerChannel
from auditory_model.src.modules.utils.sample_generator import SampleRunGenerator
from auditory_model.src.modules.utils.split_into_loop import ProcessSequenceItems
from auditory_model.src.runner import Config
"""
Config(
audio_file="sounds/pure_440.wav",
run_name="Izhikevich Neuron Model loop",
pipeline=[
PreprocessLoadAudioLibrosa(take_only_first_x_ms=200),
NormalizeAudioToVoltage(max_voltage_in_mV=30),
SampleRunGenerator(
sub_modules=[
MultiChannelIzhikevichModel(),
]
),
AggregatePerChannel(),
SplitIntoLoop(
stop=1,
sub_modules=[
HistogramPlotter.psth(),
],
),
],
).run()
"""
Config(
audio_file="sounds/pure_440.wav",
run_name="Izhikevich Neuron Model loop",
pipeline=[
PreprocessLoadAudioLibrosa(),
PlotRawSignal(),
NormalizeAudioToVoltage(max_voltage_in_mV=30),
PlotRawSignal(file_name="Mili wolt.png"),
SampleRunGenerator(
sub_modules=[
MultiChannelIzhikevichModel(),
SpikeThresholding(),
],
n_samples=500,
),
AggregatePerChannel(),
ProcessSequenceItems(sub_modules=[HistogramPlotter.psth()]),
],
).run()