File tree Expand file tree Collapse file tree 2 files changed +4
-6
lines changed
examples/data/hmeqModels/H2OBinaryGLM Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -400,9 +400,7 @@ def _write_imports(
400400 )
401401
402402 if mojo_model or binary_h2o_model :
403- cls .score_code += (
404- "import h2o\n \n h2o.init()\n \n "
405- )
403+ cls .score_code += "import h2o\n \n h2o.init()\n \n "
406404 elif binary_string :
407405 cls .score_code += (
408406 f'import codecs\n \n binary_string = "{ binary_string } "'
@@ -509,11 +507,11 @@ def _viya4_model_load(
509507 if mojo_model :
510508 cls .score_code += (
511509 f"model = h2o.import_mojo(str(Path(settings.pickle_path"
512- f" ) / \ "{ model_file_name } \ " ))\n \n "
510+ f' ) / "{ model_file_name } "))\n \n '
513511 )
514512 return (
515513 f"{ '' :8} model = h2o.import_mojo(str(Path(settings.pickle_path) / "
516- f" \" { model_file_name } \ " ))\n \n "
514+ f'" { model_file_name } "))\n \n '
517515 )
518516 elif binary_h2o_model :
519517 cls .score_code += (
@@ -527,7 +525,7 @@ def _viya4_model_load(
527525 else :
528526 cls .score_code += (
529527 f"with open(Path(settings.pickle_path) / "
530- f'\ "{ model_file_name } \ " , "rb") as pickle_model:\n '
528+ f'"{ model_file_name } ", "rb") as pickle_model:\n '
531529 f"{ '' :4} model = { pickle_type } .load(pickle_model)\n \n "
532530 )
533531 return (
You can’t perform that action at this time.
0 commit comments