from Models.GaussianNaiveBayes import GaussianNaiveBayes, Persist
from getXY import getXY
from sklearn.model_selection import train_test_split
from time import time
import sys

X, y = getXY(sys.argv[1])

X_train, X_test, y_train, y_test = train_test_split(X, y, test_size = 0.2, random_state = 0)

start_time = time()
classifier = GaussianNaiveBayes(X_train, y_train)
print("Time Taken to Train: {}".format(time() - start_time))

Persist(classifier)