Pyfhel
Pyfhel copied to clipboard
`ImportError` when running `from Pyfhel import Pyfhel`
Description
Trying to run code from steps 1-3 in Pyfhel's MultDepth and Relinearization tutorial results in an ImportError
when running from Pyfhel import Pyfhel
.
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "/Users/kiran/Documents/workspace/Projects/Q-SECURE/project/test/test.py", line 5, in <module>
from Pyfhel import Pyfhel
File "/Users/kiran/miniconda3/envs/q-secure_env/lib/python3.11/site-packages/Pyfhel/__init__.py", line 1, in <module>
from .Pyfhel import Pyfhel
ImportError: dlopen(/Users/kiran/miniconda3/envs/q-secure_env/lib/python3.11/site-packages/Pyfhel/Pyfhel.cpython-311-darwin.so, 0x0002): symbol not found in flat namespace '__ZN4seal13parms_id_zeroE'
Code To Reproduce Error
Activate conda virtual environment and install Pyfhel via pip
. I also set/added the environment variables from Pyfhel's Installing a C/C++ Compiler instructions to my .bash_profile
. Up until now, everything's fine. Running the following command is what produces the aforementioned errors:
python -m project.test.test
Expected behavior Successfully run code from steps 1-3 in Pyfhel's MultDepth and Relinearization tutorial, with the described outputs printed to my terminal.
Setup:
- OS: Sonoma 14.4
- Python: 3.11.8
- C compiler version: [Clang 14.0.6] on darwin
- Pyfhel Version: 3.4.2
@lynkos The error indicates that SEAL library was not installed/found alongside Pyfhel.
How did you install Pyfhel
? If possible, you could install it directly with pip
instead of via conda
, I recall some issues with the latter method.
Hi @ibarrond, thanks for reaching out!
How did you install
Pyfhel
? If possible, you could install it directly withpip
instead of viaconda
, I recall some issues with the latter method.
I installed Pyfhel
(in my conda
environment) as described in README.md
:
pip install Pyfhel
When that didn't work, I uninstalled it and reinstalled it by cloning the repo:
git clone --recursive https://github.com/ibarrond/Pyfhel.git
pip install .
Unfortunately, I still got the same error.
Hi @lynkos were you able to resolve the issue? I am getting the same error.