Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: oeyetgin/SOFTX-DCT-FEATURE
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: osmatrix/SOFTX-DCT-FEATURE
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Able to merge. These branches can be automatically merged.
  • 4 commits
  • 6 files changed
  • 2 contributors

Commits on Apr 15, 2019

  1. ignore .arff and .mat temp file

    huhongjun committed Apr 15, 2019
    Copy the full SHA
    547561c View commit details
  2. chinese readme

    huhongjun committed Apr 15, 2019
    Copy the full SHA
    f751429 View commit details
  3. format

    huhongjun committed Apr 15, 2019
    Copy the full SHA
    602e477 View commit details

Commits on Jan 1, 2020

  1. 本地目录

    huhj2020 committed Jan 1, 2020
    Copy the full SHA
    5d82e66 View commit details
Showing with 136 additions and 4 deletions.
  1. +2 −0 .gitignore
  2. +10 −4 CLASSIFICATION_MODEL.kf
  3. +31 −0 README-zh_CN.md
  4. +31 −0 Weka/CS/Seed1_NB_Birlesik_IR_CSC2x2.txt
  5. +32 −0 Weka/CS/Seed1_RF_Birlesik_IR_CSC2x2.txt
  6. +30 −0 Weka/CS/Seed1_SVM_Birlesik_IR_CSC2x2.txt
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
*.arff
*.mat
14 changes: 10 additions & 4 deletions CLASSIFICATION_MODEL.kf
Original file line number Diff line number Diff line change
@@ -47,7 +47,7 @@
"loader" : {
"type" : "loader",
"class" : "weka.core.converters.ArffLoader",
"filePath" : "Desktop/BMP_Database_Duzenli/IR_128x128_Yeni/Validation_4000_10Fold/Test_and_Train_10Fold/Birlesik_IR_PB64x64.arff",
"filePath" : "../../00-work/ws_mylabs/SOFTX-DCT-FEATURE/1_CLASSICAL_SELECTION (CS)/Birlesik_IR_CSC2x2.arff",
"useRelativePath" : true
},
"name" : "ArffLoader"
@@ -108,7 +108,9 @@
{
"class" : "weka.knowledgeflow.steps.ClassifierPerformanceEvaluator",
"properties" : {
"costMatrixString" : "",
"errorPlotPointSizeProportionalToMargin" : false,
"evaluateWithRespectToCosts" : false,
"evaluationMetricsToOutput" : "Correct,Incorrect,Kappa,Total cost,Average cost,KB relative,KB information,Correlation,Complexity 0,Complexity scheme,Complexity improvement,MAE,RMSE,RAE,RRSE,Coverage,Region size,TP rate,FP rate,Precision,Recall,F-measure,MCC,ROC area,PRC area",
"name" : "ClassifierPerformanceEvaluator_1"
},
@@ -122,7 +124,9 @@
{
"class" : "weka.knowledgeflow.steps.ClassifierPerformanceEvaluator",
"properties" : {
"costMatrixString" : "",
"errorPlotPointSizeProportionalToMargin" : false,
"evaluateWithRespectToCosts" : false,
"evaluationMetricsToOutput" : "Correct,Incorrect,Kappa,Total cost,Average cost,KB relative,KB information,Correlation,Complexity 0,Complexity scheme,Complexity improvement,MAE,RMSE,RAE,RRSE,Coverage,Region size,TP rate,FP rate,Precision,Recall,F-measure,MCC,ROC area,PRC area",
"name" : "ClassifierPerformanceEvaluator_2"
},
@@ -136,7 +140,9 @@
{
"class" : "weka.knowledgeflow.steps.ClassifierPerformanceEvaluator",
"properties" : {
"costMatrixString" : "",
"errorPlotPointSizeProportionalToMargin" : false,
"evaluateWithRespectToCosts" : false,
"evaluationMetricsToOutput" : "Correct,Incorrect,Kappa,Total cost,Average cost,KB relative,KB information,Correlation,Complexity 0,Complexity scheme,Complexity improvement,MAE,RMSE,RAE,RRSE,Coverage,Region size,TP rate,FP rate,Precision,Recall,F-measure,MCC,ROC area,PRC area",
"name" : "ClassifierPerformanceEvaluator_3"
},
@@ -151,7 +157,7 @@
"class" : "weka.knowledgeflow.steps.TextSaver",
"properties" : {
"append" : true,
"file" : "/Users/omeremreyetgin/Desktop/BMP_Database_Duzenli/IR_128x128_Yeni/Validation_4000_10Fold/Test_and_Train_10Fold/Seed1_NB_Birlesik_IR_PB64x64.txt",
"file" : "D:/00-work/ws_mylabs/SOFTX-DCT-FEATURE/Weka/CS/Seed1_NB_Birlesik_IR_CSC2x2.txt",
"name" : "Result_NaiveBayes",
"writeTitleString" : true
},
@@ -163,7 +169,7 @@
"class" : "weka.knowledgeflow.steps.TextSaver",
"properties" : {
"append" : true,
"file" : "/Users/omeremreyetgin/Desktop/BMP_Database_Duzenli/IR_128x128_Yeni/Validation_4000_10Fold/Test_and_Train_10Fold/Seed1_RF_Birlesik_IR_PB64x64.txt",
"file" : "D:/00-work/ws_mylabs/SOFTX-DCT-FEATURE/Weka/CS/Seed1_RF_Birlesik_IR_CSC2x2.txt",
"name" : "Result_RandomForest",
"writeTitleString" : true
},
@@ -175,7 +181,7 @@
"class" : "weka.knowledgeflow.steps.TextSaver",
"properties" : {
"append" : true,
"file" : "/Users/omeremreyetgin/Desktop/BMP_Database_Duzenli/IR_128x128_Yeni/Validation_4000_10Fold/Test_and_Train_10Fold/Seed1_SVM_Birlesik_IR_PB64x64.txt",
"file" : "D:/00-work/ws_mylabs/SOFTX-DCT-FEATURE/Weka/CS/Seed1_SVM_Birlesik_IR_CSC2x2.txt",
"name" : "Result_LibLINEAR (SVM)",
"writeTitleString" : false
},
31 changes: 31 additions & 0 deletions README-zh_CN.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# README

红外图片和可见光图片检测电力线问题。
matlab用于提取特征,提供五种算法;
weka执行分类,采用NaiveBayes、RAndomForest、SVM三种。

## 安装

1. 安装weka 3.8
package manager中安装liblinear,normalize
2. 安装matlab 2013b

## 运行

打开matlab,打开5个目录,执行目录下的main*.m即可;

打开weka=》knowledge flow打开CLASSIFICATION_MODEL文件
双击arff loader选择文件,然后点击text saver设置输出

点击左上角run即可。

## FAQ

### Weka package manager 无法打开的问题

1.打开日志窗口,可以看到服务器连接不上,一是官方的props文件,另外也需要连接sf.net

2.runweka.bat增加如下一行
set _JAVA_OPTIONS=-Dhttp.proxyHost=127.0.0.1 -Dhttp.proxyPort=8580
使用代理连接服务器,http代理成功,socks5代理提示ziplib出错,repo缓存下载大小约2M。

31 changes: 31 additions & 0 deletions Weka/CS/Seed1_NB_Birlesik_IR_CSC2x2.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
NaiveBayes

=== Evaluation result ===

Scheme: NaiveBayes
Relation: Birlesik_IR_CSC2x2.arff-weka.filters.unsupervised.instance.Normalize-N1.0-L2.0


Correctly Classified Instances 17 85 %
Incorrectly Classified Instances 3 15 %
Kappa statistic 0.7
Mean absolute error 0.2681
Root mean squared error 0.4053
Relative absolute error 53.6275 %
Root relative squared error 81.0505 %
Coverage of cases (0.95 level) 90 %
Mean rel. region size (0.95 level) 77.5 %
Total Number of Instances 20

=== Detailed Accuracy By Class ===

TP Rate FP Rate Precision Recall F-Measure MCC ROC Area PRC Area Class
0.900 0.200 0.818 0.900 0.857 0.704 0.820 0.848 1
0.800 0.100 0.889 0.800 0.842 0.704 0.820 0.751 0
Weighted Avg. 0.850 0.150 0.854 0.850 0.850 0.704 0.820 0.800

=== Confusion Matrix ===

a b <-- classified as
9 1 | a = 1
2 8 | b = 0
32 changes: 32 additions & 0 deletions Weka/CS/Seed1_RF_Birlesik_IR_CSC2x2.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
RandomForest

=== Evaluation result ===

Scheme: RandomForest
Options: -P 100 -I 100 -num-slots 1 -K 0 -M 1.0 -V 0.001 -S 1
Relation: Birlesik_IR_CSC2x2.arff-weka.filters.unsupervised.instance.Normalize-N1.0-L2.0


Correctly Classified Instances 15 75 %
Incorrectly Classified Instances 5 25 %
Kappa statistic 0.5
Mean absolute error 0.3135
Root mean squared error 0.4047
Relative absolute error 62.7 %
Root relative squared error 80.9457 %
Coverage of cases (0.95 level) 95 %
Mean rel. region size (0.95 level) 87.5 %
Total Number of Instances 20

=== Detailed Accuracy By Class ===

TP Rate FP Rate Precision Recall F-Measure MCC ROC Area PRC Area Class
0.800 0.300 0.727 0.800 0.762 0.503 0.830 0.858 1
0.700 0.200 0.778 0.700 0.737 0.503 0.830 0.789 0
Weighted Avg. 0.750 0.250 0.753 0.750 0.749 0.503 0.830 0.824

=== Confusion Matrix ===

a b <-- classified as
8 2 | a = 1
3 7 | b = 0
30 changes: 30 additions & 0 deletions Weka/CS/Seed1_SVM_Birlesik_IR_CSC2x2.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
=== Evaluation result ===

Scheme: LibLINEAR
Options: -S 1 -C 1.0 -E 0.001 -B 1.0 -L 0.1 -I 1000
Relation: Birlesik_IR_CSC2x2.arff-weka.filters.unsupervised.instance.Normalize-N1.0-L2.0


Correctly Classified Instances 16 80 %
Incorrectly Classified Instances 4 20 %
Kappa statistic 0.6
Mean absolute error 0.2
Root mean squared error 0.4472
Relative absolute error 40 %
Root relative squared error 89.4427 %
Coverage of cases (0.95 level) 80 %
Mean rel. region size (0.95 level) 50 %
Total Number of Instances 20

=== Detailed Accuracy By Class ===

TP Rate FP Rate Precision Recall F-Measure MCC ROC Area PRC Area Class
0.900 0.300 0.750 0.900 0.818 0.612 0.800 0.725 1
0.700 0.100 0.875 0.700 0.778 0.612 0.800 0.763 0
Weighted Avg. 0.800 0.200 0.813 0.800 0.798 0.612 0.800 0.744

=== Confusion Matrix ===

a b <-- classified as
9 1 | a = 1
3 7 | b = 0