From 00e6670b4ab9723d4cd955d9d9855529ac5750dc Mon Sep 17 00:00:00 2001 From: Chris Kerr Date: Wed, 11 Dec 2013 12:50:45 +0000 Subject: [PATCH] Added I/mA column type = 8 Also there seems to be a duplicate of colID=23 is the same as 7 (dq/mAh) --- BioLogic.py | 9 ++++++--- tests/test_BioLogic.py | 22 +++++++++++++++++++--- 2 files changed, 25 insertions(+), 6 deletions(-) diff --git a/BioLogic.py b/BioLogic.py index 2f62c9d..4a402f3 100644 --- a/BioLogic.py +++ b/BioLogic.py @@ -9,6 +9,7 @@ from os import SEEK_SET, SEEK_CUR import time from datetime import date from collections import OrderedDict +from warnings import warn import numpy as np @@ -74,8 +75,7 @@ def MPTfile(file_or_path): "counter inc.", "time/s", "control/V", "Ewe/V", "/mA", "dQ/mA.h", "P/W"]) if fieldnames not in expected_fieldnames: - raise ValueError("Unrecognised headers for MPT file format %s" % - fieldnames) + warn("Unrecognised headers for MPT file format %s" % fieldnames) record_type = np.dtype(list(map(fieldname_to_dtype, fieldnames))) @@ -150,8 +150,11 @@ def VMPdata_dtype_from_colIDs(colIDs): dtype_dict['control/V/mA'] = '