-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Adding Terminal Window to Jupyter Cells so all Colab users (free and pro) can train with Nerfstudio #2870
Merged
brentyi
merged 20 commits into
nerfstudio-project:main
from
AntonioMacaronio:colab-training-fix
Mar 1, 2024
Merged
Adding Terminal Window to Jupyter Cells so all Colab users (free and pro) can train with Nerfstudio #2870
brentyi
merged 20 commits into
nerfstudio-project:main
from
AntonioMacaronio:colab-training-fix
Mar 1, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@jfenton888 thank you for the catch! I've updated the PR with this change |
Thank you!!! Going to test this soon and see if anything is needed, but it looks like everything is good! |
ginazhouhuiwu
approved these changes
Feb 22, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything seemed good to me, sorry for the delay and thank you again!!
Michael-Spleenlab
pushed a commit
to Michael-Spleenlab/nerfstudio
that referenced
this pull request
Apr 26, 2024
…pro) can train with Nerfstudio (nerfstudio-project#2870) * adding terminal window to jupyter cells for free colab users to train and render * updating torchaudio package dependency * deleting viewer connection cell, replaced with ns-train's sharable URL viewer link * fixing flying apostrophe * fixing pip torch download installation typo --------- Co-authored-by: Gina Wu <[email protected]>
ArpegorPSGH
pushed a commit
to ArpegorPSGH/nerfstudio
that referenced
this pull request
Jun 22, 2024
…pro) can train with Nerfstudio (nerfstudio-project#2870) * adding terminal window to jupyter cells for free colab users to train and render * updating torchaudio package dependency * deleting viewer connection cell, replaced with ns-train's sharable URL viewer link * fixing flying apostrophe * fixing pip torch download installation typo --------- Co-authored-by: Gina Wu <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Background and Issues:
ns-train
in a jupyter cell, and this has been made apparent in several issues below. (Pro users can get around this, but it's still problematic and explained below)The culprit of this bug is that as of Feb 2024, Google Colab runs python 3.10, which has an issue with nerfstudio's rich console outputs. In particular, a python module called
shutil
will set the terminal size to 0 when dealing with rich console outputs. As a result, nothing gets printed, and Colab will shutdown the cell and terminate early before training can begin.This is mentioned in other python modules which use the rich console output, and a complete breakdown on the issue is detailed here.
Overview of Changes
colab-xterm
module, we are able to create a terminal window in a jupyter cell output.ns-train
and they will be able to generate the viser/viewer link to see the training progressns-train
's sharable URL linkImpact and Other Notes
While Pro Colab users can get around this by running
ns-train
in their terminal window, Colab only allows for 1 terminal window. Therefore, to run the render command, pro users need to Ctrl+C the training process hosting the viser/viewer link, which can be quite irritating - especially if they want to make more than just 1 render path.Therefore, even once Colab upgrades to python 3.11 in April 2024, there is still a need to have at least 2 terminal windows, which is possible with this change.
To run
ns-train
, users (free and pro) simply need to follow the instructions to copy and paste the command into the terminal window. This is pretty clear to follow, and looks like the following: