diff --git a/.github/workflows/test-docker.yml b/.github/workflows/test-docker.yml new file mode 100644 index 0000000..87f620b --- /dev/null +++ b/.github/workflows/test-docker.yml @@ -0,0 +1,19 @@ +# action.yml +name: 'test-docker' +on: 'pull_request' +jobs: + test-docker: + runs-on: ubuntu-latest + defaults: + run: + shell: bash -l {0} + steps: + + - uses: actions/checkout@v3 + + - name: Setup Docker buildx + uses: docker/setup-buildx-action@v1 + + - run: | + docker build -t testbuild . + docker run -v "$(pwd)":/app testbuild bash -c "cd /app && pytest" \ No newline at end of file diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 580d1ae..55609a0 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -14,13 +14,13 @@ jobs: - uses: conda-incubator/setup-miniconda@v2 with: - python-version: "3.6" + python-version: "3.8" - run: | pip install . sudo apt-get update sudo apt-get install libglib2.0-0 -y sudo apt-get install libsm6 libxext6 libxrender-dev -y - conda install faiss-cpu=1.6.3 -c pytorch + conda install faiss-cpu=1.7.2 -c pytorch pip uninstall recurring_content_detector -y python -m pytest -s diff --git a/Dockerfile b/Dockerfile index 98448a2..7d7d8e8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -7,12 +7,12 @@ COPY setup.py /opt/recurring-content-detector/setup.py WORKDIR /opt/recurring-content-detector -RUN conda install python=3.6 -y && \ +RUN conda install python=3.8 -y && \ pip install . && \ apt-get update --allow-releaseinfo-change && \ apt-get install libglib2.0-0 -y && \ apt-get install -y libsm6 libxext6 libxrender-dev -y && \ apt-get install ffmpeg -y && \ - conda install faiss-cpu=1.6.3 -c pytorch + conda install faiss-cpu=1.7.2 -c pytorch diff --git a/README.MD b/README.MD index cc4a360..1c72b45 100644 --- a/README.MD +++ b/README.MD @@ -25,12 +25,12 @@ It'll first downsize the videos using ffmpeg, then it will convert the videos to ## Local Installation -To install the package, do the following steps (assuming you have an anaconda setup with python 3.6) if you want to run the program with the default settings: +To install the package, do the following steps (assuming you have an anaconda setup with python 3.8): ```bash git clone https://github.com/nielstenboom/recurring-content-detector.git cd recurring-content-detector -conda install faiss-cpu=1.6.3 -c pytorch +conda install faiss-cpu=1.7.2 -c pytorch pip install mkl pip install . ``` diff --git a/setup.py b/setup.py index 9e8839b..76a6fc2 100644 --- a/setup.py +++ b/setup.py @@ -10,15 +10,15 @@ packages=find_packages(), include_package_data = True, install_requires=[ - 'Pillow==6.1.0', - 'ffmpeg_python==0.2.0', - 'matplotlib==3.1.1', - 'opencv_python==4.1.1.26', - 'pandas==0.25.0', - 'scipy==1.3.1', - 'tqdm==4.40.2', - 'natsort==6.2.0', - 'numpy==1.16.2', - 'pytest==6.0.2' + 'Pillow==6.*', + 'ffmpeg_python==0.*', + 'matplotlib==3.*', + 'opencv_python==4.*', + 'pandas==0.*', + 'scipy==1.*', + 'tqdm==4.*', + 'natsort==6.*', + 'numpy==1.*', + 'pytest==6.*' ], zip_safe=False) \ No newline at end of file