comparison nn_classifier.xml @ 17:699024d5c451 draft

"planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit 5b2ac730ec6d3b762faa9034eddd19ad1b347476"
author bgruening
date Mon, 16 Dec 2019 05:31:46 -0500
parents d0efc68a3ddb
children 1d3447c2203c
comparison
equal deleted inserted replaced
16:55c7d3e58eae 17:699024d5c451
32 32
33 with open("$infile_model", 'rb') as model_handler: 33 with open("$infile_model", 'rb') as model_handler:
34 classifier_object = load_model(model_handler) 34 classifier_object = load_model(model_handler)
35 35
36 header = 'infer' if params["selected_tasks"]["header"] else None 36 header = 'infer' if params["selected_tasks"]["header"] else None
37 data = pandas.read_csv("$selected_tasks.infile_data", sep='\t', header=header, index_col=None, parse_dates=True, encoding=None, tupleize_cols=False) 37 data = pandas.read_csv("$selected_tasks.infile_data", sep='\t', header=header, index_col=None, parse_dates=True, encoding=None)
38 prediction = classifier_object.predict(data) 38 prediction = classifier_object.predict(data)
39 prediction_df = pandas.DataFrame(prediction) 39 prediction_df = pandas.DataFrame(prediction)
40 res = pandas.concat([data, prediction_df], axis=1) 40 res = pandas.concat([data, prediction_df], axis=1)
41 res.to_csv(path_or_buf = "$outfile_predict", sep="\t", index=False) 41 res.to_csv(path_or_buf = "$outfile_predict", sep="\t", index=False)
42 42