Created
September 9, 2020 03:28
-
-
Save YiLi225/be3a024727e228c15d42a4e72ab3a27d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Caveat: (2) columns with unique values | |
dairy_table['Food'].memory_usage(index=False, deep=True) | |
Out[120]: 1605 | |
## Convert to category, | |
dairy_table['Food'].astype('category').memory_usage(index=False, deep=True) | |
Out[121]: 2262 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment