Classification transcription factor structural domain sentences
Showing
1 changed file
with
3 additions
and
2 deletions
... | @@ -309,8 +309,9 @@ if __name__ == "__main__": | ... | @@ -309,8 +309,9 @@ if __name__ == "__main__": |
309 | for param in sorted(best_parameters.keys()): | 309 | for param in sorted(best_parameters.keys()): |
310 | oFile.write("\t%s: %r\n" % (param, best_parameters[param])) | 310 | oFile.write("\t%s: %r\n" % (param, best_parameters[param])) |
311 | if args.classifier == "SVM": | 311 | if args.classifier == "SVM": |
312 | - oFile.write('\nWeights assigned to the features: \n') | 312 | + if args.kernel == "linear": |
313 | - oFile.write("{}\n".format(classifier.coef_)) | 313 | + oFile.write('\nWeights assigned to the features: \n') |
314 | + oFile.write("{}\n".format(classifier.coef_)) | ||
314 | oFile.write('Confidence scores: \n') | 315 | oFile.write('Confidence scores: \n') |
315 | oFile.write("{}\n".format(confidence_scores)) | 316 | oFile.write("{}\n".format(confidence_scores)) |
316 | oFile.write('Number of support vectors per class: \n{}\n'.format(classifier.n_support_)) | 317 | oFile.write('Number of support vectors per class: \n{}\n'.format(classifier.n_support_)) | ... | ... |
-
Please register or login to post a comment