|
| 1 | +[tool.poetry] |
| 2 | +name = "rembg" |
| 3 | +version = "0.0.0" # Managed by poetry-dynamic-versioning |
| 4 | +description = "Remove image background" |
| 5 | +authors = ["Daniel Gatis <danielgatis@gmail.com>"] |
| 6 | +license = "MIT" |
| 7 | +readme = "README.md" |
| 8 | +homepage = "https://github.com/danielgatis/rembg" |
| 9 | +repository = "https://github.com/danielgatis/rembg" |
| 10 | +keywords = ["remove", "background", "u2net"] |
| 11 | +classifiers = [ |
| 12 | + "License :: OSI Approved :: MIT License", |
| 13 | + "Topic :: Scientific/Engineering", |
| 14 | + "Topic :: Scientific/Engineering :: Mathematics", |
| 15 | + "Topic :: Scientific/Engineering :: Artificial Intelligence", |
| 16 | + "Topic :: Software Development", |
| 17 | + "Topic :: Software Development :: Libraries", |
| 18 | + "Topic :: Software Development :: Libraries :: Python Modules", |
| 19 | + "Programming Language :: Python", |
| 20 | + "Programming Language :: Python :: 3 :: Only", |
| 21 | + "Programming Language :: Python :: 3.11", |
| 22 | + "Programming Language :: Python :: 3.12", |
| 23 | + "Programming Language :: Python :: 3.13", |
| 24 | +] |
| 25 | +packages = [{include = "rembg"}] |
| 26 | + |
| 27 | +[tool.poetry.dependencies] |
| 28 | +python = "^3.11" |
| 29 | +jsonschema = "^4.25.1" |
| 30 | +numpy = "^2.3.0" |
| 31 | +pillow = "^12.1.0" |
| 32 | +pooch = "^1.8.2" |
| 33 | +pymatting = "^1.1.14" |
| 34 | +scikit-image = "^0.26.0" |
| 35 | +scipy = "^1.16.3" |
| 36 | +tqdm = "^4.67.1" |
| 37 | + |
| 38 | +# CPU backend (optional) |
| 39 | +onnxruntime = {version = "^1.23.2", optional = true} |
| 40 | + |
| 41 | +# GPU backend (optional) - only available on Linux/Windows, not on macOS |
| 42 | +onnxruntime-gpu = {version = "^1.23.2", optional = true, markers = "sys_platform != 'darwin'"} |
| 43 | + |
| 44 | +# ROCm backend (optional) - only available on Linux (latest is 1.22.x) |
| 45 | +onnxruntime-rocm = {version = "^1.22.0", optional = true, markers = "sys_platform == 'linux'"} |
| 46 | + |
| 47 | +# CLI dependencies (optional) |
| 48 | +aiohttp = {version = "^3.13.2", optional = true} |
| 49 | +asyncer = {version = "^0.0.12", optional = true} |
| 50 | +click = {version = "^8.3.1", optional = true} |
| 51 | +fastapi = {version = "^0.128.0", optional = true} |
| 52 | +filetype = {version = "^1.2.0", optional = true} |
| 53 | +gradio = {version = "^6.2.0", optional = true} |
| 54 | +python-multipart = {version = "^0.0.21", optional = true} |
| 55 | +sniffio = {version = "^1.3.1", optional = true} |
| 56 | +uvicorn = {version = "^0.40.0", optional = true} |
| 57 | +watchdog = {version = "^6.0.0", optional = true} |
| 58 | + |
| 59 | +# Dev dependencies (optional, for pip install .[dev]) |
| 60 | +bandit = {version = "^1.9.2", optional = true} |
| 61 | +black = {version = "^25.12.0", optional = true} |
| 62 | +flake8 = {version = "^7.3.0", optional = true} |
| 63 | +imagehash = {version = "^4.3.2", optional = true} |
| 64 | +isort = {version = "^7.0.0", optional = true} |
| 65 | +mypy = {version = "^1.19.1", optional = true} |
| 66 | +pytest = {version = "^9.0.2", optional = true} |
| 67 | + |
| 68 | +[tool.poetry.group.dev.dependencies] |
| 69 | +bandit = "^1.9.2" |
| 70 | +black = "^25.12.0" |
| 71 | +flake8 = "^7.3.0" |
| 72 | +imagehash = "^4.3.2" |
| 73 | +isort = "^7.0.0" |
| 74 | +mypy = "^1.19.1" |
| 75 | +pytest = "^9.0.2" |
| 76 | + |
| 77 | +[tool.poetry.extras] |
| 78 | +cpu = ["onnxruntime"] |
| 79 | +gpu = ["onnxruntime-gpu"] |
| 80 | +rocm = ["onnxruntime-rocm"] |
| 81 | +cli = ["aiohttp", "asyncer", "click", "fastapi", "filetype", "gradio", "python-multipart", "sniffio", "uvicorn", "watchdog"] |
| 82 | +dev = ["bandit", "black", "flake8", "imagehash", "isort", "mypy", "pytest"] |
| 83 | + |
| 84 | +[tool.poetry.scripts] |
| 85 | +rembg = "rembg.cli:main" |
| 86 | + |
1 | 87 | [build-system] |
2 | | -# These are the assumed default build requirements from pip: |
3 | | -# https://pip.pypa.io/en/stable/reference/pip/#pep-517-and-518-support |
4 | | -requires = ["setuptools>=65.5.1", "wheel"] |
5 | | -build-backend = "setuptools.build_meta" |
| 88 | +requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning>=1.0.0,<2.0.0"] |
| 89 | +build-backend = "poetry_dynamic_versioning.backend" |
6 | 90 |
|
7 | | -[versioneer] |
8 | | -VCS = "git" |
| 91 | +[tool.poetry-dynamic-versioning] |
| 92 | +enable = true |
| 93 | +vcs = "git" |
9 | 94 | style = "pep440" |
10 | | -versionfile_source = "rembg/_version.py" |
11 | | -versionfile_build = "rembg/_version.py" |
12 | | -tag_prefix = "v" |
13 | | -parentdir_prefix = "rembg-" |
| 95 | +pattern = "^v(?P<base>\\d+\\.\\d+\\.\\d+)" |
| 96 | + |
| 97 | +[tool.poetry-dynamic-versioning.substitution] |
| 98 | +files = ["rembg/__init__.py"] |
0 commit comments