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

Installation failed #43

Open
woshitiandoudou opened this issue Jan 11, 2024 · 3 comments
Open

Installation failed #43

woshitiandoudou opened this issue Jan 11, 2024 · 3 comments

Comments

@woshitiandoudou
Copy link

I have downloaded Python 3.8, PVCAM, and the SDK. However, I encountered the following error during the installation process in the Python terminal. What should I do?

running install
C:\Users\I\PycharmProjects\pythonProject2\venv\lib\site-packages\setuptools_distutils\cmd.py:66: SetuptoolsDeprecationWarning: setup.py instal
l is deprecated.
!!

    ********************************************************************************
    Please avoid running ``setup.py`` directly.
    Instead, use pypa/build, pypa/installer or other
    standards-based tools.

    See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details.
    ********************************************************************************

!!
self.initialize_options()
C:\Users\I\PycharmProjects\pythonProject2\venv\lib\site-packages\setuptools_distutils\cmd.py:66: EasyInstallDeprecationWarning: easy_install c
ommand is deprecated.
!!

    ********************************************************************************
    Please avoid running ``setup.py`` and ``easy_install``.
    Instead, use pypa/build, pypa/installer or other
    standards-based tools.

    See https://github.com/pypa/setuptools/issues/917 for details.
    ********************************************************************************

!!
self.initialize_options()
running bdist_egg
running egg_info
writing pyvcam.egg-info\PKG-INFO
writing dependency_links to pyvcam.egg-info\dependency_links.txt
writing top-level names to pyvcam.egg-info\top_level.txt
reading manifest file 'pyvcam.egg-info\SOURCES.txt'
adding license file 'LICENSE'
writing manifest file 'pyvcam.egg-info\SOURCES.txt'
installing library code to build\bdist.win-amd64\egg
running install_lib
running build_py
running build_ext
building 'pyvcam.pvc' extension
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -IC:\Users\I\PycharmProjects
pythonProject2\venv\lib\site-packages\numpy\core\include "-IC:\Program Files\Photometrics\PVCamSDK/inc/" -IC:\Users\I\PycharmProjects\pythonPr
oject2\venv\include -IC:\Users\I\AppData\Local\Programs\Python\Python38\include -IC:\Users\I\AppData\Local\Programs\Python\Python38\Includ
e "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\ucrt" "-IC:\Prog
ram Files (x86)\Windows Kits\8.1\include\shared" "-IC:\Program Files (x86)\Windows Kits\8.1\include\um" "-IC:\Program Files (x86)\Windows Kits\8.1\i
nclude\winrt" "-I-IC:\Program Files\Photometrics\PVCamSDK\inc" /EHsc /Tpsrc/pyvcam/pvcmodule.cpp /Fobuild\temp.win-amd64-cpython-38\Release\src/pyvc
am/pvcmodule.obj
pvcmodule.cpp
c:\users\I\pycharmprojects\pythonproject2\venv\lib\site-packages\numpy\core\include\numpy\npy_1_7_deprecated_api.h(14) : Warning Msg: Using dep
recated NumPy API, disable it with #define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
src/pyvcam/pvcmodule.cpp(173): warning C4244: '=': conversion from 'uintptr_t' to 'uns32', possible loss of data
src/pyvcam/pvcmodule.cpp(216): warning C4477: 'printf' : format string '%d' requires an argument of type 'int', but variadic argument 1 has type 'co
nst std::size_t'
src/pyvcam/pvcmodule.cpp(216): note: consider using '%zd' in the format string
src/pyvcam/pvcmodule.cpp(1317): error C3861: 'pl_exp_trigger': identifier not found
src/pyvcam/pvcmodule.cpp(1323): error C2065: 'PL_SW_TRIG_STATUS_TRIGGERED': undeclared identifier
src/pyvcam/pvcmodule.cpp(1371): error C2039: 'imageFormat': is not a member of 'md_frame_header'
C:\Program Files\Photometrics\PVCamSDK/inc/pvcam.h(924): note: see declaration of 'md_frame_header'
src/pyvcam/pvcmodule.cpp(1371): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1372): error C2039: 'imageCompression': is not a member of 'md_frame_header'
C:\Program Files\Photometrics\PVCamSDK/inc/pvcam.h(924): note: see declaration of 'md_frame_header'
src/pyvcam/pvcmodule.cpp(1372): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1375): error C2065: 'md_frame_header_v3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1375): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1375): error C2061: syntax error: identifier 'md_frame_header_v3'
src/pyvcam/pvcmodule.cpp(1376): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1376): error C2227: left of '->timestampBOF' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1376): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1376): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1377): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1377): error C2227: left of '->timestampEOF' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1377): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1377): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1378): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1378): error C2227: left of '->exposureTime' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1378): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1378): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1379): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1379): error C2227: left of '->bitDepth' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1379): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1379): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1380): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1380): error C2227: left of '->colorMask' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1380): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1380): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1381): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1381): error C2227: left of '->flags' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1381): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1381): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1382): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1382): error C2227: left of '->extendedMdSize' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1382): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1382): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1383): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1383): error C2227: left of '->imageFormat' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1383): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1383): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1384): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1384): error C2227: left of '->imageCompression' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1384): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1405): error C2660: 'PyDict_SetItem': function does not take 2 arguments
error: command 'C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe' failed with exit code 2
(venv) PS C:\Users\I\Desktop\F\D\PyVCAM-master> python -m pip install --upgrade numpy
Requirement already satisfied: numpy in c:\users\I\pycharmprojects\pythonproject2\venv\lib\site-packages (1.24.4)
(venv) PS C:\Users\I\Desktop\F\D\PyVCAM-master> $Env:INCLUDE = "-I'C:\Program Files\Photometrics\PVCamSDK\lib'"
(venv) PS C:\Users\I\Desktop\F\D\PyVCAM-master> python setup.py install
Operating system: Windows
Machine architecture: AMD64


Pre-install necessary packages as admin

python -m pip install --upgrade pip setuptools wheel numpy


Build package: python setup.py build

Install package: python setup.py install

Create Wheel dist: python setup.py sdist bdist_wheel

Uninstall package: pip uninstall pyvcam


running install
C:\Users\I\PycharmProjects\pythonProject2\venv\lib\site-packages\setuptools_distutils\cmd.py:66: SetuptoolsDeprecationWarning: setup.py instal
l is deprecated.
!!

    ********************************************************************************
    Please avoid running ``setup.py`` directly.
    Instead, use pypa/build, pypa/installer or other
    standards-based tools.

    See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details.
    ********************************************************************************

!!
self.initialize_options()
C:\Users\I\PycharmProjects\pythonProject2\venv\lib\site-packages\setuptools_distutils\cmd.py:66: EasyInstallDeprecationWarning: easy_install c
ommand is deprecated.
!!

    ********************************************************************************
    Please avoid running ``setup.py`` and ``easy_install``.
    Instead, use pypa/build, pypa/installer or other
    standards-based tools.

    See https://github.com/pypa/setuptools/issues/917 for details.
    ********************************************************************************

!!
self.initialize_options()
running bdist_egg
running egg_info
writing pyvcam.egg-info\PKG-INFO
writing dependency_links to pyvcam.egg-info\dependency_links.txt
writing top-level names to pyvcam.egg-info\top_level.txt
reading manifest file 'pyvcam.egg-info\SOURCES.txt'
adding license file 'LICENSE'
writing manifest file 'pyvcam.egg-info\SOURCES.txt'
installing library code to build\bdist.win-amd64\egg
running install_lib
running build_py
running build_ext
building 'pyvcam.pvc' extension
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -IC:\Users\I\PycharmProjects
pythonProject2\venv\lib\site-packages\numpy\core\include "-IC:\Program Files\Photometrics\PVCamSDK/inc/" -IC:\Users\I\PycharmProjects\pythonPr
oject2\venv\include -IC:\Users\I\AppData\Local\Programs\Python\Python38\include -IC:\Users\I\AppData\Local\Programs\Python\Python38\Includ
e "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\ucrt" "-IC:\Prog
ram Files (x86)\Windows Kits\8.1\include\shared" "-IC:\Program Files (x86)\Windows Kits\8.1\include\um" "-IC:\Program Files (x86)\Windows Kits\8.1\i
nclude\winrt" "-I-I'C:\Program Files\Photometrics\PVCamSDK\lib'" /EHsc /Tpsrc/pyvcam/pvcmodule.cpp /Fobuild\temp.win-amd64-cpython-38\Release\src/py
vcam/pvcmodule.obj
pvcmodule.cpp
c:\users\I\pycharmprojects\pythonproject2\venv\lib\site-packages\numpy\core\include\numpy\npy_1_7_deprecated_api.h(14) : Warning Msg: Using dep
recated NumPy API, disable it with #define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
src/pyvcam/pvcmodule.cpp(173): warning C4244: '=': conversion from 'uintptr_t' to 'uns32', possible loss of data
src/pyvcam/pvcmodule.cpp(216): warning C4477: 'printf' : format string '%d' requires an argument of type 'int', but variadic argument 1 has type 'co
nst std::size_t'
src/pyvcam/pvcmodule.cpp(216): note: consider using '%zd' in the format string
src/pyvcam/pvcmodule.cpp(1317): error C3861: 'pl_exp_trigger': identifier not found
src/pyvcam/pvcmodule.cpp(1323): error C2065: 'PL_SW_TRIG_STATUS_TRIGGERED': undeclared identifier
src/pyvcam/pvcmodule.cpp(1371): error C2039: 'imageFormat': is not a member of 'md_frame_header'
C:\Program Files\Photometrics\PVCamSDK/inc/pvcam.h(924): note: see declaration of 'md_frame_header'
src/pyvcam/pvcmodule.cpp(1371): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1372): error C2039: 'imageCompression': is not a member of 'md_frame_header'
C:\Program Files\Photometrics\PVCamSDK/inc/pvcam.h(924): note: see declaration of 'md_frame_header'
src/pyvcam/pvcmodule.cpp(1372): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1375): error C2065: 'md_frame_header_v3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1375): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1375): error C2061: syntax error: identifier 'md_frame_header_v3'
src/pyvcam/pvcmodule.cpp(1376): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1376): error C2227: left of '->timestampBOF' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1376): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1376): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1377): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1377): error C2227: left of '->timestampEOF' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1377): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1377): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1378): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1378): error C2227: left of '->exposureTime' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1378): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1378): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1379): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1379): error C2227: left of '->bitDepth' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1379): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1379): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1380): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1380): error C2227: left of '->colorMask' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1380): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1380): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1381): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1381): error C2227: left of '->flags' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1381): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1381): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1382): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1382): error C2227: left of '->extendedMdSize' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1382): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1382): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1383): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1383): error C2227: left of '->imageFormat' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1383): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1383): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1384): error C2065: 'pMetaDataFrameHeaderV3': undeclared identifier
src/pyvcam/pvcmodule.cpp(1384): error C2227: left of '->imageCompression' must point to class/struct/union/generic type
src/pyvcam/pvcmodule.cpp(1384): note: type is 'unknown-type'
src/pyvcam/pvcmodule.cpp(1384): error C2660: 'PyDict_SetItem': function does not take 2 arguments
src/pyvcam/pvcmodule.cpp(1405): error C2039: 'roiDataSize': is not a member of 'md_frame_roi_header'
C:\Program Files\Photometrics\PVCamSDK/inc/pvcam.h(957): note: see declaration of 'md_frame_roi_header'
src/pyvcam/pvcmodule.cpp(1405): error C2660: 'PyDict_SetItem': function does not take 2 arguments
error: command 'C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe' failed with exit code 2

@jlaydevant
Copy link

jlaydevant commented Feb 1, 2024

I have been running into the same issue for days and I can't find a solution. I tried to uninstall and reinstall VS studio with different version (ie version MSVC) and it always throws out the same error.
Any help would be really appreciated!

(I'm using Windows 11)

@vondrejPM
Copy link
Contributor

Hi,
In order to run the PyVCAM adaptor, I would recommend downloading the latest PVCAM and PVCAM_SDK.

As for the installation, you will need to open command prompt and navigate to the folder with the setup.py and run "python setup.py install". In this case, the python stands for the python.exe. Provided that you use Python 3.* this should work just fine.

@jlaydevant
Copy link

Hi,
Thanks for your answer, I installed the latest versions for both PVCAM and PYVCAM_SDK and it indeed worked smoothly!
Thansk again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants