A helpful script to optimize a Pandas DataFrame.
Project description
pd-helper
A helpful package to streamline Pandas DataFrame optimization.
Save 50-75% on DataFrame memory usage by running the optimizer.
Auto configure dtypes for appropriate data types in each column.
Basic Usage
Given a pandas dataframe, "df":
from pd_helper.helper import optmize
if __name__ == "__main__":
# guading function under module is necessary to run multiprocessing (save time).
# some DataFrame, df
df = optimize(df)
Install
pip install pd-helper
Sample Results
Starting with 175.63 MB memory.
After optmization.
Ending with 65.33 MB memory.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pd_helper-0.1.0.tar.gz
(5.8 kB
view hashes)
Built Distribution
Close
Hashes for pd_helper-0.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 35b04655a524c002985ce4dec21f5ad0c1c83d130346c8e1d81c60c8598e7d8c |
|
MD5 | f27b097b29dffb50a931c52d49683bbb |
|
BLAKE2b-256 | 0eb154f3c7355addeefbb861a1e2eae453b8e0eb2398b8280e6a0d28089563f8 |