Package qubx :: Package fast :: Module data
[hide private]
[frames] | no frames]

Module data

source code

Compiled routines for sampled data.

Copyright 2008-2011 Research Foundation State University of New York This file is part of QUB Express.

QUB Express is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

QUB Express is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License, named LICENSE.txt, in the QUB Express program directory. If not, see <http://www.gnu.org/licenses/>.

Classes [hide private]
  DoseResponse_Equil
Very important to feed data chunks in reverse order.
  DoseResponse_Peak
Feed whole segments please.
  IdlStim
Idealizes a stimulus signal.
  Idl_AdaptiveResample
Idealizes a stimulus signal.
  IdlStats
  MeanRSS
Functions [hide private]
 
raster_samples(w, samples, samples_per_pixel, resolution)
Returns (lows, highs, gauss_lows, gauss_highs); arrays of at most w y-coords; each pixel represents several samples; the arrays give the minimum, maximum, and mean +/- one std.
source code
 
adaptive_resample(samples, max_std)
Divides samples into intervals such that all(stds[i] < max_std).
source code
 
decode_acquirefile_samples(src_8, src_16, src_16s, dest, size, count) source code
 
mean_rss(data) source code
Variables [hide private]
  __package__ = 'qubx.fast'
Function Details [hide private]

raster_samples(w, samples, samples_per_pixel, resolution)

source code 

Returns (lows, highs, gauss_lows, gauss_highs); arrays of at most w y-coords; each pixel represents several samples; the arrays give the minimum, maximum, and mean +/- one std.

Parameters:
  • resolution - min difference between highs[i] and lows[i]

adaptive_resample(samples, max_std)

source code 

Divides samples into intervals such that all(stds[i] < max_std). Also finds the closest sample to the mean in each interval.

Parameters:
  • samples - numpy.array(float32) of sampled data
  • max_std - desired ceiling for all stds[i]
Returns:
(means, stds, firsts, lasts, closests) -- array[interval_index]