From 9a9af2c67bfb49832dcf9091241b69bfd112b78d Mon Sep 17 00:00:00 2001 From: Chirag Jain Date: Wed, 17 Jan 2024 07:20:52 +0000 Subject: [PATCH] Add a launcher option for notebook --- .jp_app_launcher/config.yaml | 8 ++++++++ Dockerfile-notebook | 6 +++--- assets/truefoundry-logo.svg | 15 +++++++++++++++ notebook-requirements.txt | 3 +++ 4 files changed, 29 insertions(+), 3 deletions(-) create mode 100644 .jp_app_launcher/config.yaml create mode 100644 assets/truefoundry-logo.svg create mode 100644 notebook-requirements.txt diff --git a/.jp_app_launcher/config.yaml b/.jp_app_launcher/config.yaml new file mode 100644 index 0000000..a416fde --- /dev/null +++ b/.jp_app_launcher/config.yaml @@ -0,0 +1,8 @@ +- title: Finetuning Notebook + description: Launch Truefoundry LLM Finetuning Notebook + icon: /home/jovyan/llm-finetune/assets/truefoundry-logo.svg + source: /llm-finetune/finetune.ipynb + type: notebook + cwd: /home/jovyan/llm-finetune/ + catalog: Notebook + copy: false \ No newline at end of file diff --git a/Dockerfile-notebook b/Dockerfile-notebook index a1e7014..06c49f0 100644 --- a/Dockerfile-notebook +++ b/Dockerfile-notebook @@ -11,9 +11,9 @@ RUN sudo add-apt-repository ppa:flexiondotorg/nvtop -y && \ apt update && \ apt install -y --no-install-recommends cuda-toolkit-11-8 USER jovyan - -COPY requirements.txt post-pytorch-requirements.txt /tmp_home/jovyan/llm-finetune/ +COPY requirements.txt notebook-requirements.txt post-pytorch-requirements.txt /tmp_home/jovyan/llm-finetune/ RUN pip install -U pip wheel setuptools && \ - pip install --no-cache-dir -U -r /tmp_home/jovyan/llm-finetune/requirements.txt jupyter_server_proxy==4.1.0 && \ + pip install --no-cache-dir -U -r /tmp_home/jovyan/llm-finetune/notebook-requirements.txt && \ pip install --no-cache-dir --no-build-isolation -U -r /tmp_home/jovyan/llm-finetune/post-pytorch-requirements.txt +ENV JUPYTER_APP_LAUNCHER_PATH=/home/jovyan/llm-finetune/.jp_app_launcher/ COPY . /tmp_home/jovyan/llm-finetune/ diff --git a/assets/truefoundry-logo.svg b/assets/truefoundry-logo.svg new file mode 100644 index 0000000..2bdde55 --- /dev/null +++ b/assets/truefoundry-logo.svg @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/notebook-requirements.txt b/notebook-requirements.txt new file mode 100644 index 0000000..9a73569 --- /dev/null +++ b/notebook-requirements.txt @@ -0,0 +1,3 @@ +-r requirements.txt +jupyter-server-proxy==4.1.0 +jupyter_app_launcher @ git+https://github.com/truefoundry/jupyter_app_launcher@9a959b894542995fc763ed07324bbd274e96610d \ No newline at end of file