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

Tunneling support, related UI improvements #98

Merged
merged 2 commits into from
Sep 16, 2023
Merged

Tunneling support, related UI improvements #98

merged 2 commits into from
Sep 16, 2023

Conversation

brentyi
Copy link
Collaborator

@brentyi brentyi commented Sep 16, 2023

This PR adds support for a Gradio-inspired share= argument to viser.ViserServer(). This creates a shareable link that will be generally convenient + useful for Colab support. (cc @ginazhouhuiwu)

What we have is similar to #71, but doesn't require Rust or Cargo; multiprocessing + standard asyncio streams are used to handle network traffic.

Example usage:

Screen.Recording.2023-09-15.at.11.43.22.PM.mov

I also made some client updates, notably wss/https support. 🙂

@brentyi brentyi requested a review from tancik September 16, 2023 06:55
@brentyi
Copy link
Collaborator Author

brentyi commented Sep 16, 2023

(note: the code feels a bit chaotic to me, but assuming things work I think we can merge as-is and do some cleanup passes after CVPR)

Copy link
Collaborator

@tancik tancik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great feature, LGTM!

@brentyi brentyi merged commit dde0373 into main Sep 16, 2023
11 checks passed
@brentyi brentyi deleted the brent/tunneling branch September 16, 2023 17:58
@smart4654154
Copy link

Dear author,I have followed your example successfully, but unfortunately, when I attempted to use other examples, I encountered difficulties, especially with examples like Python/Examples/02_Gui.py --share. Could you please guide me on the correct operation for this? Additionally, how can I obtain a shareable link when running my data with Colab? (Unfortunately, being a beginner with limited proficiency in English, this might be a simple question, but I genuinely don't know how to resolve it. Thank you very much for your help.)

@brentyi
Copy link
Collaborator Author

brentyi commented Jan 18, 2024

Hi!

On the CLI side, this --share argument was only implemented in the SMPL-X example:

share: bool = False,
) -> None:
server = viser.ViserServer()
server.set_up_direction("+y")
if share:
server.request_share_url()

For getting the URL, see: https://viser.studio/server/#viser.ViserServer.request_share_url

yzslab pushed a commit to yzslab/viser that referenced this pull request Oct 20, 2024
* Experimental tunneling support, related UI improvements

* Appease mypy
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

Successfully merging this pull request may close these issues.

3 participants