# for local run, before pygraphc packaging
import sys
sys.path.insert(0, '../pygraphc/misc')
from IPLoM import *
sys.path.insert(0, '../pygraphc/evaluation')
from ExternalEvaluation import *

# set path
ip_address = '161.166.232.17'
standard_path = '/home/hudan/Git/labeled-authlog/dataset/' + ip_address
standard_file = standard_path + 'auth.log.anon.labeled'
analyzed_file = 'auth.log.anon'
prediction_file = 'iplom-result-' + ip_address + '.txt'
OutputPath = './results'
para = Para(path=standard_path, logname=analyzed_file, save_path=OutputPath)

# call IPLoM and get clusters
myparser = IPLoM(para)
time = myparser.main_process()
clusters = myparser.get_clusters()
original_logs = myparser.logs

# set cluster label to get evaluation metrics
ExternalEvaluation.set_cluster_label_id(None, clusters, original_logs, prediction_file)
homogeneity_completeness_vmeasure = ExternalEvaluation.get_homogeneity_completeness_vmeasure(standard_file,
                                                                                            prediction_file)

print homogeneity_completeness_vmeasure
print ('The running time of IPLoM is', time)

@@ -1,89 +1,17 @@
-# for local run, before pygraphc packaging%0Aimport sys%0Asys.path.insert(0, '../
+from 
 pygraphc
 /mis
@@ -10,21 +10,14 @@
 aphc
-/
+.
 misc
-')%0Afrom 
+.
 IPLo
@@ -31,39 +31,21 @@
 t *%0A
-sys.path.insert(0, '../
+from 
 pygraphc
 /eva
@@ -40,17 +40,17 @@
 pygraphc
-/
+.
 evaluati
@@ -55,16 +55,9 @@
 tion
-')%0Afrom 
+.
 Exte
@@ -87,16 +87,22 @@
 %0A%0A# set 
+input 
 path%0Aip_
@@ -185,16 +185,38 @@
 dataset/
+Hofstede2014/dataset1/
 ' + ip_a
@@ -388,17 +388,16 @@
 ./result
-s
 '%0Apara =
@@ -952,16 +952,17 @@
         
+ 
 predicti
@@ -970,16 +970,41 @@
 n_file)%0A
+# print evaluation result
 %0Aprint h

Edit import module. pygraphc is now ready to be packaged