summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorMario Mulansky <mario.mulansky@gmx.net>2015-07-07 18:55:32 +0200
committerMario Mulansky <mario.mulansky@gmx.net>2015-07-07 18:55:32 +0200
commit5119d47d0f00c3f7203cf94460730b59a7e473ec (patch)
treef17eecd4d2cb7da865b6fe4a1b4faf268ab77334 /examples
parent0ece782e1579660cdb71e077cbaaf9f76e97bef4 (diff)
add disable_backend_warning property
Users can now disable the warning messages produced when the cython backend is not available by writing spk.disable_backend_warning = True in the beginning
Diffstat (limited to 'examples')
-rw-r--r--examples/performance.py3
-rw-r--r--examples/plot.py1
2 files changed, 4 insertions, 0 deletions
diff --git a/examples/performance.py b/examples/performance.py
index 1c31e8f..d0c3b91 100644
--- a/examples/performance.py
+++ b/examples/performance.py
@@ -14,6 +14,9 @@ from datetime import datetime
import cProfile
import pstats
+# in case you dont have the cython backends, disable the warnings as follows:
+# spk.disable_backend_warning = True
+
M = 100 # number of spike trains
r = 1.0 # rate of Poisson spike times
T = 1E3 # length of spike trains
diff --git a/examples/plot.py b/examples/plot.py
index c44afd1..1922939 100644
--- a/examples/plot.py
+++ b/examples/plot.py
@@ -16,6 +16,7 @@ import matplotlib.pyplot as plt
import pyspike as spk
+
spike_trains = spk.load_spike_trains_from_txt("PySpike_testdata.txt",
edges=(0, 4000))