clear all python cache code example
Example 1: remove all pycache files
find . | grep -E "(__pycache__|\.pyc|\.pyo$)" | xargs rm -rf
Example 2: clear all python cache
find . | grep -E "(__pycache__|\.pyc|\.pyo$)" | xargs rm -rf
Example 3: python clear memory
a = 10
print a
del a
print a ## throws an error here because it's been deleted already.