فهرست منبع

gin commit from nit-ope-de04

New files: 7
Modified files: 1
Deleted files: 7
Julia Sprenger 1 سال پیش
والد
کامیت
a3f41215c0

+ 7 - 7
nix/generate_nix_testfiles.py

@@ -5,18 +5,16 @@ import quantities as pq
 
 n_segments = 2
 n_spiketrains = 8
+n_waveform_samples = 10
 n_analogsignals = 4
 n_irregularlysampledsignals = 1
 n_events = 2
 n_epochs = 3
 
+random_generator = np.random.default_rng(seed=42)
+
 def get_rand(shape=None, min=0, max=1, sorted=False):
-    if shape is None:
-        data = np.random.rand()
-    elif hasattr(shape, '__iter__'):
-        data = np.random.rand(*shape)
-    else:
-        data = np.random.rand(shape)
+    data = random_generator.random(shape)
 
     #rescaling random numbers to min-max range
     data = data*(max-min) + min
@@ -31,8 +29,10 @@ def generate_basic_block():
         block.segments.append(seg)
 
         for spiketrain_idx in range(n_spiketrains):
+            waveforms = get_rand((10, 14)) * pq.V
             st = neo.SpikeTrain(times=get_rand((10), max=10, sorted=True)*pq.s, t_stop=10*pq.s,
-                                name=f'my_spiketrain_{spiketrain_idx}')
+                                name=f'my_spiketrain_{spiketrain_idx}', waveforms=waveforms,
+                                left_sweep=4)
             st.segment = seg
             seg.spiketrains.append(st)
 

+ 1 - 0
nix/generated_file_neo0.10.2.nix

@@ -0,0 +1 @@
+/annex/objects/MD5E-s1119453--45857426b8e2b205e338cfe73e09762e.2.nix

+ 1 - 0
nix/generated_file_neo0.11.1.nix

@@ -0,0 +1 @@
+/annex/objects/MD5E-s1119453--3b0f622a24ecf2851ec3f9dde3b415b8.1.nix

+ 1 - 0
nix/generated_file_neo0.12.0.nix

@@ -0,0 +1 @@
+/annex/objects/MD5E-s1119453--36f38c60b197d61c8f8724baadec6b6c.0.nix

+ 1 - 0
nix/generated_file_neo0.6.1.nix

@@ -0,0 +1 @@
+/annex/objects/MD5E-s3047297--378d8210e9d2501af386a7cee3da78ce.1.nix

+ 1 - 0
nix/generated_file_neo0.7.2.nix

@@ -0,0 +1 @@
+/annex/objects/MD5E-s1174027--be685e9636e87e956cf6afa2affa8847.2.nix

+ 1 - 0
nix/generated_file_neo0.8.0.nix

@@ -0,0 +1 @@
+/annex/objects/MD5E-s1174027--c41806652188730b8cf181b1b880669c.0.nix

+ 1 - 0
nix/generated_file_neo0.9.0.nix

@@ -0,0 +1 @@
+/annex/objects/MD5E-s1119453--ff2521c0c75325a688bfa1b5621e2bdf.0.nix

+ 0 - 1
nix/generated_file_neo_0.10.2.nix

@@ -1 +0,0 @@
-../.git/annex/objects/x6/qZ/MD5E-s925371--23f5dd2c79fc67d5886881ce50ac313b.2.nix/MD5E-s925371--23f5dd2c79fc67d5886881ce50ac313b.2.nix

+ 0 - 1
nix/generated_file_neo_0.11.1.nix

@@ -1 +0,0 @@
-../.git/annex/objects/q9/qz/MD5E-s925371--1e439ac0ba8006667d9eda32afd77f42.1.nix/MD5E-s925371--1e439ac0ba8006667d9eda32afd77f42.1.nix

+ 0 - 1
nix/generated_file_neo_0.12.0.nix

@@ -1 +0,0 @@
-../.git/annex/objects/1k/4X/MD5E-s925371--68cbe2c16ff5c9bf878411c88a38271a.0.nix/MD5E-s925371--68cbe2c16ff5c9bf878411c88a38271a.0.nix

+ 0 - 1
nix/generated_file_neo_0.6.1.nix

@@ -1 +0,0 @@
-../.git/annex/objects/Jk/3V/MD5E-s2688871--cd9e2ba5ced4eedcd2c0be04c5f9c083.1.nix/MD5E-s2688871--cd9e2ba5ced4eedcd2c0be04c5f9c083.1.nix

+ 0 - 1
nix/generated_file_neo_0.7.2.nix

@@ -1 +0,0 @@
-../.git/annex/objects/99/fV/MD5E-s983355--e3337eae19ca20a86543ec28b5a2126c.2.nix/MD5E-s983355--e3337eae19ca20a86543ec28b5a2126c.2.nix

+ 0 - 1
nix/generated_file_neo_0.8.0.nix

@@ -1 +0,0 @@
-../.git/annex/objects/81/jg/MD5E-s983355--18777aebfc3d18bc12ad3222e418a81c.0.nix/MD5E-s983355--18777aebfc3d18bc12ad3222e418a81c.0.nix

+ 0 - 1
nix/generated_file_neo_0.9.0.nix

@@ -1 +0,0 @@
-../.git/annex/objects/8x/Xq/MD5E-s925371--61fa926e97f38c9c4d7fef5701b51fe0.0.nix/MD5E-s925371--61fa926e97f38c9c4d7fef5701b51fe0.0.nix