Skip to main content

Clean and add extra information to data produced by the battery cyclers from Novonix.

Project description

Documentation Status zenodo

Prepare Novonix Data

This code handles common issues encountered in files generated with a range of Novonix software versions and it can add extra information. There is a master function prepare_novonix that can run at once all the available features, providing also flexibility to only choose some.

The code can be used to test if a file has the expected structure for a Novonix file (isnovoix function) and to read a specific column from a raw Novonix file (read_column function). Files can be cleanned from empty lines and characters added after the ‘]’ in the header and failed tests are handled by modifying the capacity column to start at the sum of the capacities from the failed tests, instead of 0 (cleannovonix function).

The extra information that can be created for cleaned files (functions: novonix_add_state and novonix_add_loopnr) is:

  • A ‘State’ column with 0 for the first measurement of a particular step, 1 for regular data points, 2 to indicate the last measurement in that series and -1 for single measurements.

  • A reduced protocol with one command per numerated line.

  • A ‘Protocol line’ column that makes reference to the reduced protocol lines.

  • A ‘Loop number’ column with 0s when commands are not repeated and monotoncally increasing integers starting from 1, to indicate the repetition number.

Requirements

This code has been developed in Python 3.7.1 and tested from Matlab and within PowerShell and ConEmu BashShell in Windows 10.

Example

The example.py runs over the given example data. To run this example, simply type: python example.py.

Running this code from MatLab

In your code add the ‘pycode’ folder to your search path:

addpath(genpath('pycode'))

Try to run the code catching exceptions:

try
       py.pycode.novonix_add.prepare_novonix(file_to_open,pyargs('verbose','False','lprotocol','True'));
catch e e.message if(isa(e,'matlab.exception.PyException'))
       e.ExceptionObject
end

Ensure that Matlab can see your installation of Python by running pyversion. If Matlab cannot see python, once you know where your Python executable is (within a python terminal you can do this by typing: import os, sys ; os.path.dirname(sys.executable)), type within your MatLab interpreter pyversion [path to python executable] and check that now the path to Python was recognised with pyversion.

Compatibility

This code has been tested with data generated by different versions of the Novonix software. If you encounter issues running the code for any version of Novonix software report an issue. Note that an example file will be needed in order to improve the code. List of the Novonix software. If you encounter issues running the code for any version of Novonix software report an issue. Note that an example file will be needed in order to improve the code. List of the Novonix software versions the code has been tested against:

  • 3.0.2.3

  • 3.0.2.1

  • TO

  • 2.0.0.7

  • 1.9.4.0

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

preparenovonix-0.0.1.tar.gz (10.8 kB view hashes)

Uploaded Source

Built Distribution

preparenovonix-0.0.1-py3-none-any.whl (12.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page