{ "cells": [ { "cell_type": "markdown", "id": "cccf7fdb-d8bf-4281-a21d-dbe88d28a6a2", "metadata": {}, "source": [ "# Checking Sign Conventions\n", "The sign convention for current varies between sources of battery data.\n", "Some define \"charging\" as positive whereas for others charging is negative current.\n", "The ``SignConventionChecker`` class checks whether our sign choice in the battery-data-toolkit, \"charging current is postive,\" is followed." ] }, { "cell_type": "code", "execution_count": 1, "id": "e07d0f83-d2e5-4306-9a56-22e4843b8148", "metadata": {}, "outputs": [], "source": [ "%matplotlib inline\n", "from matplotlib import pyplot as plt\n", "from battdat.consistency.current import SignConventionChecker\n", "from battdat.data import CellDataset\n", "from datetime import datetime, timedelta" ] }, { "cell_type": "markdown", "id": "82db7e17-6866-4855-a492-e545cf081fd5", "metadata": {}, "source": [ "## Load Example Data\n", "We have two simple cells that vary only by the where the \"cycle\" starts." ] }, { "cell_type": "code", "execution_count": 2, "id": "a27a6598-7836-4705-81fb-e05fc8aad24c", "metadata": {}, "outputs": [], "source": [ "from battdat.io.batterydata import BDReader\n", "dataset = BDReader().read_dataset(['../../../tests/files/batterydata/p492-13-raw.csv'])" ] }, { "cell_type": "markdown", "id": "4c2d1e16-ead3-4e51-b84b-0e27d42fbae4", "metadata": {}, "source": [ "## Voltage Should Increase During Charge\n", "The core concept behind our sign convention is that the voltage for a battery should increase while it is charging: an principle that is true for many types of batteries.\n", "\n", "The algorithm for checking a dataset is consistent with this principle is conceptually simple:\n", "1. Find a point where the current is the most constant\n", "2. Measure the slope between voltage and time.\n", "3. Make sure the slope and the current have the same sign (if voltage 📈, current ➕)\n", "\n", "There are, however, a few nuances to the actual implementation." ] }, { "cell_type": "markdown", "id": "41f5741a-d426-48d2-b48f-7f9f2746fbcf", "metadata": {}, "source": [ "### Step 1: Finding a Region of Stable Current\n", "Time spans with stable current are where the standard deviation of current is small.\n", "The checker finds the most-stable region using Panda's windowing function.\n", "\n", "Start by converting the \"test_time\" column in data to a Python time object so that Pandas can compute windows corresponding to a specific time span." ] }, { "cell_type": "code", "execution_count": 3, "id": "36048ad5-16ca-4f37-a50e-73822fc9668f", "metadata": {}, "outputs": [], "source": [ "raw_data = dataset.raw_data.query('test_time < 8000').copy() # Get a subset of the timesteries\n", "raw_data['timestamp'] = raw_data['test_time'].apply(datetime.fromtimestamp)" ] }, { "cell_type": "markdown", "id": "1a4a6cc5-bbd2-463a-9853-f7076b682d26", "metadata": {}, "source": [ "A window of 6 minutes is short enough to find nearly-constant spans of current\n", "and long enough that transient fluctuations in voltage should have a minimal expect.\n", "> NOTE: The window size is an adjustable parameter in `SignConventionChecker`" ] }, { "cell_type": "code", "execution_count": 4, "id": "daf33c9b-b6d1-4349-ae28-009e03cc1b13", "metadata": {}, "outputs": [], "source": [ "current_std = raw_data.rolling(timedelta(seconds=360), on='timestamp')['current'].std()" ] }, { "cell_type": "code", "execution_count": 5, "id": "6476de44-835c-48f7-9294-2c881b8bcac8", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "Text(0.5, 0, 'Time (s)')" ] }, "execution_count": 5, "metadata": {}, "output_type": "execute_result" }, { "data": { "image/png": "iVBORw0KGgoAAAANSUhEUgAAAUAAAADMCAYAAAAClXq9AAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAAogUlEQVR4nO3df1xUVf4/8NfMwAwgMqj8GFBQTFbLX6gEUm72SVYqstzcSh9GaP7YTE3StbRN/W7l4tq6W5rp1sN03UzU3XLXH9myaKmFICAYupLlD1h1MCVmBJEfc9/fP4a5cJ0Zfsgdhpl5Px9NA/eee+eckXnPOfece46CiAiMMeaBlM7OAGOMOQsHQMaYx+IAyBjzWBwAGWMeiwMgY8xjcQBkjHksDoCMMY/FAZAx5rE4ADLGPBYHQMaYx/LqjBdZv3493n77bej1egwfPhzr1q1DXFyc3fS7du3CsmXLcOHCBURHR+MPf/gDHn30UXE/EWHFihX48M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0/iwoULOHjwoLi/uLgYffr0QVBQkMPKw+TDAZC5vblz56KiogJTpkzB8ePH8cMPP+CLL77A9OnTYTKZbB4THByMkSNHSpYS3bt3L9auXYvCwkJcvHgRW7duhSAIGDhwoJjmyJEjGD9+vMPLxOTBAZC5vfDwcHz99dcwmUwYP348hg4dirS0NAQGBlqtXtbczJkzsW3bNvH3wMBAfPrpp3jooYdw9913Y+PGjdi+fTsGDx4MALh16xZ2796NWbNmObxMTB48EJoxO2pqajBw4EDs2LGjTUtibtiwAZ999hn+/e9/d0LumBy4BsiYHb6+vti6dWuLA6ab8/b2xrp16xycKyYnrgEyxjwW1wAZYx6LAyBjzGNxAGSMeSwOgIwxj8UBkDHmsTgAMsY8FgdAxpjH4gDIGPNYHAAZYx7r/wMbdLDT8Y7v0AAAAABJRU5ErkJggg==", "text/plain": [ "
" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "fig, ax = plt.subplots(figsize=(3., 1.8))\n", "\n", "ax.plot(raw_data['test_time'], raw_data['current'], label='$I$ (A)')\n", "ax.plot(raw_data['test_time'], current_std, label='$\\\\sigma_I$ (A)')\n", "\n", "ax.legend()\n", "ax.set_xlabel('Time (s)')" ] }, { "cell_type": "markdown", "id": "588b6054-f534-44f0-b0bc-296e45a9716d", "metadata": {}, "source": [ "There are plenty of regions of stable current in this data and some where the current is nonzero." ] }, { "cell_type": "code", "execution_count": 6, "id": "720475c2-b5d2-4f89-9c69-dfe036bdcbdb", "metadata": {}, "outputs": [], "source": [ "window = raw_data.query('1000 < test_time < 2000')" ] }, { "cell_type": "code", "execution_count": 7, "id": "229f0e66-58b1-4260-b7bb-8f41fbb43a29", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
cycle_numberstep_indextest_timecurrentvoltagetemperaturetimetimestamp
16051052.958-0.000953.18341329.84541.578067e+091969-12-31 19:17:32.958
17051252.962-0.000953.16617129.87761.578067e+091969-12-31 19:20:52.962
18051452.960-0.000953.14816529.89371.578067e+091969-12-31 19:24:12.960
19051652.958-0.000953.12909129.84541.578067e+091969-12-31 19:27:32.958
20051852.962-0.000953.10925529.82931.578068e+091969-12-31 19:30:52.962
\n", "
" ], "text/plain": [ " cycle_number step_index test_time current voltage temperature \\\n", "16 0 5 1052.958 -0.00095 3.183413 29.8454 \n", "17 0 5 1252.962 -0.00095 3.166171 29.8776 \n", "18 0 5 1452.960 -0.00095 3.148165 29.8937 \n", "19 0 5 1652.958 -0.00095 3.129091 29.8454 \n", "20 0 5 1852.962 -0.00095 3.109255 29.8293 \n", "\n", " time timestamp \n", "16 1.578067e+09 1969-12-31 19:17:32.958 \n", "17 1.578067e+09 1969-12-31 19:20:52.962 \n", "18 1.578067e+09 1969-12-31 19:24:12.960 \n", "19 1.578067e+09 1969-12-31 19:27:32.958 \n", "20 1.578068e+09 1969-12-31 19:30:52.962 " ] }, "execution_count": 7, "metadata": {}, "output_type": "execute_result" } ], "source": [ "window" ] }, { "cell_type": "markdown", "id": "93623621-e53e-4b4b-b754-c0fd1c6b2577", "metadata": {}, "source": [ "## Step 2: Compute the slope between voltage and time\n", "The [slope between two variables is proportional to the covariance](https://en.wikipedia.org/wiki/Simple_linear_regression#Relationship_with_the_sample_covariance_matrix), which can also be computed for a rolling window" ] }, { "cell_type": "code", "execution_count": 8, "id": "d12c05f3-939d-4127-bc73-0a166c6a151d", "metadata": {}, "outputs": [], "source": [ "cov = raw_data.rolling(timedelta(seconds=360), on='timestamp')['voltage'].cov(raw_data['test_time'])" ] }, { "cell_type": "code", "execution_count": 9, "id": "8018b6b4-2a35-4ea3-bf4f-cbb6228315f9", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "Text(0.5, 24.0, 'Time (s)')" ] }, "execution_count": 9, "metadata": {}, "output_type": "execute_result" }, { "data": { "image/png": "iVBORw0KGgoAAAANSUhEUgAAAUYAAADkCAYAAADkdI2hAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAABACklEQVR4nO3deVyU1f4H8M8szAz7vi+KgICyKIiIW5a4Z3lzz9JbZmaalpZJi/0sDbe8dtWrWQa3W0qpZWaKKYpL4QKKgCCCoiCryDLDNjPMc35/DDM5bLLMCuf9ej0vZebMc75nXvL1PM9ZHhYhhICiKIpSYus6AIqiKH1DEyNFUVQzNDFSFEU1QxMjRVFUMzQxUhRFNUMTI0VRVDM0MVIURTXD1XUAhoZhGBQVFcHc3BwsFkvX4VAU9RhCCEQiEVxcXMBmd73fRxNjJxUVFcHd3V3XYVAU1Y6CggK4ubl1+fM0MXaSubk5APkXb2Fh0Wa5GnEj6sSNMOVzYcqnXzNFaYNQKIS7u7vy97Sr6G9sJykuny0sLNpNjMu+vYLztx8iyM0SR5eN1FZ4FEUB3b7NRQdfNKSqTgIASHtQjeR7FTqOhqKoztDLxLh7924EBQUpe2URERE4ceJEm+W//vprjBo1CtbW1rC2tkZkZCSuXLmiUuaf//wnWCyWyjFx4kSNtSHS31H59/8k3oGwQaqxuiiKUi+9TIxubm7YuHEjUlJSkJycjGeeeQbPP/88bt682Wr5xMREzJ07F2fPnkVSUhLc3d0xfvx4FBYWqpSbOHEiiouLlceBAwc01oblY31w6I0IAMCZW2UYsyUR3yXdg1TGaKxOiqLUg2Uo247Z2Nhgy5YtWLhw4RPLymQyWFtbY+fOnZg/fz4AeY+xqq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dVVOV3n559/JnZ2dmT16tV61yaaGDVkx44dxMPDg/B4PDJ06FBy6dIlXYdECCFtPjwoJiZGWaa+vp68+eabxNrampiYmJB//OMfpLi4WOU89+7dI5MmTSLGxsbEzs6OrFq1ikilUpUyZ8+eJYMGDSI8Ho/069dPpQ5Nap4YDbU9v/32GwkICCB8Pp/4+fmRvXv3qrzPMAz5+OOPiaOjI+Hz+WTs2LEkOztbpcyjR4/I3LlziZmZGbGwsCCvvPIKEYlEKmVu3LhBRo4cSfh8PnF1dSUbN27USHuEQiFZsWIF8fDwIAKBgPTr1498+OGHKtNq9KVNdD9GiqKoZug9RoqiqGZoYqQoimqGJkaKoqhmaGKkKIpqhiZGiqKoZmhipCiKaoYmRoqiqGZoYqQoimqGJkaKoqhmaGKkKIpqhiZGiqKoZv4fmoC69y2wto4AAAAASUVORK5CYII=", "text/plain": [ "
" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "fig, axs = plt.subplots(3, 1, figsize=(3., 2.4), sharex=True)\n", "\n", "axs[0].plot(raw_data['test_time'], raw_data['voltage'])\n", "axs[0].set_ylabel('$V$ (V)')\n", "\n", "axs[1].plot(raw_data['test_time'], raw_data['current'] * 1000)\n", "axs[1].set_ylabel('$I$ (mA)')\n", "\n", "axs[2].plot(raw_data['test_time'], cov)\n", "axs[2].set_ylabel('$\\\\sigma_{V,t}$ (mA)')\n", "\n", "ax.legend()\n", "ax.set_xlabel('Time (s)')" ] }, { "cell_type": "markdown", "id": "29d76761-a20c-4c25-8373-c5745b9c8d64", "metadata": {}, "source": [ "Note how the covariance between voltage and time ($\\sigma_{V,t}$) has the same sign as the current for the regions where the data are the same." ] }, { "cell_type": "markdown", "id": "72d35f64-e5bb-45f9-8eb9-00562a6998e5", "metadata": {}, "source": [ "## Step 3: Compare signs\n", "The ``SignConventionChecker`` does these two previous steps and compares the outcome" ] }, { "cell_type": "code", "execution_count": 10, "id": "1c26dc07-2569-40e0-bff1-592eb466d1a7", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "[]" ] }, "execution_count": 10, "metadata": {}, "output_type": "execute_result" } ], "source": [ "chckr = SignConventionChecker()\n", "chckr.check(dataset)" ] }, { "cell_type": "markdown", "id": "d8f4388b-dafc-40a9-b6aa-8a560655ad82", "metadata": {}, "source": [ "No errors for this dataset. ✅\n", "\n", "If we change the sign, the checker will notice and report why the data are wrong" ] }, { "cell_type": "code", "execution_count": 11, "id": "752d930d-b86a-48d1-bc63-2d3b36bc8349", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "['Potential sign error in current. Average current between test_time=299170.4s and test_time=299530.4 is 9.5e-03 A and the covariance between the voltage and current is -1.5e+00 V-s. The current and this covariance should have the same sign.']" ] }, "execution_count": 11, "metadata": {}, "output_type": "execute_result" } ], "source": [ "dataset.raw_data['current'] *= -1\n", "chckr.check(dataset)" ] }, { "cell_type": "code", "execution_count": null, "id": "e01cebe7-d216-4221-9427-e64b360db101", "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.10.15" } }, "nbformat": 4, "nbformat_minor": 5 }