diff options
author | Andreas Maunz <andreas@maunz.de> | 2012-01-31 10:25:05 +0100 |
---|---|---|
committer | Andreas Maunz <andreas@maunz.de> | 2012-01-31 10:25:05 +0100 |
commit | a3e3c4a18df7196ac2a22a19285e998ab87d2a3f (patch) | |
tree | 1db1a375a963ad971b95e5fa55751a9c04b70f8f | |
parent | 6b9482101ff26b3e31cf145c4786ada56923d5f7 (diff) | |
parent | 985a7a0a18f763ceae020cef2fbf0db3da17776d (diff) |
Merge branch 'caret' into pc_new_1
-rw-r--r-- | README.md | 14 | ||||
m--------- | last-utils | 0 | ||||
-rw-r--r-- | lazar.rb | 15 | ||||
m--------- | libfminer | 0 |
4 files changed, 12 insertions, 17 deletions
@@ -35,19 +35,19 @@ REST operations [feature_generation_uri], [prediction_algorithm], [feature_dataset_uri], - [propositionalized=false], [pc_type=null], - [nr_hits=false (class.), true (regr.)], - [min_sim=0.3 (nominal), 0.6 (numeric features)] + [nr_hits=false (class. using wt. maj. vote), true (else)], + [min_sim=0.3 (nominal), 0.4 (numeric features)] + [min_train_performance=0.1] Synopsis -------- -- prediction\_algorithm: One of "weighted\_majority\_vote" (default for classification), "local\_svm\_classification", "local\_svm\_regression (default for regression)", "local\_mlr\_prop". "weighted\_majority\_vote" is not applicable for regression. "local\_mlr\_prop" is not applicable for classification. -- propositionalized: One of "true", "false". Not appplicable when prediction\_algorithm="weighted\_majority\_vote". +- prediction\_algorithm: One of "weighted\_majority\_vote" (default for classification), "local\_svm\_classification", "local\_svm\_regression" (default for regression). "weighted\_majority\_vote" is not applicable for regression. - pc_type: Mandatory for feature dataset, one of [geometrical, topological, electronic, constitutional, hybrid, cpsa]. -- nr_hits: Whether for instantiated models (local\_svm\_kernel = "propositionalized" for prediction_algorithm="local\_svm\_classification" or "local\_svm\_regression", or for prediction_algorithm="local\_mlr\_prop") nominal features should be instantiated with their occurrence counts in the instances. For non-instantiated models (local\_svm\_kernel = "weighted\_tanimoto" for prediction_algorithm="local\_svm\_classification" or "local\_svm\_regression", or for prediction_algorithm="weighted\_majority\_vote") the neighbor-to-neighbor and neighbor-to-query similarity also integrates these counts, when the parameter is set. One of "true", "false". -- min_sim: The minimum similarity threshold for neighbors. Numeric value in [0,1]. +- nr_hits: Whether nominal features should be instantiated with their occurrence counts in the instances. One of "true", "false". +- min_sim: The minimum similarity threshold for neighbors. Numeric value in [0,1]. +- min_train_performance. The minimum training performance for "local\_svm\_classification" (Accuracy) and "local\_svm\_regression" (R-squared). Numeric value in [0,1]. See http://www.maunz.de/wordpress/opentox/2011/lazar-models-and-how-to-trigger-them for a graphical overview. diff --git a/last-utils b/last-utils -Subproject 8c02f7e71450cac6d8c5d7d34ecb620046b4ea4 +Subproject cf0238477127e54509b6ab8b5c38f50dd6ffce0 @@ -93,20 +93,19 @@ post '/lazar/?' do min_sim = params[:min_sim].to_f if params[:min_sim] min_sim = 0.3 unless params[:min_sim] + # Algorithm + lazar.prediction_algorithm = "Neighbors.#{params[:prediction_algorithm]}" if params[:prediction_algorithm] + # Nr Hits nr_hits = false - if params[:nr_hits] == "true" + if params[:nr_hits] == "true" || lazar.prediction_algorithm.include?("local_svm") lazar.feature_calculation_algorithm = "Substructure.match_hits" nr_hits = true end params[:nr_hits] = "true" if lazar.feature_calculation_algorithm == "Substructure.match_hits" #not sure if this line in needed - # Algorithm - lazar.prediction_algorithm = "Neighbors.#{params[:prediction_algorithm]}" if params[:prediction_algorithm] - # Propositionalization - propositionalized = false - propositionalized = true if ( params[:propositionalized] != "false" && ( lazar.prediction_algorithm == "local_mlr_prop" || lazar.prediction_algorithm.include?("local_svm") ) ) + propositionalized = (lazar.prediction_algorithm=="Neighbors.weighted_majority_vote" ? false : true) # PC type pc_type = params[:pc_type] unless params[:pc_type].nil? @@ -115,10 +114,6 @@ post '/lazar/?' do min_train_performance = params[:min_train_performance].to_f if params[:min_train_performance] min_train_performance = 0.1 unless params[:min_train_performance] - # Conf_stdev --- To be removed?? - lazar.conf_stdev = ( (params[:conf_stdev] == "true") ? true : false ) - - diff --git a/libfminer b/libfminer -Subproject 17932e809c35c93374ed3d5fd19a313325c35b4 +Subproject f9e560dc0a7a5d5af439814ab5fa9ce027a025b |