code: def save_GLRM_mojo(model):
      # save model
      regex = re.compile("[+\\-* !@#$%^&()={}\\[\\]|;:'\"<>,.?/]")
      MOJONAME = regex.sub("_", model._id)
  
      print("Downloading Java prediction model code from H2O")
      TMPDIR = os.path.normpath(
          os.path.join(
              os.path.dirname(os.path.realpath("__file__")),
              "..",
              "results",
              MOJONAME,
          )
      )
      os.makedirs(TMPDIR)
      model.download_mojo(path=TMPDIR)  # save mojo
      return TMPDIR
  
file_path: h2o-3/h2o-py/tests/testdir_javapredict/pyunit_pubdev_5858_GLRMIterNumber.py
imports: import sys, os
  import h2o
  from tests import pyunit_utils
  from h2o.estimators.glrm import H2OGeneralizedLowRankEstimator
  from random import randint
  import re
  import time
  import subprocess
  from subprocess import STDOUT, PIPE
label_desc: Use image node_id 2 for calling a global function with example usage: save_GLRM_mojo(model) and returns: TMPDIR