shz9 / viprs

Variational Inference of Polygenic Risk Scores
https://shz9.github.io/viprs/
MIT License
19 stars 1 forks source link

Error in tutorial with LDMatrix.load() #6

Closed nlapier2 closed 3 months ago

nlapier2 commented 3 months ago

Hello,

I was trying out the Getting Started procedure in a python shell, and the magenpy steps worked, but upon running v = vp.VIPRS(gdl) I got the following error:

>>> v = vp.VIPRS(gdl)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/nlapier2/project-mstephens/miniconda3/envs/viprs_env/lib/python3.11/site-packages/viprs/model/VIPRS.py", line 163, in __init__
    ld_mat.load(return_symmetric=True, fill_diag=True, dtype=dtype)
TypeError: LDMatrix.load() got an unexpected keyword argument 'fill_diag'

This occurred whether I set up conda or a venv following the installation instructions, and whether I used python 3.8 or python 3.11.

Any help is much appreciated.

shz9 commented 3 months ago

Hi @nlapier2 ,

This issue is due to currently-evolving interface of LDMatrix in magenpy. I haven't published the latest version of viprs to PyPI yet (still iterating over some improvements). Do you mind trying to install the latest version of viprs from GitHub directly?

pip install git+https://github.com/shz9/viprs

Let me know If you still see issues with this.

nlapier2 commented 3 months ago

That seems to work -- thanks!