Skip to content

Commit

Permalink
Prepare to release.
Browse files Browse the repository at this point in the history
  • Loading branch information
Cykooz committed Oct 8, 2021
1 parent 0923ef2 commit 010527a
Show file tree
Hide file tree
Showing 7 changed files with 69 additions and 23 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
name: Linux
strategy:
matrix:
python-version: [ "3.6", "3.7", "3.8", "3.9" ]
python-version: [ "3.6", "3.7", "3.8", "3.9", "3.10" ]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
runs-on: windows-latest
strategy:
matrix:
python-version: [ "3.6", "3.7", "3.8", "3.9" ]
python-version: [ "3.6", "3.7", "3.8", "3.9", "3.10" ]
steps:
- uses: actions/checkout@v2

Expand Down Expand Up @@ -131,7 +131,7 @@ jobs:
runs-on: macos-latest
strategy:
matrix:
python-version: [ "3.6", "3.7", "3.8", "3.9" ]
python-version: [ "3.6", "3.7", "3.8", "3.9", "3.10" ]
steps:
- uses: actions/checkout@v2

Expand Down
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CHANGELOG

## [1.0] - 2021-10-08

- First stable release.

## [0.1] - 2021-09-05

- Initial version.
20 changes: 10 additions & 10 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ name = "cykooz.resizer.rust_lib"

[dependencies]
fast_image_resize = "0.3.0"
pyo3 = "0.14.3"
pyo3 = "0.14.5"


[features]
Expand Down
41 changes: 41 additions & 0 deletions DEV.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Notes for developers

## Install dependencies

- Install Rust with help of `rustup` (https://rustup.rs/)
- Install Pythons dependencies:
```shell
python3 -m pip install .[pillow]
```

## Build Rust library

### Debug version

```shell
maturin develop
```

### Optimized version

```shell
maturin develop --release --strip
```

## Run tests

```shell
pytest --benchmark-skip
```

## Run benchmark

```shell
pytest -s tests/test_benchmark.py
```

## Build release wheels and sdist

```shell
maturin build --release --strip
```
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ python3 -m pip install cykooz.resizer[pillow]
## Information

Supported pixel types and available optimisations:
- ``U8x4`` - four bytes per pixel:
- ``U8x4`` - four bytes per pixel (RGB, RGBA, CMYK):
- native Rust-code without forced SIMD
- SSE4.1
- AVX2
Expand All @@ -31,7 +31,7 @@ Supported pixel types and available optimisations:

Implemented resize algorithms:
- Nearest - is nearest-neighbor interpolation, replacing every pixel with the
nearest pixel in the output; for upscaling this means multiple pixels of the.
nearest pixel in the output; for upscaling this means multiple pixels of the
same color will be present.
- Convolution with different filters:
- box
Expand Down Expand Up @@ -119,7 +119,7 @@ Resize algorithms:

| Package (time in ms) | nearest | bilinear | lanczos3 |
|:------------------------|----------:|-----------:|-----------:|
| Pillow | 0.93 | 118.66 | 204.77 |
| cykooz.resizer | 0.51 | 68.90 | 126.13 |
| cykooz.resizer - sse4_1 | 0.52 | 26.25 | 39.50 |
| cykooz.resizer - avx2 | 0.51 | 17.59 | 26.99 |
| Pillow | 0.92 | 99.03 | 228.23 |
| cykooz.resizer | 0.51 | 69.29 | 127.72 |
| cykooz.resizer - sse4_1 | 0.51 | 25.66 | 39.11 |
| cykooz.resizer - avx2 | 0.51 | 17.49 | 27.08 |
7 changes: 4 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,21 +1,22 @@
[build-system]
requires = ["maturin>=0.11"]
requires = ["maturin>=0.11.4"]
build-backend = "maturin"


[project]
name = "cykooz.resizer"
version = "0.1"
version = "1.0"
description = "A fast image resizer"
readme = "README.md"
classifiers = [
"Development Status :: 4 - Beta",
"Development Status :: 5 - Production/Stable",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Rust",
"Topic :: Multimedia :: Graphics",
Expand Down

0 comments on commit 010527a

Please sign in to comment.