r/electrochemistry • u/SwedenGoldenBridge • 23d ago
I am building Python library for reading electrochemical measurement files, need example files to add support
I am using AI-assist tool to read non-plain text electrochemical measurement files (e.g. Metrohm .nox, biologic .mpr, gamry .dta, etc). It is frustrating sometime to always use there software to export as csv or xlsx so I vibecoded this python library.
If your file is not supported, open an issue on github and attached example file (can be garbage data), to attached it, rename the file like this, examplle.mpr.txt.
https://github.com/kevinsmia1939/PyElectrochemReader
To install the library: pip install pyelectrochemreader
Here is the simplest way to use the library.
from pyelectrochemreader import read
import matplotlib.pyplot as plt
data = read("example/data/CV_C01.mpr")[0]
plt.plot(data["voltage"], data["current"])
plt.xlabel("Voltage (V)")
plt.ylabel("Current (A)")
plt.show()
2
u/dstark1993 23d ago
How different this is from other already available options? If you google read .mpr files / read biologic files there are at least two libraries I found (and use)...
1
u/q-vector 22d ago
Great, I will open an issue for 3T files
2
u/BTCbob 22d ago
I did something similar:
https://github.com/boblansdorp/electrochem
vibecoding rocks for this sort of stuff!