code: def learning_curve(
      model,
      X,
      y,
      cv=None,
      shuffle=False,
      random_state=None,
      train_sizes=None,
      n_jobs=1,
      scoring=None,
  ):
      """Train model on datasets of varying size and generates plot of score vs size.
  
      Called by plot_learning_curve to visualize learning curve. Please use the function
      plot_learning_curve() if you wish to visualize your learning curves.
      """
      (
          train_sizes,
          train_scores,
          test_scores,
      ) = model_selection.learning_curve(
          model,
          X,
          y,
          cv=cv,
          n_jobs=n_jobs,
          train_sizes=train_sizes,
          scoring=scoring,
          shuffle=shuffle,
          random_state=random_state,
      )
      train_scores_mean = np.mean(train_scores, axis=1)
      test_scores_mean = np.mean(test_scores, axis=1)
  
      table = make_table(
          train_scores_mean, test_scores_mean, train_sizes
      )
      chart = wandb.visualize("wandb/learning_curve/v1", table)
  
      return chart
  
imports: from warnings import simplefilter
  import numpy
  from sklearn import model_selection
  import wandb
  from wandb.sklearn import utils
label_desc: Use image node_id 1 for calling a global function with example usage: learning_curve(model, X, y, cv, shuffle, random_state, train_sizes, n_jobs, scoring) and returns: chart