Skip to content

Commit

Permalink
upgraded dependencies and ruff changes
Browse files Browse the repository at this point in the history
  • Loading branch information
alvertogit committed Mar 3, 2024
1 parent 8a52341 commit c59907f
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
python3 -m pip install --upgrade setuptools
python3 -m pip install -r requirements.txt
- name: Lint with Ruff
run: ruff --output-format=github .
run: ruff check --output-format=github .
continue-on-error: true
- name: Run tests
run: |
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ WORKDIR /app
COPY requirements.txt /app
RUN python3 -m venv .
RUN python3 -m pip install pip==24.0
RUN python3 -m pip install setuptools==69.1.0
RUN python3 -m pip install setuptools==69.1.1
RUN python3 -m pip install --no-cache-dir -r requirements.txt
COPY ./app /app
EXPOSE 5000
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ The code has been tested using:
* [TensorFlow] (2.15): an open source software [Deep Learning] library for high performance numerical computation using data flow graphs.
* [Matplotlib] (3.8): a plotting library for [Python] and its numerical mathematics extension [NumPy].
* [NumPy] (1.26): a library for [Python], adding support for large, multi-dimensional arrays and matrices, along with a large collection of high-level mathematical functions to operate on these arrays.
* [Ruff] (0.3): An extremely fast Python linter and code formatter, written in Rust.
* [scikit-image] (0.22): a collection of algorithms for image processing with [Python].

### PYTHON VIRTUAL ENVIRONMENT
Expand All @@ -44,7 +45,7 @@ Command to configure virtual environment with [venv]:
~/deeplearning_flask$ python3 -m venv dlflask3
~/deeplearning_flask$ source dlflask3/bin/activate
(dlflask3)~/deeplearning_flask$ python3 -m pip install pip==24.0
(dlflask3)~/deeplearning_flask$ python3 -m pip install setuptools==69.1.0
(dlflask3)~/deeplearning_flask$ python3 -m pip install setuptools==69.1.1
(dlflask3)~/deeplearning_flask$ python3 -m pip install -r requirements_dev.txt
```

Expand All @@ -59,6 +60,7 @@ deeplearning_flask
├── .github
│   └── workflows
│   └── ci_tests.yml
├── .gitignore
├── app
│   ├── app
│   │   ├── __init__.py
Expand All @@ -82,6 +84,7 @@ deeplearning_flask
├── nginx
│   └── conf.d
│   └── local.conf
├── pyproject.toml
├── README.md
├── requirements.txt
└── requirements_dev.txt
Expand Down Expand Up @@ -243,3 +246,4 @@ copyright: 2018-2024
[curl]: https://curl.haxx.se/
[pytest]: https://docs.pytest.org/en/latest/
[Makefile]: https://en.wikipedia.org/wiki/Makefile
[Ruff]: https://docs.astral.sh/ruff/
8 changes: 6 additions & 2 deletions .ruff.toml → pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
[tool.ruff]
extend-include = ["*.ipynb"]

line-length = 100
target-version = "py310"
lint.select = [

[tool.ruff.lint]
select = [
# pycodestyle
"E",
"W",
Expand All @@ -15,4 +20,3 @@ lint.select = [
# isort
"I",
]
extend-include = ["*.ipynb"]
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ Flask==3.0.2
gunicorn==21.2.0
numpy==1.26.4
Pillow==10.2.0
pytest==8.0.1
pytest==8.0.2
requests==2.31.0
ruff==0.2.2
ruff==0.3.0
scikit-image==0.22.0
tensorflow==2.15.0
2 changes: 1 addition & 1 deletion requirements_dev.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
-r requirements.txt
jupyterlab==4.1.1
jupyterlab==4.1.2
matplotlib==3.8.3

0 comments on commit c59907f

Please sign in to comment.