Skip to content

Instantly share code, notes, and snippets.

@luminoso
Last active August 1, 2023 13:55
Show Gist options
  • Save luminoso/3e714879e970666481be148b8d5ef373 to your computer and use it in GitHub Desktop.
Save luminoso/3e714879e970666481be148b8d5ef373 to your computer and use it in GitHub Desktop.
base install jupyerlab datascience project
# CONDA
# create env
conda config --add channels conda-forge
conda config --set channel_priority strict
conda create --strict-channel-priority -n jupyter
conda activate jupyter
# jupyter, notebook and old notebook extensions
conda install -y jupyterlab
# https://github.com/jupyterlab/debugger
jupyter labextension install @jupyterlab/debugger
jupyter labextension enable @jupyterlab/debugger
# https://github.com/jupyter-widgets/ipywidgets
conda install -y ipywidgets
jupyter labextension install @jupyter-widgets/jupyterlab-manager
jupyter labextension enable @jupyter-widgets/jupyterlab-manager
# https://github.com/jupyterlab/jupyterlab-toc
jupyter labextension install @jupyterlab/toc
jupyter labextension enable @jupyterlab/toc
# https://github.com/wallneradam/jupyterlab-run-all-buttons#readme
# jupyter labextension install @wallneradam/run_all_buttons
# jupyter labextension enable run_all_buttons
# https://github.com/krassowski/jupyterlab-lsp
pip install jupyter-lsp
conda install -y nodejs
jupyter labextension install @krassowski/jupyterlab-lsp
conda install -y python-language-server
# https://jupyterlab-code-formatter.readthedocs.io/
conda install -c conda-forge -y jupyterlab_code_formatter
conda install -c conda-forge -y black
# jupyter serverextension enable --py jupyterlab_code_formatter
# jupyter labextension enable jupyterlab_code_formatter
# https://github.com/jupyterlab/jupyterlab-git
conda install -y jupyterlab-git
# https://github.com/deshaw/jupyterlab-execute-time
conda install -c conda-forge -y jupyterlab_execute_time
# datascience packages
# pip install -y pandas numpy scikit-learn scipy xlrd dill joblib
# pip install -y matplotlib tqdm swifter seaborn plotly
# create jupyter virtualenv
# https://www.linkedin.com/pulse/how-use-virtual-environment-inside-jupyter-lab-sina-khoshgoftar/
# https://gist.github.com/hughdbrown/a2f321458981043beeaa126db661a647
python -m venv .venv
source .venv/bin/activate
pip install ipykernel
ipython kernel install --user --name=test1
python -m ipykernel install --user --name=virtualenv
# list
jupyter kernelspec list
# delete
# jupyter kernelspec uninstall virtualenv
jupyter-lab --no-browser --NotebookApp.token='' --NotebookApp.password='' --NotebookApp.allow_origin='*' --NotebookApp.ip='0.0.0.0'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment