can anybody give me a brief description of these default folders created for each profile on TLJH.(I have hosted TLJH on an EC2 server). Can I clear the .cache/ folder periodically in order to free up disk space?
-
.cache - can be wiped. this is a default cache folder for a lot of programs. i would not blindly wipe everything, get to know the content of the folder and what might be worth deleting. often you can use command line arguments to delete the cache of a program i.e.
pip cache purge
-
.config - similar to /etc or .local/etc, stores config files for various programs
-
.ipynb_checkpoint - these hold previous versions of your files, which you could restore. if you want to clean all ipynb folders for a user, run this from home directory:
rm -rf `find -type d -name .ipynb_checkpoints`
-
.ipython - saves ipython history db, startup folder, log, metakernel history.
-
.jupyter - config files, workspaces of jupyter and it’s extensions.
-
.local - do not delete around in there if you do not know what you are doing. you might break stuff you do not want to break. .local/share/Trash can be wiped without consequences though
Thanks, can you also explain the .conda/ folder it has some contents as follows:
no, i don’t use conda.
still, unless you want to experiment with the chance to break your conda environment(s), i’d not delete stuff from there manually.
just searching the official documentation lists a clean command:
https://docs.conda.io/projects/conda/en/latest/commands/clean.html
maybe that -p helps shrinking the pkgs folder.
envs
and pkgs
generally contain the same files, and usage can be misreported because most files in envs
are “hard links” to files in pkgs
, which can get counted twice or even more times if you have more than one env. You can clean out unused files with conda clean -pity
.
I just found that huggingface-cli delete-cache
will delete, selectively, from ~/.cache/huggingface.