Spaces:
Runtime error
Runtime error
Commit
•
6d91644
1
Parent(s):
e779e95
Update setup.py
Browse files
setup.py
CHANGED
@@ -1,61 +1,6 @@
|
|
1 |
from typing import List
|
2 |
from setuptools import find_packages, setup
|
3 |
import subprocess
|
4 |
-
|
5 |
-
def fetch_requirements(path) -> List[str]:
|
6 |
-
"""
|
7 |
-
This function reads the requirements file.
|
8 |
-
|
9 |
-
Args:
|
10 |
-
path (str): the path to the requirements file.
|
11 |
-
|
12 |
-
Returns:
|
13 |
-
The lines in the requirements file.
|
14 |
-
"""
|
15 |
-
with open(path, "r") as fd:
|
16 |
-
return [r.strip() for r in fd.readlines()]
|
17 |
-
|
18 |
-
def fetch_readme() -> str:
|
19 |
-
"""
|
20 |
-
This function reads the README.md file in the current directory.
|
21 |
-
|
22 |
-
Returns:
|
23 |
-
The lines in the README file.
|
24 |
-
"""
|
25 |
-
with open("README.md", encoding="utf-8") as f:
|
26 |
-
return f.read()
|
27 |
-
|
28 |
-
setup(
|
29 |
-
name="opensora",
|
30 |
-
version="1.0.0",
|
31 |
-
packages=find_packages(
|
32 |
-
exclude=(
|
33 |
-
"assets",
|
34 |
-
"configs",
|
35 |
-
"docs",
|
36 |
-
"outputs",
|
37 |
-
"pretrained_models",
|
38 |
-
"scripts",
|
39 |
-
"tests",
|
40 |
-
"tools",
|
41 |
-
"*.egg-info",
|
42 |
-
)
|
43 |
-
),
|
44 |
-
description="Democratizing Efficient Video Production for All",
|
45 |
-
long_description=fetch_readme(),
|
46 |
-
long_description_content_type="text/markdown",
|
47 |
-
license="Apache Software License 2.0",
|
48 |
-
install_requires=fetch_requirements("requirements.txt"),
|
49 |
-
python_requires=">=3.6",
|
50 |
-
classifiers=[
|
51 |
-
"Programming Language :: Python :: 3",
|
52 |
-
"License :: OSI Approved :: Apache Software License",
|
53 |
-
"Environment :: GPU :: NVIDIA CUDA",
|
54 |
-
"Topic :: Scientific/Engineering :: Artificial Intelligence",
|
55 |
-
"Topic :: System :: Distributed Computing",
|
56 |
-
],
|
57 |
-
)
|
58 |
-
|
59 |
install_options = [
|
60 |
"--disable-pip-version-check",
|
61 |
"--no-cache-dir",
|
@@ -68,4 +13,72 @@ subprocess.run(
|
|
68 |
["pip", "install", "-v"] + install_options + ["git+https://github.com/sandeshrajbhandari/apex.git#egg=apex"],
|
69 |
check=True,
|
70 |
capture_output=True
|
71 |
-
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
from typing import List
|
2 |
from setuptools import find_packages, setup
|
3 |
import subprocess
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
4 |
install_options = [
|
5 |
"--disable-pip-version-check",
|
6 |
"--no-cache-dir",
|
|
|
13 |
["pip", "install", "-v"] + install_options + ["git+https://github.com/sandeshrajbhandari/apex.git#egg=apex"],
|
14 |
check=True,
|
15 |
capture_output=True
|
16 |
+
)
|
17 |
+
|
18 |
+
# def fetch_requirements(path) -> List[str]:
|
19 |
+
# """
|
20 |
+
# This function reads the requirements file.
|
21 |
+
|
22 |
+
# Args:
|
23 |
+
# path (str): the path to the requirements file.
|
24 |
+
|
25 |
+
# Returns:
|
26 |
+
# The lines in the requirements file.
|
27 |
+
# """
|
28 |
+
# with open(path, "r") as fd:
|
29 |
+
# return [r.strip() for r in fd.readlines()]
|
30 |
+
|
31 |
+
# def fetch_readme() -> str:
|
32 |
+
# """
|
33 |
+
# This function reads the README.md file in the current directory.
|
34 |
+
|
35 |
+
# Returns:
|
36 |
+
# The lines in the README file.
|
37 |
+
# """
|
38 |
+
# with open("README.md", encoding="utf-8") as f:
|
39 |
+
# return f.read()
|
40 |
+
|
41 |
+
# setup(
|
42 |
+
# name="opensora",
|
43 |
+
# version="1.0.0",
|
44 |
+
# packages=find_packages(
|
45 |
+
# exclude=(
|
46 |
+
# "assets",
|
47 |
+
# "configs",
|
48 |
+
# "docs",
|
49 |
+
# "outputs",
|
50 |
+
# "pretrained_models",
|
51 |
+
# "scripts",
|
52 |
+
# "tests",
|
53 |
+
# "tools",
|
54 |
+
# "*.egg-info",
|
55 |
+
# )
|
56 |
+
# ),
|
57 |
+
# description="Democratizing Efficient Video Production for All",
|
58 |
+
# long_description=fetch_readme(),
|
59 |
+
# long_description_content_type="text/markdown",
|
60 |
+
# license="Apache Software License 2.0",
|
61 |
+
# install_requires=fetch_requirements("requirements.txt"),
|
62 |
+
# python_requires=">=3.6",
|
63 |
+
# classifiers=[
|
64 |
+
# "Programming Language :: Python :: 3",
|
65 |
+
# "License :: OSI Approved :: Apache Software License",
|
66 |
+
# "Environment :: GPU :: NVIDIA CUDA",
|
67 |
+
# "Topic :: Scientific/Engineering :: Artificial Intelligence",
|
68 |
+
# "Topic :: System :: Distributed Computing",
|
69 |
+
# ],
|
70 |
+
# )
|
71 |
+
|
72 |
+
# install_options = [
|
73 |
+
# "--disable-pip-version-check",
|
74 |
+
# "--no-cache-dir",
|
75 |
+
# "--no-build-isolation",
|
76 |
+
# "--config-settings", "--build-option=--cpp_ext",
|
77 |
+
# "--config-settings", "--build-option=--cuda_ext"
|
78 |
+
# ]
|
79 |
+
|
80 |
+
# subprocess.run(
|
81 |
+
# ["pip", "install", "-v"] + install_options + ["git+https://github.com/sandeshrajbhandari/apex.git#egg=apex"],
|
82 |
+
# check=True,
|
83 |
+
# capture_output=True
|
84 |
+
# )
|