Visualize and analyze tables

Visualize and analyze W&B Tables.

Customize your W&B Tables to answer questions about your machine learning model’s performance, analyze your data, and more.

Interactively explore your data to:

  • Compare changes precisely across models, epochs, or individual examples
  • Understand higher-level patterns in your data
  • Capture and communicate your insights with visual samples

Compare two tables

Compare two tables with a merged view or a side-by-side view. For example, the image below demonstrates a table comparison of MNIST data.

Left: mistakes after 1 training epochs, Right: mistakes after 5 epochs

Follow these steps to compare two tables:

  1. Go to your project in the W&B App.
  2. Select the artifacts icon on the left panel.
  3. Select an artifact version.

In the following image we demonstrate a model’s predictions on MNIST validation data after each of five epochs (view interactive example here).

Click on 'predictions' to view the Table
  1. Hover over the second artifact version you want to compare in the sidebar and click Compare when it appears. For example, in the image below we select a version labeled as “v4” to compare to MNIST predictions made by the same model after 5 epochs of training.
Preparing to compare model predictions after training for 1 epoch (v0, shown here) vs 5 epochs (v4)

Merged view

Initially you see both tables merged together. The first table selected has index 0 and a blue highlight, and the second table has index 1 and a yellow highlight. View a live example of merged tables here.

In the merged view, numerical columns appears as histograms by default

From the merged view, you can

  • choose the join key: use the dropdown at the top left to set the column to use as the join key for the two tables. Typically this is the unique identifier of each row, such as the filename of a specific example in your dataset or an incrementing index on your generated samples. Note that it’s currently possible to select any column, which may yield illegible tables and slow queries.
  • concatenate instead of join: select “concatenating all tables” in this dropdown to union all the rows from both tables into one larger Table instead of joining across their columns
  • reference each Table explicitly: use 0, 1, and * in the filter expression to explicitly specify a column in one or both table instances
  • visualize detailed numerical differences as histograms: compare the values in any cell at a glance

Side-by-side view

To view the two tables side-by-side, change the first dropdown from “Merge Tables: Table” to “List of: Table” and then update the “Page size” respectively. Here the first Table selected is on the left and the second one is on the right. Also, you can compare these tables vertically as well by clicking on the “Vertical” checkbox.

In the side-by-side view, Table rows are independent of each other.
  • compare the tables at a glance: apply any operations (sort, filter, group) to both tables in tandem and spot any changes or differences quickly. For example, view the incorrect predictions grouped by guess, the hardest negatives overall, the confidence score distribution by true label, etc.
  • explore two tables independently: scroll through and focus on the side/rows of interest

Visualize how values change throughout your runs

View how values you log to a table change throughout your runs with a step slider. Slide the step slider to view the values logged at different steps. For example, you can view how the loss, accuracy, or other metrics change after each run.

he slider uses a key to determine the step value. The default key for the slider is _step, a special key that W&B automatically logs for you. The _step key is an integer that increments by 1 each time you call wandb.log() in your code.

To add a step slider to a W&B Table:

  1. Navigate to your project’s workspace.
  2. Click Add panel in the top right corner of the workspace.
  3. Select Query panel.
  4. Within the query expression editor, select runs and press Enter on your keyboard.
  5. Click the gear icon to view the settings for the panel.
  6. Set Render As selector to Stepper.
  7. Set Stepper Key to _step or the key to use as the unit for the step slider.

The following image shows a query panel with three W&B runs and the values they logged at step 295.

Query panel with three W&B runs and the values they logged at step 295 using the step slider feature.

Within the W&B App UI you may notice duplicate values for multiple steps. This duplication can occur if multiple runs log the same value at different steps, or if a run does not log values at every step. If a value is missing for a given step, W&B uses the last value that was logged as the slider key.

Custom step key

The step key can be any numeric metric that you log in your runs as the step key, such as epoch or global_step. When you use a custom step key, W&B maps each value of that key to a step (_step) in the run.

This table shows how a custom step key epoch maps to _step values for three different runs: serene-sponge, lively-frog, and vague-cloud. Each row represents a call to wandb.log() at a particular _step in a run. The columns show the corresponding epoch values, if any, that were logged at those steps. Some _step values are omitted to save space.

The first time wandb.log was called, none of the runs logged an epoch value, so the table shows empty values for epoch.

_step vague-cloud (epoch) lively-frog(epoch) serene-sponge (epoch)
1
2 1
4 1 2
5 1
6 3
8 2 4
10 5
12 3 6
14 7
15 2
16 4 8
18 9
20 3 5 10

Now, if the slider is set to epoch = 1, the following happens:

  • vague-cloud finds epoch = 1 and returns the value logged at _step = 5
  • lively-frog finds epoch = 1 and returns the value logged at _step = 4
  • serene-sponge finds epoch = 1 and returns the value logged at _step = 2

If the slider is set to epoch = 9:

  • vague-cloud also doesn’t log epoch = 9, so W&B uses the latest prior value epoch = 3 and returns the value logged at _step = 20
  • lively-frog doesn’t log epoch = 9, but the latest prior value is epoch = 5 so it returns the value logged at _step = 20
  • serene-sponge finds epoch = 9 and return the value logged at _step = 18

Compare artifacts

You can also compare tables across time or model variants.

Compare tables across time

Log a table in an artifact for each meaningful step of training to analyze model performance over training time. For example, you could log a table at the end of every validation step, after every 50 epochs of training, or any frequency that makes sense for your pipeline. Use the side-by-side view to visualize changes in model predictions.

For each label, the model makes fewer mistakes after 5 training epochs (R) than after 1 (L)

For a more detailed walkthrough of visualizing predictions across training time, see this report and this interactive notebook example.

Compare tables across model variants

Compare two artifact versions logged at the same step for two different models to analyze model performance across different configurations (hyperparameters, base architectures, and so forth).

For example, compare predictions between a baseline and a new model variant, 2x_layers_2x_lr, where the first convolutional layer doubles from 32 to 64, the second from 128 to 256, and the learning rate from 0.001 to 0.002. From this live example, use the side-by-side view and filter down to the incorrect predictions after 1 (left tab) versus 5 training epochs (right tab).

After 1 epoch, performance is mixed: precision improves for some classes and worsens for others.
After 5 epochs, the 'double' variant is catching up to the baseline.

Save your view

Tables you interact with in the run workspace, project workspace, or a report automatically saves their view state. If you apply any table operations then close your browser, the table retains the last viewed configuration when you next navigate to the table.

To save a table from a workspace in a particular state, export it to a W&B Report. To export a table to report:

  1. Select the kebob icon (three vertical dots) in the top right corner of your workspace visualization panel.
  2. Select either Share panel or Add to report.
Share panel creates a new report, Add to report lets you append to an existing report.

Examples

These reports highlight the different use cases of W&B Tables: