2019-03-03 15:33:34 +08:00
|
|
|
|
<html>
|
|
|
|
|
<head>
|
2019-04-08 06:06:02 +08:00
|
|
|
|
<!-- Global site tag (gtag.js) - Google Analytics -->
|
|
|
|
|
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-123499302-2"></script>
|
|
|
|
|
<script>
|
|
|
|
|
window.dataLayer = window.dataLayer || [];
|
|
|
|
|
function gtag(){dataLayer.push(arguments);}
|
|
|
|
|
gtag('js', new Date());
|
|
|
|
|
|
|
|
|
|
gtag('config', 'UA-123499302-2');
|
|
|
|
|
</script>
|
2019-04-01 07:16:10 +08:00
|
|
|
|
<title>Gradio</title>
|
2019-03-03 15:33:34 +08:00
|
|
|
|
<link href="https://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
|
|
|
|
|
<link href="style/style.css" rel="stylesheet">
|
|
|
|
|
<link href="style/sharing.css" rel="stylesheet">
|
|
|
|
|
<link href="style/gradio.css" rel="stylesheet">
|
|
|
|
|
</head>
|
|
|
|
|
<body>
|
|
|
|
|
<nav>
|
|
|
|
|
<img src="img/logo_inline.png" />
|
2019-04-01 07:16:10 +08:00
|
|
|
|
<a href="index.html">Gradio</a>
|
2019-03-03 15:33:34 +08:00
|
|
|
|
<a href="getting_started.html">Getting Started</a>
|
|
|
|
|
<a class="selected" href="sharing.html">Sharing</a>
|
2019-04-10 10:54:47 +08:00
|
|
|
|
<a href="blog.html">Blog</a>
|
2019-03-03 15:33:34 +08:00
|
|
|
|
</nav>
|
|
|
|
|
<div class="content">
|
|
|
|
|
<h1>Sharing</h1>
|
2019-04-01 07:16:10 +08:00
|
|
|
|
<p>Gradio comes with built in support for sharing models. When gradio
|
2019-03-03 15:33:34 +08:00
|
|
|
|
launches an interface for a model, it also creates a shareable link that
|
|
|
|
|
can be sent out by the creator to collaborators so they can access the
|
|
|
|
|
interface from their browsers. The link does not require these remote
|
2019-04-01 07:16:10 +08:00
|
|
|
|
users to have gradio, Python, or any environment set up.</p>
|
2019-03-03 15:33:34 +08:00
|
|
|
|
<p>This link, which is printed to the console, is generated by adding
|
|
|
|
|
the parameter <code><span class="var">share</span>=True</code> when
|
|
|
|
|
launching the interface: e.g. <code>io.<span
|
|
|
|
|
class="func">launch(</span><span class="var">share</span>=True<span
|
|
|
|
|
class="func">)</span></code>. The link stays active for 8 hours.
|
2019-04-01 07:16:10 +08:00
|
|
|
|
Other users can access the gradio interface from the link remotely, but
|
2019-03-03 15:33:34 +08:00
|
|
|
|
the model stays on the original host computer. When remote users submit
|
2019-04-01 07:16:10 +08:00
|
|
|
|
inputs to the gradio interface, the browser makes a call to the host
|
2019-03-03 15:33:34 +08:00
|
|
|
|
computer with the input provided. On the host, the model will generate
|
|
|
|
|
the output based on the provided input, and return the output, which
|
|
|
|
|
will be rendered in the remote browser’s output pane. </p>
|
|
|
|
|
<p>Because these remote interfaces will run models on the host machine
|
|
|
|
|
and draw from its compute power, we do not recommend publicly share the
|
|
|
|
|
generated links. Distribute them among trusted colleagues only.</p>
|
|
|
|
|
<div id="sharing_explained">
|
|
|
|
|
<img src="img/sharing_explained.png" /><br>
|
|
|
|
|
When the remote user submits an input from their interface, the model
|
|
|
|
|
executes on the host computer.
|
|
|
|
|
</div>
|
|
|
|
|
<h1>Public Hosting</h1>
|
2019-04-01 07:16:10 +08:00
|
|
|
|
<p>The option for permanent public hosting on gradio servers is coming
|
2019-03-03 15:33:34 +08:00
|
|
|
|
soon! You will be able share your model publicly and collect user input
|
|
|
|
|
data in this upcoming feature.</p>
|
|
|
|
|
</div>
|
|
|
|
|
<footer>
|
|
|
|
|
<img src="img/logo_inline.png" />
|
|
|
|
|
</footer>
|
|
|
|
|
<body>
|
|
|
|
|
</html>
|