From 1d8a7c797e9f710b0c98e3e07505d6c736bebacd Mon Sep 17 00:00:00 2001 From: Sergey Chernyaev Date: Sun, 12 May 2024 13:55:12 +0200 Subject: [PATCH] Fix EasyNMT, fasttext dependency installation problem on Python 3.11 --- .github/workflows/setup.yml | 4 ++-- requirements.txt | 12 ++++++++---- setup.py | 9 +++++++-- 3 files changed, 17 insertions(+), 8 deletions(-) diff --git a/.github/workflows/setup.yml b/.github/workflows/setup.yml index 60619ea..3d0dc55 100644 --- a/.github/workflows/setup.yml +++ b/.github/workflows/setup.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.9"] + python-version: ["3.11"] steps: - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} @@ -16,7 +16,7 @@ jobs: python-version: ${{ matrix.python-version }} - name: Install application run: | - pip install wheel + pip install --no-deps EasyNMT==2.0.2 pip install -e . - name: Check that package was installed successfully run: | diff --git a/requirements.txt b/requirements.txt index 71da213..3f3d862 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,7 +2,11 @@ faster-whisper==0.10.0 tqdm==4.56.0 ffmpeg-python==0.2.0 wheel==0.42.0 -fasttext==0.9.2 -pybind11==2.11.1 -EasyNMT==2.0.2 -langcodes==3.3.0 \ No newline at end of file +langcodes==3.3.0 +transformers>=4.4,<5 +torch>=1.6.0 +numpy +nltk +sentencepiece +protobuf +EasyNMT==2.0.2 \ No newline at end of file diff --git a/setup.py b/setup.py index 2758ca7..86e200d 100644 --- a/setup.py +++ b/setup.py @@ -10,9 +10,14 @@ 'faster-whisper', 'tqdm', 'ffmpeg-python', - 'fasttext', - 'EasyNMT', 'langcodes', + 'transformers>=4.4,<5', + 'torch>=1.6.0', + 'numpy', + 'nltk', + 'sentencepiece', + 'protobuf', + 'EasyNMT==2.0.2', ], description="Automatically generate and embed subtitles into your videos", entry_points={