Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[vpdq] Add support for Windows in vpdq pypy package #1346

Open
therreher opened this issue Aug 17, 2023 · 5 comments
Open

[vpdq] Add support for Windows in vpdq pypy package #1346

therreher opened this issue Aug 17, 2023 · 5 comments
Labels
help wanted vpdq Pertaining to the Video PDQ hashing algorithm

Comments

@therreher
Copy link

Does this software work with windows 10. I have ffmpeg and cmake installed but when I try to install I get this error:
pip install vpdq
Collecting vpdq
Using cached vpdq-0.0.8.tar.gz (86 kB)
Preparing metadata (setup.py) ... done
Requirement already satisfied: cython in c:\users\user\appdata\local\programs\python\python311\lib\site-packages (from vpdq) (3.0.0)
Requirement already satisfied: opencv-python in c:\users\user\appdata\local\programs\python\python311\lib\site-packages (from vpdq) (4.8.0.76)
Collecting opencv-python-headless (from vpdq)
Obtaining dependency information for opencv-python-headless from https://files.pythonhosted.org/packages/70/78/7a13730745684584db53e8aa3c3bd84beef2dcb32bebf627bda0d6df461e/opencv_python_headless-4.8.0.76-cp37-abi3-win_amd64.whl.metadata
Using cached opencv_python_headless-4.8.0.76-cp37-abi3-win_amd64.whl.metadata (20 kB)
Requirement already satisfied: numpy>=1.21.2 in c:\users\user\appdata\local\programs\python\python311\lib\site-packages (from opencv-python->vpdq) (1.25.2)
Using cached opencv_python_headless-4.8.0.76-cp37-abi3-win_amd64.whl (38.0 MB)
Building wheels for collected packages: vpdq
Building wheel for vpdq (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [4 lines of output]
running bdist_wheel
running build
running build_ext
error: [WinError 2] The system cannot find the file specified
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for vpdq
Running setup.py clean for vpdq
Failed to build vpdq
ERROR: Could not build wheels for vpdq, which is required to install pyproject.toml-based projects

@Dcallies
Copy link
Contributor

Hmm, @ianwal had done a series of diffs to add windows support, but I don't think we built a new version at the end, which you've tried to pip install. Let me release a new version and see if that fixes it.

I have a windows machine, so should be able to test it.

@Dcallies Dcallies added the vpdq Pertaining to the Video PDQ hashing algorithm label Aug 17, 2023
@Dcallies Dcallies self-assigned this Aug 17, 2023
@ianwal
Copy link
Contributor

ianwal commented Aug 17, 2023

The Python bindings I didn't have time to get working fully with Windows. It's a build issue. But, vpdq itself does build and work with Windows.

The way the binding builds with Cython is it passes the libav libraries as the environment variable LIBRARY_DIRS from CMake to Cython. When I tried to build with Windows it seemed like that was missing. It's probably a simple fix.

Here are some of my notes to get vpdq itself to build on Windows with MinGW #1331 (comment)

One way this could be done is if the platform is detected as Windows in the build script vpdq/vpdq-release.py, then have the user supply the location of the libav library dirs installed with MinGW. This wouldn't be pretty but it would work.

@Dcallies
Copy link
Contributor

Finally repo'd on my side after remembering the correct sequence of installs to get visual studios to build opencv.

@therreher - any concerns with me converting this to a help request to add windows support for the cpp bindings?

@therreher
Copy link
Author

That's find but I have another question. I saw in @ianwal notes"Install MinGW toolchain." Does FFmpeg need to be installed through MinGW because I installed it from https://www.gyan.dev/ffmpeg/builds/ and added the path manually.

@ianwal
Copy link
Contributor

ianwal commented Aug 18, 2023

FFmpeg need to be installed through MinGW because I installed it from https://www.gyan.dev/ffmpeg/builds/ and added the path manually.

Not sure. I don't have a lot of experience with MinGW. If it builds it builds. I would prefer to install through a package manager though.

@Dcallies Dcallies removed their assignment Aug 18, 2023
@Dcallies Dcallies changed the title Windows? [vpdq] Add support for Windows in vpdq pypy package Aug 23, 2023
dougneal pushed a commit that referenced this issue Aug 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted vpdq Pertaining to the Video PDQ hashing algorithm
Projects
None yet
Development

No branches or pull requests

3 participants