diff --git a/.flake8 b/.flake8 deleted file mode 100644 index c4d72bc..0000000 --- a/.flake8 +++ /dev/null @@ -1,5 +0,0 @@ -[flake8] -extend-ignore = E203, F401, E402, E501, W503 -exclude = .git,__pycache__,.ipynb_checkpoints -max-line-length = 90 -max-complexity = 18 \ No newline at end of file diff --git a/.flake8_nb b/.flake8_nb deleted file mode 100644 index caee0d3..0000000 --- a/.flake8_nb +++ /dev/null @@ -1,5 +0,0 @@ -[flake8_nb] -extend-ignore = E203, F401, E402, E501 -exclude = .git,__pycache__,.ipynb_checkpoints -max-line-length = 90 -max-complexity = 18 \ No newline at end of file diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9ce3303..0a8827e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,9 +26,9 @@ jobs: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - pip install -e .[dev] - # python -m pip install uv - # uv pip install --system -e . + python -m pip install uv + uv pip install spacy --no-binary blis # do not compile blis from source + uv pip install -e .[dev] - name: Run pytest run: | cd ammico diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index b209794..81e609a 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -17,7 +17,8 @@ jobs: fetch-depth: 0 # otherwise, you will failed to push refs to dest repo - name: install ammico run: | - pip install -e .[dev] + python -m pip install uv + uv pip install -e .[dev] - name: set google auth uses: 'google-github-actions/auth@v0.4.0' with: diff --git a/Dockerfile b/Dockerfile index e922a1c..36f9c6d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,8 @@ FROM jupyter/base-notebook # Install system dependencies for computer vision packages USER root -RUN apt update && apt install -y build-essential libgl1 libglib2.0-0 libsm6 libxrender1 libxext6 +RUN apt update && apt install -y build-essential libgl1 libglib2.0-0 libsm6 libxext6 libxrender1 \ + && rm -rf /var/lib/apt/lists/* USER $NB_USER # Copy the repository into the container @@ -18,12 +19,5 @@ ENV JUPYTER_ENABLE_LAB=yes ENV XDG_DATA_HOME=/opt/ammico/data # Copy notebooks into the home directory -RUN rm -rf $HOME/work -RUN cp /opt/ammico/notebooks/*.ipynb $HOME - -ARG GOOGLE_CREDS -ENV GOOGLE_APPLICATION_CREDENTIALS=credentials.json -RUN echo ${GOOGLE_CREDS} > $GOOGLE_APPLICATION_CREDENTIALS -# Bundle the pre-built models (that are downloaded on demand) into the -# Docker image. -RUN ammico_prefetch_models +RUN rm -rf "$HOME"/work && \ + cp /opt/ammico/notebooks/*.ipynb "$HOME" \ No newline at end of file