Hi WittyOwl57
I'm guessing clearml is trying to unify the histograms for each iteration, but the result is in this case not useful.
I think you are correct, the TB histograms are actually a 3d histograms (i.e. 2d histograms over time, which would be the default for kernel;/bias etc.)
is there a way to ungroup the result by iteration, and, is it possible to group it by something else (e.g. the tags of the two plots displayed below side by side).
Can you provide a toy example, to play with? (somehow we need to separate the two use cases...)
WittyOwl57 are you aware of any equivalent to the joypy
plot in plotly?
Hi AgitatedDove14
this is how our calls look like:
` from pytorch_lightning.loggers import TensorBoardLogger
logger = TensorBoardLogger(save_dir=".", name="debug plotting", 1)
logger.experiment.add_histogram(f"A", data[data.by == 0])
logger.experiment.add_histogram(f"B", data[data.by == 1]) `the result of which is shown in my post above.
This is some test data, and how we'd like things to look:
` def make_data(size: int=10000, n: int=5) -> pd.DataFrame:
x = np.abs(np.random.normal(size=size))
y = (3 + 0.5*np.random.normal(size=size))
data = pd.DataFrame(dict(x=x, y=y))
chunk_size = size // n
for i in range(n):
data["x"][i * chunk_size: (i + 1) * chunk_size] += 0.1 * np.random.random() * np.sqrt(i)
data["y"][i * chunk_size: (i + 1) * chunk_size] += 0.5 * np.random.random() * np.sqrt(i)
data["by"] = np.concatenate([np.full(chunk_size, i) for i in range(1, n + 1)])
return data
import joypy
n = 20
data = make_data(n=n)
labels = [i if i % 2 == 0 else None for i in range(n)]
fig, axes = joypy.joyplot(data, by="by", column=["x", "y"], fade=True, labels=labels, grid="y",
linewidth=0.5, legend=False, figsize=(6,5), title="histogram test",
colormap=plt.cm.autumn_r, alpha=0.1) `
Hmm, I really like this one:
https://chart-studio.plotly.com/~empet/14632/plotly-joyplotridgelines/#plot
What I'm thinking is a global setting basically telling the TB binding layer to always do ridgeline instead of 3d surface.
wdyt?
Unfortunately there doesn't seem to be any out-of-the-box functionality for ridgeline plots (joyplots) in plotly. They are certainly doable ( https://www.python-graph-gallery.com/ridgeline-graph-plotly , or https://chart-studio.plotly.com/~empet/14632/plotly-joyplotridgelines/#/ ) but I'd guess this won't happen any time soon 🤠. We'd be happy with also having functionality similar to the one from the Scalars tab: first isolating one iteration (the latest by default) and grouping together by the prefix.
Well, of course, that would be ideal, provided someone implements the ridgeline 😊