From 2724e2a8332d1e39e55c1d42c5e33d8b8fadfbad Mon Sep 17 00:00:00 2001 From: Chris Kerr Date: Sun, 8 Dec 2013 13:36:45 +0000 Subject: [PATCH] Changed data reading to handle the newer file format --- BioLogic.py | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/BioLogic.py b/BioLogic.py index 2388ad8..e1c102b 100644 --- a/BioLogic.py +++ b/BioLogic.py @@ -205,9 +205,31 @@ class MPRfile: data_module, = (m for m in modules if m['shortname'] == b'VMP data ') log_module, = (m for m in modules if m['shortname'] == b'VMP LOG ') - ## There is 100 bytes of data before the main array starts - self.data = np.frombuffer(data_module['data'], dtype=VMPdata_dtype, - offset=100) + n_data_points = np.fromstring(data_module['data'][:4], dtype='