forked from terra-quantum-public/TQCompressedGPT2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
29 lines (23 loc) · 752 Bytes
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
from setuptools import setup, find_packages
from pathlib import Path
# Load packages from requirements.txt
BASE_DIR = Path(__file__).parent
with open(BASE_DIR / "requirements.txt", "r") as file:
required_packages = []
for line in file.readlines():
line = line.strip()
if line.startswith("#") or len(line) == 0:
continue
if "https://" in line:
tail = line.rsplit("/", 1)[1]
tail = tail.split("#")[0]
line = tail.replace("@", "==").replace(".git", "")
if line == "-e .":
continue
required_packages.append(line)
setup(
name="TQCompressedGPT2",
version="0.1",
packages=find_packages(),
install_requires=[required_packages],
)