diff ensemble.xml @ 21:9ce3e347506c draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit 2a058459e6daf0486871f93845f00fdb4a4eaca1
author bgruening
date Sat, 29 Sep 2018 07:30:08 -0400
parents 038cecaa9e7c
children 2e69c6ca6e91
line wrap: on
line diff
--- a/ensemble.xml	Thu Aug 23 16:16:12 2018 -0400
+++ b/ensemble.xml	Sat Sep 29 07:30:08 2018 -0400
@@ -22,8 +22,9 @@
 import pandas
 from scipy.io import mmread
 
-execfile("$__tool_directory__/sk_whitelist.py")
-execfile("$__tool_directory__/utils.py", globals())
+with open("$__tool_directory__/sk_whitelist.json", "r") as f:
+    sk_whitelist = json.load(f)
+exec(open("$__tool_directory__/utils.py").read(), globals())
 
 # Get inputs, outputs.
 input_json_path = sys.argv[1]
@@ -75,7 +76,7 @@
 
 else:
     with open(infile_model, 'rb') as model_handler:
-        classifier_object = SafePickler.load(model_handler)
+        classifier_object = load_model(model_handler)
     header = 'infer' if params["selected_tasks"]["header"] else None
     data = pandas.read_csv(infile_data, sep='\t', header=header, index_col=None, parse_dates=True, encoding=None, tupleize_cols=False)
     prediction = classifier_object.predict(data)
@@ -265,7 +266,7 @@
             <param name="selected_task" value="train"/>
             <param name="selected_algorithm" value="GradientBoostingRegressor"/>
             <param name="max_features" value="number_input"/>
-            <param name="num_max_features" value=""/>
+            <param name="num_max_features" value="0.5"/>
             <param name="random_state" value="42"/>
             <output name="outfile_fit" file="gbr_model01" compare="sim_size" delta="500"/>
         </test>