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

Update installation guide to work better for windows, and also simplify setup in general #3501

Open
michael-vedeler opened this issue Oct 27, 2024 · 2 comments

Comments

@michael-vedeler
Copy link

michael-vedeler commented Oct 27, 2024

Intro

So the issue i have had is that i got a new laptop recently, and had to set it up from scratch - and since i only have community edition of visual studio, i simply only have the newest version available (today that is 17.11.x, which is not compatible with cuda 11.8).

I have tried, i think, every single possible way to install nerfstudio on my computer - trying to do the unofficial upgrade of the cuda toolkit to 12.4 and install a newer version of torch and so on, but that did only lead to more headaches. I have tried to install an earlier version of visual studio build tools (17.8, that is compatible with cuda 11.8), that almost worked, but crashed when running ns-train with g-splat.

So to sum it up - i spent an embarrassingly long time yesterday to try to install nerfstudio on my new laptop..

The solution
So when i woke up today, i remembered that it is possible to install WSL to run linux on windows computers - and guess if it worked? It worked almost out of the box.

WSL is also especially nice, since you dont need to open a virtual machine or anything, it simply runs as its own command prompt on windows - just also being able to run linux code!

I had to do some small tweaks, first of which, was to ensure miniconda was installed in the linux environment:

wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh bash Miniconda3-latest-Linux-x86_64.sh
Activate it:
source ~/.bashrc

Set the g++ version to 11:

sudo apt update sudo apt install gcc-11 g++-11 sudo apt install -y build-essential

I also made sure that i set GCC-11 as the Default for the Installation Process (not sure if this is strictly necessary):

export CC=/usr/bin/gcc-11 export CXX=/usr/bin/g++-11

I also had to make sure the cuda toolkit was installed correctly in WSL:

sudo apt update sudo apt install nvidia-cuda-toolkit

When ensuring all of the previous steps are done, you simply can run the installation guide for linux, and it worked (for me at least)

I really hope this helps anyone experiencing issues installing nerfstudio on newer windows pcs, and maybe hopefully ends up in the actual guide for installing nerfstudio! :D Let's make it easier for everyone to use these amazing tools!

Also a side note; if anyone with better software knowledge then me read through this, the order of things here might be a bit of (thats because i fixed issues as they came when trying to install nerfstudio..).

@michael-vedeler
Copy link
Author

WSL install guide here: https://learn.microsoft.com/en-us/windows/wsl/install

@thomaspingel
Copy link

Nice. I tried to do this last year on WSL and got nowhere. I did need to set GCC-11 as the default for it to work.

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

2 participants