ChainConsumer icon indicating copy to clipboard operation
ChainConsumer copied to clipboard

Different renderer for summary text and axis labels

Open benjaminpope opened this issue 1 year ago • 1 comments

Hi Sam,

I notice there is a different renderer for the summary text and the axis labels.

Defining labels like this in numpyro

    dra, ddec, log_flux = [npy.sample(r"\Delta \text{RA}",    dist.Uniform(100, 200)), 
              npy.sample(r"\Delta \text{Dec}",   dist.Uniform(100, 200)),
              npy.sample(r"\log \text{Flux}",    dist.Uniform(-5,-3))
            ]

I get math mode not rendered in the axis labels

image

but if I just use unicode on the labels

    dra, ddec, log_flux = [npy.sample("Δ RA",    dist.Uniform(100, 200)), 
              npy.sample("Δ Dec",   dist.Uniform(100, 200)),
              npy.sample("log Flux",    dist.Uniform(-5,-3))
            ]

I get

image

where the summary text is now displayed in math mode, which is also not what we want.

Is it possible to make these render consistently?

Cheers,

Ben

benjaminpope avatar Apr 13 '24 11:04 benjaminpope

Hmmmm yeah that's strange, I'll look into this when I'm back from parental leave. Please ping me here if I haven't comments again in a week or two. Similarly, if you look into it yourself and figure it out, a full or partial PR will gladly be accepted:)

Samreay avatar Apr 13 '24 11:04 Samreay