HEP-PBSP / SIMUnet

The public code for SIMUnet, a NNPDF based tool to perform simultaneous determination of PDFs and EFT Wilson coefficients.
https://hep-pbsp.github.io/SIMUnet/
GNU General Public License v3.0
2 stars 2 forks source link

vp-setupfit fails because importlib.metadata.PackageNotFoundError: n3fit #59

Closed flonigro closed 4 months ago

flonigro commented 4 months ago

I am trying to run vp-setupfit file.yml following instructions on the Documentation page. In particular, I copied and pasted the runcard on the "simultaneous fit" example and I obtain the followin error:

Traceback (most recent call last):
  File "/home/turing/miniconda3/envs/simunet/bin/n3fit", line 33, in <module>
    sys.exit(load_entry_point('n3fit', 'console_scripts', 'n3fit')())
  File "/home/turing/miniconda3/envs/simunet/bin/n3fit", line 22, in importlib_load_entry_point
    for entry_point in distribution(dist_name).entry_points
  File "/home/turing/miniconda3/envs/simunet/lib/python3.9/importlib/metadata.py", line 542, in distribution
    return Distribution.from_name(distribution_name)
  File "/home/turing/miniconda3/envs/simunet/lib/python3.9/importlib/metadata.py", line 196, in from_name
    raise PackageNotFoundError(name)
importlib.metadata.PackageNotFoundError: n3fit

Moreover, n3fit is correctly installed in my conda env which I have activated when I run the aforementioned runcard.

comane commented 4 months ago

Hello @flonigro, if n3fit is already installed in your env could you please try to do the following

cd simunet_release/n3fit
pip install -e .

you should run the pip install command in the n3fit folder that contains the setup.py file.

Let me know if this solves the issue.

flonigro commented 4 months ago

Thank you @comane! Now, it works.