code
stringlengths
3
6.57k
get_stdev(self)
data.append(spike.wave.data)
np.asarray(data)
std(axis=0)
get_weights(self, weighting=None, sstdev=None, tstdev=None)
len(self.wave.chans)
len(self.wave.data[0])
self.get_gaussian_spatial_weights(sstdev)
self.get_gaussian_temporal_weights(tstdev)
self.get_gaussian_spatial_weights(sstdev)
self.get_gaussian_temporal_weights(tstdev)
np.outer(sweights, tweights)
print('\nweights:\n%r' % weights)
get_gaussian_spatial_weights(self, stdev)
Gaussian(mean=0, stdev=stdev)
get_gaussian_temporal_weights(self, stdev)
Gaussian(mean=0, stdev=stdev)
PTCSHeader(object)
int64 (currently version 3)
uint64 (nbytes, keep as multiple of 8 for nice alignment)
text (padded with null bytes if needed for 8 byte alignment)
uint64 (number of neurons)
uint64 (total number of spikes)
uint64 (number of bytes per template waveform sample)
uint64 (Hz)
uint64 (nbytes, keep as multiple of 8 for nice alignment)
text (padded with null bytes if needed for 8 byte alignment)
uint64 (total num chans in polytrode)
float64 (array of (x, y)
uint64 (nbytes, keep as multiple of 8 for nice alignment)
lstrip(fullfname, os.path.expanduser('~')
os.path.join(sortpath, sortfname)
str(datetime.datetime.fromtimestamp(os.path.getmtime(sortfullfname)
sortfmoddt.split('.')
os.path.getsize(sortfullfname)
ptcs (polytrode clustered spikes)
str(d)
pad(descr, align=8)
pad(lstrip(stream.fname, '../')
pad(stream.probe.name, align=8)
pad(self.dt.isoformat()
write(self, f)
np.int64(self.FORMATVERSION)
tofile(f)
np.uint64(len(self.descr)
tofile(f)
f.write(self.descr)
np.uint64(self.nneurons)
tofile(f)
np.uint64(self.nspikes)
tofile(f)
np.uint64(self.nsamplebytes)
tofile(f)
np.uint64(s.sampfreq)
tofile(f)
np.uint64(len(self.pttype)
tofile(f)
f.write(self.pttype)
np.uint64(s.stream.probe.nchans)
tofile(f)
np.float64(s.stream.probe.siteloc_arr()
tofile(f)
np.uint64(len(self.srcfname)
tofile(f)
f.write(self.srcfname)
np.float64(td2days(self.dt - EPOCH)
tofile(f)
datetime (in days)
np.uint64(len(self.dtstr)
tofile(f)
f.write(self.dtstr)
PTCSNeuronRecord(object)
int64 (signed neuron id, could be -ve, could be non-contiguous with previous)
uint64 (nbytes, keep as multiple of 8 for nice alignment, defaults to 0)
text (padded with null bytes if needed for 8 byte alignment)
float64 (um)
float64 (um)
float64 (um)
uint64 (num chans in template waveforms)
uint64 (0 based IDs of channels in template waveforms)
uint64 (0 based ID of max channel in template waveforms)
uint64 (num timepoints per template waveform channel)
uint64 (nbytes, keep as multiple of 8 for nice alignment)
uint64 (nbytes, keep as multiple of 8 for nice alignment)
uint64 (number of spikes in this neuron)
uint64 (us, should be sorted)
__init__(self, neuron, spikets=None, nsamplebytes=None, descr='')
n.update_wave()
pad(self.wavedtype(AD2uV(n.wave.data)
pad(self.wavedtype(AD2uV(n.wave.std)
pad(descr, align=8)
write(self, f)
np.int64(n.id)
tofile(f)
np.uint64(len(self.descr)
tofile(f)
f.write(self.descr)
np.float64(np.nan)
tofile(f)
np.float64(n.cluster.pos['x0'])