code: def test_learning_curve_for_algos_not_present_in_automl():
      # GLM without lambda search
      prostate = h2o.import_file(
          pyunit_utils.locate("smalldata/prostate/prostate.csv")
      )
      prostate["CAPSULE"] = prostate["CAPSULE"].asfactor()
      prostate["RACE"] = prostate["RACE"].asfactor()
      prostate["DCAPS"] = prostate["DCAPS"].asfactor()
      prostate["DPROS"] = prostate["DPROS"].asfactor()
  
      predictors = ["AGE", "RACE", "VOL", "GLEASON"]
      response_col = "CAPSULE"
  
      glm_model = H2OGeneralizedLinearEstimator(
          family="binomial", lambda_=0, compute_p_values=True
      )
      glm_model.train(predictors, response_col, training_frame=prostate)
      assert isinstance(
          glm_model.learning_curve_plot().figure(),
          matplotlib.pyplot.Figure,
      )
      matplotlib.pyplot.close()
  
      # HGLM
      h2o_data = h2o.import_file(
          pyunit_utils.locate("smalldata/glm_test/semiconductor.csv")
      )
      y = "y"
      x = ["x1", "x3", "x5", "x6"]
      z = 0
      h2o_data["Device"] = h2o_data["Device"].asfactor()
      hglm_model = H2OGeneralizedLinearEstimator(
          HGLM=True,
          family="gaussian",
          rand_family=["gaussian"],
          random_columns=[z],
          rand_link=["identity"],
          calc_like=True,
      )
      hglm_model.train(x=x, y=y, training_frame=h2o_data)
      assert isinstance(
          hglm_model.learning_curve_plot().figure(),
          matplotlib.pyplot.Figure,
      )
      matplotlib.pyplot.close()
  
      # GAM
      knots1 = [
          -1.99905699,
          -0.98143075,
          0.02599159,
          1.00770987,
          1.99942290,
      ]
      frameKnots1 = h2o.H2OFrame(python_obj=knots1)
      knots2 = [
          -1.999821861,
          -1.005257990,
          -0.006716042,
          1.002197392,
          1.999073589,
      ]
      frameKnots2 = h2o.H2OFrame(python_obj=knots2)
      knots3 = [
          -1.999675688,
          -0.979893796,
          0.007573327,
          1.011437347,
          1.999611676,
      ]
      frameKnots3 = h2o.H2OFrame(python_obj=knots3)
      h2o_data = h2o.import_file(
          pyunit_utils.locate(
              "smalldata/glm_test/multinomial_10_classes_10_cols_10000_Rows_train.csv"
          )
      )
      h2o_data["C1"] = h2o_data["C1"].asfactor()
      h2o_data["C2"] = h2o_data["C2"].asfactor()
      h2o_data["C11"] = h2o_data["C11"].asfactor()
      train, test = h2o_data.split_frame(ratios=[0.8])
      y = "C11"
      x = ["C1", "C2"]
      numKnots = [5, 5, 5]
      gam_model = H2OGeneralizedAdditiveEstimator(
          family="multinomial",
          gam_columns=["C6", "C7", "C8"],
          scale=[1, 1, 1],
          num_knots=numKnots,
          knot_ids=[frameKnots1.key, frameKnots2.key, frameKnots3.key],
      )
      gam_model.train(
          x=x, y=y, training_frame=train, validation_frame=test
      )
      assert isinstance(
          gam_model.learning_curve_plot().figure(),
          matplotlib.pyplot.Figure,
      )
      matplotlib.pyplot.close()
  
      # GLRM
      arrestsH2O = h2o.import_file(
          pyunit_utils.locate("smalldata/pca_test/USArrests.csv")
      )
      glrm_model = H2OGeneralizedLowRankEstimator(
          k=4,
          loss="quadratic",
          gamma_x=0.5,
          gamma_y=0.5,
          max_iterations=700,
          recover_svd=True,
          init="SVD",
          transform="standardize",
      )
      glrm_model.train(training_frame=arrestsH2O)
      assert isinstance(
          glrm_model.learning_curve_plot().figure(),
          matplotlib.pyplot.Figure,
      )
      matplotlib.pyplot.close()
  
      # CoxPH
      heart = h2o.import_file(
          pyunit_utils.locate("smalldata/coxph_test/heart.csv")
      )
      coxph_model = H2OCoxProportionalHazardsEstimator(
          start_column="start", stop_column="stop", ties="breslow"
      )
      coxph_model.train(x="age", y="event", training_frame=heart)
      assert isinstance(
          coxph_model.learning_curve_plot().figure(),
          matplotlib.pyplot.Figure,
      )
      matplotlib.pyplot.close()
  
      assert isinstance(
          coxph_model.learning_curve_plot(metric="loglik").figure(),
          matplotlib.pyplot.Figure,
      )
      matplotlib.pyplot.close()
  
      # IsolationForest
      if_model = H2OIsolationForestEstimator(
          sample_rate=0.1, max_depth=20, ntrees=50
      )
      if_model.train(training_frame=prostate)
      assert isinstance(
          if_model.learning_curve_plot().figure(),
          matplotlib.pyplot.Figure,
      )
      matplotlib.pyplot.close()
  
imports: import os
  import sys
  import pandas
  from h2o.grid import H2OGridSearch
  import matplotlib
  import h2o
  import pandas
  import matplotlib.pyplot
  from tests import pyunit_utils, test_plot_result_saving
  from h2o.automl import H2OAutoML
  from h2o.estimators import *
  from h2o.explanation._explain import H2OExplanation
label_desc: Use image node_id 12 for calling a global function with example usage: test_learning_curve_for_algos_not_present_in_automl() without return types