Skip to content

Instantly share code, notes, and snippets.

@mbadros
Created August 10, 2023 01:12
Show Gist options
  • Select an option

  • Save mbadros/83e78f6c1fe4494e09bcf808a248b64c to your computer and use it in GitHub Desktop.

Select an option

Save mbadros/83e78f6c1fe4494e09bcf808a248b64c to your computer and use it in GitHub Desktop.
!ls
import subprocess, sys
!pip install {library}
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'pkg_name'])
from IPython.core.interactiveshell import InteractiveShell
InteractiveShell.ast_node_interactivity = "all"
%load_ext autoreload
%autoreload 2
pd.set_option('display.max_columns', None)
pd.set_option('display.max_rows', 500)
pd.set_option('display.width', 1000)
%%timeit -n 10
# timeit magic has to be the first; n is the number of cycles
%run _<name of Python script>_
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment