luntergroup / smcsmc

Demographic inference from whole genomes
GNU General Public License v3.0
11 stars 4 forks source link

Problems with installation guides #68

Open arredondos opened 5 years ago

arredondos commented 5 years ago

Hello. I'm having trouble following the 'Installation from Source' instructions. The line:

git clone git@github.com:luntergroup/smcsmc.git git-smcsmc

fails with Permission denied (publickey). I tried this on different computers. If, alternatively, I clone the repository with:

git clone https://github.com/luntergroup/smcsmc git-smcsmc

then the next instruction

git submodule init

fails with No url found for submodule path 'tests/utility' in .gitmodules.

On the other hand, when trying to follow the instructions here, then after installing conda, the line

conda --add channel conda-forge

fails with: CommandNotFoundError: No command 'conda channel'.

I am currently lost as to how we should proceed in order to obtain a working version of the library.

Thank you.

Chris1221 commented 5 years ago

Hi Armando, sorry for the troubles. You have the dubious honour of being one of the first to test out these guides. A few issues here, mostly mine.

  1. Cloning

This part I don't think is an issue with the repository, I think it may be that your RSA keys are not properly configured on the different machines that you tried. There are some instructions here from github if you're passionate about getting this to work, otherwise the second method (https) is entirely equivalent and I wouldn't worry about it.

  1. Submodule init

This one is my fault, I left a file in the master branch by accident which falsely registers an old submodule. If you switch the devel branch and try it again, it should work (at least for me with a fresh clone).

So:

git clone https://github.com/luntergroup/smcsmc git-smcsmc
cd git-smcsmc
git checkout devel
git submodule init

Then the rest of the guide. I'll fix that up when I merge in the new features on devel. Let me know if that works for you.

  1. Conda

Again, a typo from me. If you try

conda config --add channels conda-forge

Rather than the version in the documentation, that should work fine. Sorry about that. I'll update it right away, thank you for finding these errors.

Please let me know if that works and if you encounter more errors, I'd love to get this working for you.

Best wishes, and thanks again.

Chris1221 commented 5 years ago

As an update, the documentation has been changed to reflect the above, as has the README on the devel branch. The submodule issue will need to wait until I merge the devel branch, but I think most people will be installing from conda so it won't be too much of an issue.

I've also gone through and tested all the code in the documentation and removed some that was previously functional but broke with updates -- the 'getting started guide' example should now be functional if smcsmc installs correctly and you use the toy.seg that I provide. I'm working on more tutorials for converting from vcf as well. If you try it, let me know if it works for you too.

arredondos commented 5 years ago

Hello Chris. Thanks for your support, it has been very helpful.

I can confirm now that following the instructions at readthedocs in Linux produces a working installations of the package (albeit with some Python warnings thrown when importing the library).

Regarding the installation from source (which is no longer necessary as far as I can tell, but still) git submodule init worked after switching to the devel branch, but then git submodule update failed with the same RSA keys error. Again, this is just an FYI since the conda installation is easier and it works (maybe you can already remove the disclaimer that recommends using the manual installation?).

I specifically mentioned Linux earlier because I am on Windows, and haven't been able to make it work for me. The conda for Windows installation stops with:

Collecting package metadata: done
Solving environment: failed

PackagesNotFoundError: The following packages are not available from current channels:

  - smcsmc

Alternatively, using the Windows Subsystem for Linux (WSL) correctly installs the package, but trying to use it fails as it seems like the library tries to load the graphical back-end right away, which WSL has no support for (command-line mode only). But this probably deserves it own separate issue.

Thanks again! Armando.

arredondos commented 5 years ago

Just for the sake of completeness, I tried the conda installation on Mac OS, and it fails with the same error as in Windows:

Collecting package metadata: done
Solving environment: failed

PackagesNotFoundError: The following packages are not available from current channels:

  - smcsmc

Current channels:

  - https://conda.anaconda.org/luntergroup/osx-64
  - https://conda.anaconda.org/luntergroup/noarch
  - https://conda.anaconda.org/terhorst/osx-64
  - https://conda.anaconda.org/terhorst/noarch
  - https://conda.anaconda.org/conda-forge/osx-64
  - https://conda.anaconda.org/conda-forge/noarch
  - https://repo.anaconda.com/pkgs/main/osx-64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/free/osx-64
  - https://repo.anaconda.com/pkgs/free/noarch
  - https://repo.anaconda.com/pkgs/r/osx-64
  - https://repo.anaconda.com/pkgs/r/noarch

To search for alternate channels that may provide the conda package you're
looking for, navigate to

    https://anaconda.org

and use the search bar at the top of the page.
Chris1221 commented 5 years ago

Hey Armando, thanks for the update. I'm glad that we got something working in Linux at the very least. The RSA issue is interesting, and I'm not quite sure what to make of it. A quick workaround would be to edit the paths in the .gitmodules to use HTTPS rather than SSH as you have previously done with cloning, but as you say, it may be moot at the moment.

You have really run the gamut of operating systems! I should make this a lot more obvious (I thought I had put it in multiple places in the documentation, but it turns out it's only there once in passing), but currently I've only uploaded binaries for smcsmc on linux, which is why it is at least installing on the WSL, but is completely not found on mac or pure windows. The mac version is on my near-future to-do list. Installing for windows is, I'll admit, a bit outside my wheelhouse. I'm very unfamiliar with the whole ecosystem and wouldn't really know where to start getting it all functional there with multithreading and all that jazz. So unfortunately I think we're constrained to linux at the moment and mac in the near future. Very sorry that it wasn't more clear from the documentation, I appreciate you plowing through it and checking!

I really appreciate the feedback re: the graphics device, as I suspect that the WSL error and the linux warning are stemming from the same line of code. I'm going to spend some time today trying to find a way to get rid of both, as I feel like I solved a complex problem in a too-simple way in the current code. I'll keep you updated if I manage to make any progress there.

Thanks again!