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

Building failure.Thanks for your help. #36

Open
JimWang151 opened this issue Aug 22, 2024 · 5 comments
Open

Building failure.Thanks for your help. #36

JimWang151 opened this issue Aug 22, 2024 · 5 comments

Comments

@JimWang151
Copy link

Below is the error message:

D:\ProgramData\anaconda3\envs\anitalker\lib\site-packages\setuptools_init_.py:85: _DeprecatedInstaller: setuptools.installer and fetch_build_eggs are deprecated.
!!

    ********************************************************************************
    Requirements should be satisfied by a PEP 517 installer.
    If you are using pip, you can try `pip install --use-pep517`.
    ********************************************************************************

!!
dist.fetch_build_eggs(dist.setup_requires)
D:\ProgramData\anaconda3\envs\anitalker\lib\site-packages\setuptools_distutils\dist.py:268: UserWarning: Unknown distribution option: 'tests_require'
warnings.warn(msg)
running build
running build_py
copying ctc_segmentation\ctc_segmentation.py -> build\lib.win32-cpython-39\ctc_segmentation
copying ctc_segmentation\partitioning.py -> build\lib.win32-cpython-39\ctc_segmentation
copying ctc_segmentation_init_.py -> build\lib.win32-cpython-39\ctc_segmentation
running build_ext
building 'ctc_segmentation.ctc_segmentation_dyn' extension
"d:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\bin\HostX86\x86\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -ID:\ProgramData\anaconda3\envs\anitalker\lib\site-packages\numpy_core\include -ID:\ProgramData\anaconda3\envs\anitalker\include -ID:\ProgramData\anaconda3\envs\anitalker\Include "-Id:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\include" "-Id:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\ATLMFC\include" "-Id:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\VS\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" /Tcctc_segmentation/ctc_segmentation_dyn.c /Fobuild\temp.win32-cpython-39\Release\ctc_segmentation/ctc_segmentation_dyn.obj
ctc_segmentation_dyn.c
D:\ProgramData\anaconda3\envs\anitalker\lib\site-packages\numpy_core\include\numpy\npy_1_7_deprecated_api.h(14) : Warning Msg: Using deprecated NumPy API, disable it with #define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
ctc_segmentation/ctc_segmentation_dyn.c(3726): error C2039: "subarray": 不是 "_PyArray_Descr" 的成员
D:\ProgramData\anaconda3\envs\anitalker\lib\site-packages\numpy_core\include\numpy\ndarraytypes.h(618): note: 参见“_PyArray_Descr”的声明
ctc_segmentation/ctc_segmentation_dyn.c(3726): error C2198: “_Py_INCREF”: 用于调用的参数太少
ctc_segmentation/ctc_segmentation_dyn.c(3727): error C2039: "subarray": 不是 "_PyArray_Descr" 的成员
D:\ProgramData\anaconda3\envs\anitalker\lib\site-packages\numpy_core\include\numpy\ndarraytypes.h(618): note: 参见“_PyArray_Descr”的声明
ctc_segmentation/ctc_segmentation_dyn.c(4870): warning C4244: “=”: convert from“double”to“float”,maybe miss data
error: command 'd:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.40.33807\bin\HostX86\x86\cl.exe' failed with exit code 2

@JimWang151
Copy link
Author

My python version:3.9.19

Thanks.

@cedilla1312
Copy link

@JimWang151 Did you test with different Numpy version? Is your version 1.7.0? I was running ESPnet2 custom script after GPU drivers upgrade and I could not run it with similar error pertaining to NDARRAY after upgrading pytorch,python (to 3.9.19) ,tvision,taudio until I have installed compatible version of Numpy, maybe you could try installing Numpy 1.20.3 as I have in conda. If it won't resolve, try downgrading to your previous version of numpy with pip, then ctc_segmentation_dyn.c needs to be edited - advanced and probably not effective. Did you try pip install --use-pep517 ?

@JimWang151
Copy link
Author

@JimWang151 Did you test with different Numpy version? Is your version 1.7.0? I was running ESPnet2 custom script after GPU drivers upgrade and I could not run it with similar error pertaining to NDARRAY after upgrading pytorch,python (to 3.9.19) ,tvision,taudio until I have installed compatible version of Numpy, maybe you could try installing Numpy 1.20.3 as I have in conda. If it won't resolve, try downgrading to your previous version of numpy with pip, then ctc_segmentation_dyn.c needs to be edited - advanced and probably not effective. Did you try pip install --use-pep517 ?

Thanks for your help.

But after i reinstalled Numpy 1.20.3,it does not work.

Can u tell me how to edit 'ctc_segmentation_dyn.c'?

@cedilla1312
Copy link

I advise you wait for developer's answer, never built this software.

My further suggestions:
Try to compile it with mingw-w64 (prolly won't do anything), try numpy 1.21;1.24; 1.19.5, the culprit could be Cython works with only old versions of Numpy (specifically its Numpy API) - Cython-Numpy mismatch, pip install --upgrade cython - another option.

Please provide additional info for devs on Numpy, Pytorch/Torch, Cython versions, compiler setup/flags or in other words, steps to repro like here.

Related links:
https://numpy.org/neps/nep-0053-c-abi-evolution.html#impact-on-cython-users
alekseik1/ifg-py@bd18222 - compatibility matrix
cython/cython#6249
cython/cython#6249 (comment) - editing ctc_segmentation_dyn.pyx - adding this line somewhere near the top of the file - probably won't fix and only trigger an error instead of warning
https://numpy.org/neps/nep-0029-deprecation_policy.html#support-table
https://github.com/numpy/numpy/blob/3113704a745e6bb8a3ce7c474ef199ee918e1e81/numpy/_core/code_generators/numpy_api.py
https://numpy.org/doc/stable/reference/c-api/deprecations.html#deprecation-mechanism-npy-no-deprecated-api
h5py/h5py#1538 (comment)

@JimWang151
Copy link
Author

I advise you wait for developer's answer, never built this software.

My further suggestions: Try to compile it with mingw-w64 (prolly won't do anything), try numpy 1.21;1.24; 1.19.5, the culprit could be Cython works with only old versions of Numpy (specifically its Numpy API) - Cython-Numpy mismatch, pip install --upgrade cython - another option.

Please provide additional info for devs on Numpy, Pytorch/Torch, Cython versions, compiler setup/flags or in other words, steps to repro like here.

Related links: https://numpy.org/neps/nep-0053-c-abi-evolution.html#impact-on-cython-users alekseik1/ifg-py@bd18222 - compatibility matrix cython/cython#6249 cython/cython#6249 (comment) - editing ctc_segmentation_dyn.pyx - adding this line somewhere near the top of the file - probably won't fix and only trigger an error instead of warning https://numpy.org/neps/nep-0029-deprecation_policy.html#support-table https://github.com/numpy/numpy/blob/3113704a745e6bb8a3ce7c474ef199ee918e1e81/numpy/_core/code_generators/numpy_api.py https://numpy.org/doc/stable/reference/c-api/deprecations.html#deprecation-mechanism-npy-no-deprecated-api h5py/h5py#1538 (comment)

Thanks for you help.I will try your suggestion.

This issue can be closed.Thanks 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

2 participants