[Ludwig-ai issue] Unlike in Colab, Matplotlib/Pyplot cannot display all the needed charts in Streamlit

Hi folks and happy new year! :raised_hands:

I’m building a Streamlit app for the (awesome!) Ludwig and I cannot seem to display the vizzes I need.

After training a model, the following code in Colab:

from ludwig import visualize
visualize.learning_curves([data])

… diplays all the needed charts:

image
image
image
image

More info about visualisaton methods here

In streamlit, I’ve converted the code as:

st.pyplot(visualize.learning_curves([data]))

… yet this code only gives me the ‘loss’ chart, see screenshot below:

I’ve tried to tweak the code in several ways but no luck so far. Any ideas anyone?

Thanks in advance! :pray:
Charly

I’ve never used Ludwig before, do they have a simple code example I can run to build a model?

1 Like

Thanks Randy!

I’ve actually found a hack on this! :wink:

  • Save all training files
  • Spot latest JSON in Ludwig folder
  • Reload that latest JSON via Ludwig’s Visualize module

Voila! :slight_smile:

2 Likes