Skip to content

Show 1D-tensors as bar charts#3769

Merged
teh-cmc merged 2 commits into
mainfrom
cmc/tensor1d_barchart
Oct 10, 2023
Merged

Show 1D-tensors as bar charts#3769
teh-cmc merged 2 commits into
mainfrom
cmc/tensor1d_barchart

Conversation

@teh-cmc
Copy link
Copy Markdown
Contributor

@teh-cmc teh-cmc commented Oct 10, 2023

Relax the bar-chart view's requirements, and strengthen the tensor view's requirements:

  • make bar-chart look for either BarChartIndicator or TensorIndicator
  • make tensor ignore anything with less than 2 dimensions (it can't display those anyway!)

import rerun as rr
import torch
rr.init("tensor", spawn=True)
rr.log("tensor", rr.Tensor(torch.rand(10,)))

image


Checklist

  • I have read and agree to Contributor Guide and the Code of Conduct
  • I've included a screenshot or gif (if applicable)
  • I have tested demo.rerun.io (if applicable)
  • The PR title and labels are set such as to maximize their usefulness for the next release's CHANGELOG

@teh-cmc teh-cmc added 🧑‍💻 dev experience developer experience (excluding CI) 🦟 regression A thing that used to work in an earlier release include in changelog labels Oct 10, 2023
@teh-cmc teh-cmc merged commit 3b5a7b7 into main Oct 10, 2023
@teh-cmc teh-cmc deleted the cmc/tensor1d_barchart branch October 10, 2023 09:52
@nikolausWest
Copy link
Copy Markdown
Member

I wonder if it would have made more sense to add an extra dimension instead and treat it like a 1 x N tensor? That way we make it possible for the user to choose what way they'd like to see their data. Like a tensor row or a bar chart depending on the indicator

@emilk emilk changed the title 1D tensors as bar charts Show 1D-tensors as bar charts Oct 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🧑‍💻 dev experience developer experience (excluding CI) include in changelog 🦟 regression A thing that used to work in an earlier release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

rr.Tensor not working for 1D tensors

3 participants