Skip to main content

Open and process battery charger log data files: fork of original package `galvani`

Project description

galvani

[!NOTE]
This repository is an approximate mirror of https://codeberg.org/echemdata/galvani (originally developed at https://github.com/echemdata/galvani), though the syncing is not automatic. Versions deployed to PyPI package from this repository as the datalab-org-galvani-mirror may not match those of the galvani package itself. Documentation may still contain out of date references to the original repository. It is unlikely new features will be developed in this mirror, changes will only involve build system, deployment and testing improvements, so please direct your development attention to the codeberg repo linked above.

Read proprietary file formats from electrochemical test stations.

Usage

Bio-Logic .mpr files

Use the MPRfile class from BioLogic.py (exported in the main package)

from galvani import BioLogic
import pandas as pd

mpr_file = BioLogic.MPRfile('test.mpr')
df = pd.DataFrame(mpr_file.data)

Arbin .res files

Use the ./galvani/res2sqlite.py script to convert the .res file to a sqlite3 database with the same schema, which can then be interrogated with external tools or directly in Python. For example, to extract the data into a pandas DataFrame (will need to be installed separately):

import sqlite3
import pandas as pd
from galvani.res2sqlite import convert_arbin_to_sqlite
convert_arbin_to_sqlite("input.res", "output.sqlite")
with sqlite3.connect("output.sqlite") as db:
    df = pd.read_sql(sql="select * from Channel_Normal_Table", con=db)

This functionality requires MDBTools to be installed on the local system.

Installation

The latest galvani releases can be installed from PyPI via

pip install datalab-org-galvani

The latest development version can be installed with pip directly from GitHub (see note about git-lfs below):

GIT_LFS_SKIP_SMUDGE=1 pip install git+https://github.com/datalab-org/galvani-mirror

Development installation and contributing

[!WARNING]

This project uses Git Large File Storage (LFS) to store its test files, however the LFS quota provided by GitHub is frequently exceeded. This means that anyone cloning the repository with LFS installed will get failures unless they set the GIT_LFS_SKIP_SMUDGE=1 environment variable when cloning. The full test data from the last release can always be obtained by downloading the GitHub release archives (tar or zip), at https://github.com/datalab-org/galvani-mirror/releases/latest

If you wish to add test files, please ensure they are as small as possible, and take care that your tests work locally without the need for the LFS files. Ideally, you could commit them to your fork when making a PR, and then they can be converted to LFS files as part of the review.

If you wish to contribute to galvani, please clone the repository and install the testing dependencies:

git clone git@github.com:datalab-org/galvani-mirror
cd galvani
pip install -e .\[tests\]

Code can be contributed back via GitHub pull requests and new features or bugs can be discussed in the issue tracker. It may also be useful to check the original issue tracker for galvani.

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

datalab_org_galvani-0.5.3.tar.gz (56.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

datalab_org_galvani-0.5.3-py3-none-any.whl (27.4 kB view details)

Uploaded Python 3

File details

Details for the file datalab_org_galvani-0.5.3.tar.gz.

File metadata

  • Download URL: datalab_org_galvani-0.5.3.tar.gz
  • Upload date:
  • Size: 56.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for datalab_org_galvani-0.5.3.tar.gz
Algorithm Hash digest
SHA256 ae9fb75aa157d2f7f6cf979e18dca7c12c73d5af79a02320c6e81691ceb9c89b
MD5 f5f13517b5b1a435406e9e1749e8a784
BLAKE2b-256 63616ea22ec32fe37ea757129d2d474e085b48c2872edbfcecbf4bc7ac5dc307

See more details on using hashes here.

Provenance

The following attestation bundles were made for datalab_org_galvani-0.5.3.tar.gz:

Publisher: release.yml on datalab-org/galvani-mirror

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file datalab_org_galvani-0.5.3-py3-none-any.whl.

File metadata

File hashes

Hashes for datalab_org_galvani-0.5.3-py3-none-any.whl
Algorithm Hash digest
SHA256 37c6541b38a9d130dc6f28a8d566122f4522ce1ade3b727d4db5e05747a3325d
MD5 535499ff999471f8a71a4351a44f5ece
BLAKE2b-256 4404c3e6cf75f6783d98f78d620df008cadb4225ddabd1c1ee65a7dfee24a23a

See more details on using hashes here.

Provenance

The following attestation bundles were made for datalab_org_galvani-0.5.3-py3-none-any.whl:

Publisher: release.yml on datalab-org/galvani-mirror

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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