import sys sys.exit()
aws configure --profile example ... export AWS_PROFILE=example
alpha = 0.1 ratio = 0.1
print(alpha) print(ratio)
papermill input.ipynb output.ipynb -p alpha 0.6 -p ratio 0.2
jupyter nbconvert --to html output.ipynb output.html
記事:
Input Notebook: notebook.ipynb Output Notebook: /tmp/out-notebook.ipynb Executing notebook with kernel: python3 Executing Cell 1--------------------------------------- Ending Cell 1------------------------------------------ ...
[msg != %^[\.\|\_]%]
環境:
エラー:
pip3 install jupyterlab jupyter lab ... ModuleNotFoundError: No module named '_sqlite3' ... ModuleNotFoundError: No module named 'pysqlite2'
修正:
sudo apt install libsqlite3-dev # 現在のpip moduleのlistを保存 pip freeze > requirements.txt # 現在のバージョン確認 pyenv versions ... * 3.11.4 ... ... # pythonを再インストール pyenv uninstall 3.11.4 pyenv install 3.11.4 python3 -V Python 3.11.4 # pip moduleを復元 pip3 install -r requirements.txt
pip3 install jupyterlab # 起動 jupyter lab
記事:
現象:
jupyter lab
修正:
jupyter lab --generate-config
--- jupyter_lab_config.py.bak 2025-04-18 16:55:20.356631429 +0900 +++ jupyter_lab_config.py 2025-04-18 16:59:28.026600944 +0900 @@ -777,6 +777,7 @@ # BROWSER environment variable to override it. # Default: '' # c.ServerApp.browser = '' +c.ServerApp.browser = '/mnt/c/Program\ Files/Google/Chrome/Application/chrome.exe %s' ## The full path to an SSL/TLS certificate file. # Default: '' @@ -1140,6 +1141,7 @@ # to launch by using a URL and visible token (as before). # Default: True # c.ServerApp.use_redirect_file = True +c.ServerApp.use_redirect_file = False