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

I have an issue installing the package #9

Open
annecvdw opened this issue Feb 16, 2024 · 2 comments
Open

I have an issue installing the package #9

annecvdw opened this issue Feb 16, 2024 · 2 comments

Comments

@annecvdw
Copy link

I have clone the repository.
When I run pip install infotheory I get the following errors:

Collecting infotheory
Using cached infotheory-1.0.01.tar.gz (19 kB)
Preparing metadata (setup.py) ... done
Building wheels for collected packages: infotheory
Building wheel for infotheory (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [23 lines of output]
C:\Users\a-v-d\anaconda3\envs\MasterThesis\lib\site-packages\setuptools\dist.py:314: InformationOnly: Normalizing '1.0.01' to '1.0.1'
self.metadata.version = self._normalize_version(self.metadata.version)
PyLinker.cpp
C:\Users\a-v-d\AppData\Local\Temp\pip-install-__062f80\infotheory_d9c2c9609954478b9b95cf02d1db283a\infotheory\InfoTools.h(71): warning C4244: 'argument': conversion from 'double' to 'EltType', possible loss of data
with
[
EltType=int
]
C:\Users\a-v-d\AppData\Local\Temp\pip-install-__062f80\infotheory_d9c2c9609954478b9b95cf02d1db283a\infotheory\InfoTools.h(79): warning C4244: 'argument': conversion from 'double' to 'EltType', possible loss of data
with
[
EltType=int
]
C:\Users\a-v-d\AppData\Local\Temp\pip-install-__062f80\infotheory_d9c2c9609954478b9b95cf02d1db283a\infotheory\InfoTools.h(1333): warning C4244: 'argument': conversion from 'double' to 'EltType', possible loss of data
with
[
EltType=int
]
./infotheory\PyLinker.cpp(25): warning C4244: 'initializing': conversion from 'Py_ssize_t' to 'int', possible loss of data
./infotheory\PyLinker.cpp(33): warning C4244: 'initializing': conversion from 'Py_ssize_t' to 'int', possible loss of data
LINK : error LNK2001: unresolved external symbol PyInit_infotheoryClass
build\temp.win-amd64-cpython-39\Release./infotheory\infotheoryClass.cp39-win_amd64.lib : fatal error LNK1120: 1 unresolved externals
error: command 'C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.39.33519\bin\HostX86\x64\link.exe' failed with exit code 1120
[end of output]

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

I do have BuildTools downloaded on my computer.
Is there anythin I am missing?

@xinhuayu
Copy link

xinhuayu commented Mar 7, 2024

changing external module: "infotheory" to "InfoTools" in the setup.py to match the actual class "InfoTools" in CPP and Header files. This seems to fix the compiling problem

@nataliekoh
Copy link

Getting the same error as @annecvdw; @xinhuayu's fix doesn't seem to work. Has anyone else encountered this problem as well?

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