This commit is contained in:
Jeff Rasley 2021-11-11 08:57:17 -08:00 коммит произвёл GitHub
Родитель bd3ebddf36
Коммит 2665c8b149
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
3 изменённых файлов: 7 добавлений и 6 удалений

2
.github/workflows/main.yml поставляемый
Просмотреть файл

@ -91,8 +91,8 @@ jobs:
run: |
if [[ -d ./torch-extensions ]]; then rm -rf ./torch-extensions; fi
git clone https://github.com/huggingface/transformers
git rev-parse --short HEAD
cd transformers
git rev-parse --short HEAD
# scipy/sklearn required for tests, using the 'dev' extra forces torch re-install
pip install .[testing]
# find reqs used in ds integration tests

Просмотреть файл

@ -50,16 +50,17 @@ def fetch_requirements(path):
install_requires = fetch_requirements('requirements/requirements.txt')
extras_require = {
'1bit_adam': fetch_requirements('requirements/requirements-1bit-adam.txt'),
'1bit_mpi' : fetch_requirements('requirements/requirements-1bit-mpi.txt'),
'1bit': [], # Will add proper cupy version below
'readthedocs': fetch_requirements('requirements/requirements-readthedocs.txt'),
'dev': fetch_requirements('requirements/requirements-dev.txt'),
}
# If MPI is available add 1bit-adam requirements
# Add specific cupy version to both onebit extension variants
if torch_available and torch.cuda.is_available():
if shutil.which('ompi_info') or shutil.which('mpiname'):
cupy = f"cupy-cuda{torch.version.cuda.replace('.','')[:3]}"
extras_require['1bit_adam'].append(cupy)
cupy = f"cupy-cuda{torch.version.cuda.replace('.','')[:3]}"
extras_require['1bit_mpi'].append(cupy)
extras_require['1bit'].append(cupy)
# Make an [all] extra that installs all needed dependencies
all_extras = set()