Spaces:
Sleeping
Sleeping
| import gradio as gr | |
| with gr.Blocks() as demo: | |
| gr.Markdown( | |
| value=""" | |
| ## Start logging with Trackio 🤗 | |
| To start logging to this Trackio dashboard, first make sure you have the Trackio library installed. You can do this by running: | |
| ```bash | |
| pip install trackio | |
| ``` | |
| Then, start logging to this Trackio dashboard by passing in the `space_id` to `trackio.init()`: | |
| ```python | |
| import trackio | |
| trackio.init(project="my-project", space_id="{}") | |
| ``` | |
| Then call `trackio.log()` to log metrics. | |
| ```python | |
| for i in range(10): | |
| trackio.log({{"loss": 1/(i+1)}}) | |
| ``` | |
| Finally, call `trackio.finish()` to finish the run. | |
| ```python | |
| trackio.finish() | |
| ``` | |
| """ ) | |
| demo.launch() |