Create cli/setup.py
Browse files- cli/setup.py +76 -0
cli/setup.py
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""
|
| 2 |
+
Setup script for BackgroundFX Pro CLI.
|
| 3 |
+
Creates command-line entry point and handles installation.
|
| 4 |
+
"""
|
| 5 |
+
|
| 6 |
+
from setuptools import setup, find_packages
|
| 7 |
+
import os
|
| 8 |
+
from pathlib import Path
|
| 9 |
+
|
| 10 |
+
# Read README if it exists
|
| 11 |
+
readme_path = Path(__file__).parent.parent / "README.md"
|
| 12 |
+
long_description = ""
|
| 13 |
+
if readme_path.exists():
|
| 14 |
+
with open(readme_path, encoding="utf-8") as f:
|
| 15 |
+
long_description = f.read()
|
| 16 |
+
|
| 17 |
+
|
| 18 |
+
def get_requirements():
|
| 19 |
+
"""Get requirements from requirements.txt."""
|
| 20 |
+
req_file = Path(__file__).parent.parent / "requirements.txt"
|
| 21 |
+
if req_file.exists():
|
| 22 |
+
with open(req_file) as f:
|
| 23 |
+
return [line.strip() for line in f if line.strip() and not line.startswith("#")]
|
| 24 |
+
|
| 25 |
+
# Fallback requirements
|
| 26 |
+
return [
|
| 27 |
+
"click>=8.0.0",
|
| 28 |
+
"rich>=10.0.0",
|
| 29 |
+
"opencv-python>=4.5.0",
|
| 30 |
+
"numpy>=1.19.0",
|
| 31 |
+
"torch>=1.9.0",
|
| 32 |
+
"gradio>=3.0.0",
|
| 33 |
+
]
|
| 34 |
+
|
| 35 |
+
|
| 36 |
+
setup(
|
| 37 |
+
name="backgroundfx-pro",
|
| 38 |
+
version="1.0.0",
|
| 39 |
+
author="BackgroundFX Team",
|
| 40 |
+
description="Professional video background removal and replacement",
|
| 41 |
+
long_description=long_description,
|
| 42 |
+
long_description_content_type="text/markdown",
|
| 43 |
+
url="https://github.com/yourusername/backgroundfx-pro",
|
| 44 |
+
packages=find_packages(),
|
| 45 |
+
python_requires=">=3.8",
|
| 46 |
+
install_requires=get_requirements(),
|
| 47 |
+
extras_require={
|
| 48 |
+
"dev": [
|
| 49 |
+
"pytest>=6.0",
|
| 50 |
+
"black>=21.0",
|
| 51 |
+
"flake8>=3.9",
|
| 52 |
+
],
|
| 53 |
+
"cuda": [
|
| 54 |
+
"torch>=1.9.0+cu111",
|
| 55 |
+
],
|
| 56 |
+
},
|
| 57 |
+
entry_points={
|
| 58 |
+
"console_scripts": [
|
| 59 |
+
"bgfx=cli.main:main",
|
| 60 |
+
"backgroundfx=cli.main:main",
|
| 61 |
+
],
|
| 62 |
+
},
|
| 63 |
+
classifiers=[
|
| 64 |
+
"Development Status :: 4 - Beta",
|
| 65 |
+
"Intended Audience :: Developers",
|
| 66 |
+
"Intended Audience :: End Users/Desktop",
|
| 67 |
+
"License :: OSI Approved :: MIT License",
|
| 68 |
+
"Operating System :: OS Independent",
|
| 69 |
+
"Programming Language :: Python :: 3",
|
| 70 |
+
"Programming Language :: Python :: 3.8",
|
| 71 |
+
"Programming Language :: Python :: 3.9",
|
| 72 |
+
"Programming Language :: Python :: 3.10",
|
| 73 |
+
"Topic :: Multimedia :: Video",
|
| 74 |
+
"Topic :: Scientific/Engineering :: Artificial Intelligence",
|
| 75 |
+
],
|
| 76 |
+
)
|