Preprocessing functions¶
- ionworkspipeline.data_fits.preprocess.pulse_data_to_ocp(pulse_data_in, ocp_file_out=None, method='explicit', include_first_point=True)¶
Extract the open-circuit potential (OCP) from data from a pulse test (e.g. GITT or HPPC test)
Parameters¶
- pulse_data_instr or pd.DataFrame
The pulse test data to use. Can be a string giving the path to the data, or a DataFrame containing the data.
- ocp_file_outstr, optional
The file to write the OCP data to. If not provided, the data is not written.
- methodstr, optional
The method to use to extract the OCP. Can be “explicit” (default) or “extrapolation”. If “explicit”, the OCP is taken to be the voltage at the last data point of each cycle. If “extrapolation”, the OCP is calculated by extrapolating the voltage to its asymptote, to account for the relaxation being incomplete at the end of the cycle. Only “explicit” is currently implemented.
- include_first_pointbool, optional
Whether to include the first point of the data. Shouuld be True if the first point is after a sufficiently long rest period (i.e. the voltage of the first point is the open-circuit voltage), and False otherwise.
Returns¶
- pd.DataFrame
A dataframe containing the OCP data.
- ionworkspipeline.data_fits.preprocess.sort_capacity_and_ocp(data)¶
For OCP data, make sure that the capacity is always increasing and the voltage is always decreasing
Parameters¶
- data:
pd.DataFrame
Pandas dataframe containing the data, should include one column with the voltage and one column with the capacity
- data: