From 073f09c310b0b65b9205f425a7685dff9062f668 Mon Sep 17 00:00:00 2001 From: yunss-ML Date: Fri, 25 Aug 2023 21:54:53 +0100 Subject: [PATCH] update repo reqs --- requirements.txt | 4 ++-- setup.py | 16 ++++++++++++---- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/requirements.txt b/requirements.txt index bc83bf5..9c4dbee 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,2 +1,2 @@ -git+https://github.com/Baijiong-Lin/LoRA-Torch -git+https://github.com/microsoft/LoRA \ No newline at end of file +LoRA-Torch @ git+https://github.com/Baijiong-Lin/LoRA-Torch +loralib diff --git a/setup.py b/setup.py index 5313b09..643029c 100644 --- a/setup.py +++ b/setup.py @@ -1,6 +1,8 @@ import setuptools import os +import pkg_resources import sys +import pathlib current_dir = os.path.dirname(__file__) target_dir = os.path.abspath(os.path.join(current_dir, ".")) @@ -15,6 +17,15 @@ ENV: python -m venv AdapterLoRa && pip install -r requirements.txt """ +# parse_requirements() returns generator of pip.req.InstallRequirement objects +# install_reqs =parse_requirements('requirements.txt', session='hack') +# reqs = [str(ir.req) for ir in install_reqs] +with pathlib.Path('requirements.txt').open() as requirements_txt: + install_requires = [ + str(requirement) + for requirement + in pkg_resources.parse_requirements(requirements_txt) + ] setuptools.setup( name="AdapterLoRa", @@ -27,10 +38,7 @@ url="https://github.com/youness-elbrag/AdapterLoRa/", packages=setuptools.find_packages(), keywords = ['Quantization', 'AdapterLLM', 'PEFT'], # Keywords that define your package best - install_requires=[ # I get to this in a second - 'LoRA-Torch @ git+https://github.com/Baijiong-Lin/LoRA-Torch', - 'LoRA @ git+https://github.com/microsoft/LoRA', - ], + install_requires= install_requires, classifiers=[ 'Development Status :: 4 - Beta', # Chose either "3 - Alpha", "4 - Beta" or "5 - Production/Stable" as the current state of your package 'Intended Audience :: Developers', # Define that your audience are developers