def __init__(self,pinakasA,mywidth,classifier_code):
		self.code=classifier_code
		if self.code=="svm":
			classifier=SVMAnomalyClassifier(pinakasA,mywidth)
		elif self.code=="gmm":
			classifier=GMMAnomalyClassifier(pinakasA,mywidth)
		else:
			raiseException("Unrecognized Name")
		#if isinstance(classifier,SVMAnomalyClassifier):
			#print "einai SVMAnomalyClassifier"
		#if isinstance(classifier,AnomalyClassifier):
			#print "einai AnomalyClassifier"
		self.width=mywidth
		classifier.trainWithDataset(pinakasA,self.width)
		trained_pickled = open('/home/mike/svn/nasia/trunk/philosophers/src/anomaly_detection/scripts/results/trained.pkl', 'wb') #apo8ikevei to trained montelo sto data.pkl
		pickle.dump(classifier, trained_pickled, -1)
		sys.exit()
	def __init__(self,pinakasA,mywidth,classifier_code):
		self.code=classifier_code
		if self.code=="svm":
			classifier=SVMAnomalyClassifier(pinakasA,mywidth)
		elif self.code=="gmm":
			classifier=GMMAnomalyClassifier(pinakasA,mywidth)
		else:
			raiseException("Unrecognized Name")
		if isinstance(classifier,SVMAnomalyClassifier):
			print "einai SVMAnomalyClassifier"
		if isinstance(classifier,AnomalyClassifier):
			print "einai AnomalyClassifier"
		self.width=mywidth
		classifier.trainWithDataset(pinakasA,self.width)
		trained_pickled = open('trained.pkl', 'wb') #apo8ikevei to trained montelo sto data.pkl
		pickle.dump(classifier, trained_pickled, -1)
		sys.exit()