This is a sandbox repo for figuring out how to read axon binary files into python.
Installation: To use axonbinaryfile the python module you may need to fool around with where to put ABFFIO.dll so that the _abf.pyd dynamic module can load
- It has collection of materials from the internet to help with the process:
- code from stimfit
- matlab modules
- abffio library from Axon Instruments
As of April 2010, there are working python modules to read:
- ".abf" episodic stimulation files from pClamp9 and pClamp10 (from Axon) under windows it relies upon the dynamic library from axon, ABFFIO.dll, which must be findable
- It does the the job with episodic files.
- ABF has a complicated set of options/experiment types. For episodic files, could use ability to get the stimulus waveform, check to see if there are multpile sample rates and such.
- Needs work to support gap-free, event triggered.
If you stumble upon this repo, the code I write here is BSD or python licensed, feel free to use it, as usual there's no warantee.
The code from other people continues with their source licenses.
More Info: other libraries, notes
- matlababffiler http://sourceforge.net/projects/matlababffilere/
- Stimfit http://www.stimfit.org
- libaxon http://libaxon.sourceforge.net/
matlababffilere is based upon C++ code for reading axon instruments abf files versions 1 and 2 using the closed-source windows library released by the company. I used this as the template for my code when I was getting started
I started with abf2txt.exe in the matlab abf file reader project at sourceforge by bigryan (bigryan at users.sourceforge.net)
I made a branch of version 0-2-2 and did a little patching because there to fix some array access errors which I also submitted as a patch to the above sourceforge project.
The approach for abf2tmp is to convert the pClamp abf file into two text files, one with data and the other with the meta data from the file. Then in python I read these files and parse them into numpy arrays and such.
I'm learning the ABF file IO api as I go so the code is likely to be a bit ragged. I would next like to write a native python module or a ctypes module for access to the library directly from python.
Stimfit is a big project for analysis of electrophysiology files and it supports reading axon files. I've thrown copies of some of the code into this repo for further study. It also includes some Axon/Molecular Devices code.
libaxon is another project to read and write axon files with matlab and python bindings. Haven't looked at it much yet. Compiles on unix/mingw.
I am basing this first first on the Axon (now molecular devices) FSP-ABF2_0_1_4D (debug version) FSP-ABF2_0_1_4R (release version)
which appear to be from 2007-03-28