Example #1
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)

                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/gNaiveBayes.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)


                labelSum = tk.Label(self, text = "Naive Bayes is a collection of algorithms that are based on the Bayes Theorem. \nIt works by classifying features of input data. It can then predict \nthe class of input by seeing which features match between \nclasses. Some advantages are that it is fast and easy to train. A disadvantage is that it assumes every\n feature is independent of the other which is not always true for every class.")
                labelSum.place(x =80, y= 200)

                label = tk.Label(self, text= machineLearningModels.gNaiveBayes(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predBayes))
                buttonZ.place(x = 275, y = 400)
Example #2
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)

                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)


                load2 = Image.open('MLModelPics/percepetron(neuron).jpg')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)


                labelSum = tk.Label(self, text = "A perceptron is used for classifying data. It is a linear classifier so it classifies \ndata into two categories. It works by calculating a weighted sum of input values and returning 1 \nif the sum is greater than a certain value or it returns 0 otherwise.")
                labelSum.place(x =100, y= 200)

                label = tk.Label(self, text= machineLearningModels.precep(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predPer))
                buttonZ.place(x = 275, y = 400)
Example #3
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)

                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/LinearSUPPORTvector.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)


                labelSum = tk.Label(self, text = "Support Vector Machine is a linear model that can be used for classification\n or regression. It works by creating a line or plane that separates \ndata into classes. It finds a line between points from the two classes and then maximizes the distance \nbetween the line and the points. SVMs usually have fast performances.")
                labelSum.place(x =75, y= 200)

                label = tk.Label(self, text= machineLearningModels.lSVM(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)
                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predLSVM))
                buttonZ.place(x = 275, y = 400)
Example #4
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/DecisionTree.jpg')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "A decision tree is a structure that is used to predict the value of a target value based on certain input variables.\n Each node of the tree represents a decision that will affect the outcome of the target value. \nOne advantage of using a decision tree to predict behavior is that decision trees are easy to understand and follow.\n It is easy to follow the conditional logic that decision trees use.")
                labelSum.place(x =50, y= 200)


                label = tk.Label(self, text= machineLearningModels.dTree(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predTree))
                buttonZ.place(x = 275, y = 400)
Example #5
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)


                load2 = Image.open('MLModelPics/rForest.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "Decision trees that grow deep might lead to some incorrect results, random forests are a way to \ndeal with this. Random forests work by building a number of decision trees and merging them together\n and taking the averages of the test variables. One advantage of random forests is that it reduces\n the variance of using decision trees. A disadvantage is that making multiple decision \ntrees and merging them together might be run slow in some cases.")
                labelSum.place(x =75, y= 200)


                label = tk.Label(self, text= machineLearningModels.rForest(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predForest))
                buttonZ.place(x = 275, y = 400)
Example #6
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/kNearestNeighbor.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2

                labelSum = tk.Label(self, text = "K-Nearest Neighbors is an algorithm that can be used for both classification and regression. \nIt works by taking in training data and then seeing which data points are close to a data point\n and then classifying that data point as part of the same class as the majority of the k-nearest \ndata points. An advantage of k-nearest neighbors is that it is usually pretty accurate and \nworks well for non-linear data. A disadvantage is that it has to store all the training\n data which can lead to memory and runtime issues.")
                labelSum.place(x =100, y= 200)

                img2.place(x = 950, y = 75)

                label = tk.Label(self, text= machineLearningModels.KNN(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predK))
                buttonZ.place(x = 275, y = 400)
Example #7
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/gradient-descent.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "Gradient Descent is an algorithm that minimizes a cost function. \nGradient descent is important in machine learning because it optimizes how well a machine \nlearning algorithm is working by minimizing that algorithm’s cost function. It works by calculating gradients\n and using those gradients to change weights for predictions.")
                labelSum.place(x =65, y= 200)

                label = tk.Label(self, text= machineLearningModels.SGD(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predSGD))
                buttonZ.place(x = 275, y = 400)
Example #8
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

		
                load2 = Image.open('MLModelPics/LogRegression.jpg')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "Logistic regression is a classification algorithm.\nIt predicts the probability of an input belonging to a certain set by \nseparating data into two regions. Logistic regression is used when the response \nvariable will be binary, for example, pass/fail.")
                labelSum.place(x =100, y= 200)

                label = tk.Label(self, text= machineLearningModels.logRegression(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                label.place(x = 700,y = 100)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 400)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predLog))
                buttonZ.place(x = 275, y = 400)
Example #9
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

		
                load2 = Image.open('MLModelPics/LogRegression.jpg')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "Logistic regression is a classification algorithm.\nIt predicts the probability of an input belonging to a certain set by \nseparating data into two regions. Logistic regression is used when the response \nvariable will be binary, for example, pass/fail.")
                labelSum.place(x =100, y= 200)

             #   label = tk.Label(self, text= machineLearningModels.logRegression(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
            #label.place(x = 700,y = 100)

                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.logRegression(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predLog))
                buttonZ.place(x = 275, y = 400)
Example #10
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)

                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)


                load2 = Image.open('MLModelPics/percepetron(neuron).jpg')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)


                labelSum = tk.Label(self, text = "A perceptron is used for classifying data. It is a linear classifier so it classifies \ndata into two categories. It works by calculating a weighted sum of input values and returning 1 \nif the sum is greater than a certain value or it returns 0 otherwise.")
                labelSum.place(x =100, y= 200)

                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.precep(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predPer))
                buttonZ.place(x = 275, y = 400)
Example #11
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)


                load2 = Image.open('MLModelPics/rForest.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "Decision trees that grow deep might lead to some incorrect results, random forests are a way to \ndeal with this. Random forests work by building a number of decision trees and merging them together\n and taking the averages of the test variables. One advantage of random forests is that it reduces\n the variance of using decision trees. A disadvantage is that making multiple decision \ntrees and merging them together might be run slow in some cases.")
                labelSum.place(x =75, y= 200)


                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.rForest(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predForest))
                buttonZ.place(x = 275, y = 400)
Example #12
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)

                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/gNaiveBayes.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)


                labelSum = tk.Label(self, text = "Naive Bayes is a collection of algorithms that are based on the Bayes Theorem. \nIt works by classifying features of input data. It can then predict \nthe class of input by seeing which features match between \nclasses. Some advantages are that it is fast and easy to train. A disadvantage is that it assumes every\n feature is independent of the other which is not always true for every class.")
                labelSum.place(x =80, y= 200)

                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.gNaiveBayes(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predBayes))
                buttonZ.place(x = 275, y = 400)
Example #13
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)

                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/LinearSUPPORTvector.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)


                labelSum = tk.Label(self, text = "Support Vector Machine is a linear model that can be used for classification\n or regression. It works by creating a line or plane that separates \ndata into classes. It finds a line between points from the two classes and then maximizes the distance \nbetween the line and the points. SVMs usually have fast performances.")
                labelSum.place(x =75, y= 200)

                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.lSVM(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predLSVM))
                buttonZ.place(x = 275, y = 400)
Example #14
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/DecisionTree.jpg')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "A decision tree is a structure that is used to predict the value of a target value based on certain input variables.\n Each node of the tree represents a decision that will affect the outcome of the target value. \nOne advantage of using a decision tree to predict behavior is that decision trees are easy to understand and follow.\n It is easy to follow the conditional logic that decision trees use.")
                labelSum.place(x =50, y= 200)


                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.dTree(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predTree))
                buttonZ.place(x = 275, y = 400)
Example #15
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/kNearestNeighbor.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2

                labelSum = tk.Label(self, text = "K-Nearest Neighbors is an algorithm that can be used for both classification and regression. \nIt works by taking in training data and then seeing which data points are close to a data point\n and then classifying that data point as part of the same class as the majority of the k-nearest \ndata points. An advantage of k-nearest neighbors is that it is usually pretty accurate and \nworks well for non-linear data. A disadvantage is that it has to store all the training\n data which can lead to memory and runtime issues.")
                labelSum.place(x =100, y= 200)

                img2.place(x = 950, y = 75)

                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.KNN(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predK))
                buttonZ.place(x = 275, y = 400)
Example #16
0
        def __init__(self, parent, controller):
                tk.Frame.__init__(self, parent)
                
                load1 = Image.open('MLModelPics/bg2.png')
                render1 = ImageTk.PhotoImage(load1)
                img1 = tk.Label(self, image = render1)
                img1.image = render1
                img1.place(x = 0, y = 0)

                load2 = Image.open('MLModelPics/gradient-descent.png')
                load2 = load2.resize((450, 450))
                render2 = ImageTk.PhotoImage(load2)
                img2 = tk.Label(self, image = render2)
                img2.image = render2
                img2.place(x = 950, y = 75)

                labelSum = tk.Label(self, text = "Gradient Descent is an algorithm that minimizes a cost function. \nGradient descent is important in machine learning because it optimizes how well a machine \nlearning algorithm is working by minimizing that algorithm’s cost function. It works by calculating gradients\n and using those gradients to change weights for predictions.")
                labelSum.place(x =65, y= 200)

                textArea = tk.Text(self, height = 20, width = 15, wrap = tk.WORD)
                textArea.insert(tk.END, machineLearningModels.SGD(machineLearningModels.train1, machineLearningModels.train2, machineLearningModels.test))
                textArea.configure(font=("Arial",12))

                scroller = tk.Scrollbar(self, orient= tk.VERTICAL)
                scroller.config(command = textArea.yview)
                textArea.configure(yscrollcommand= scroller.set)
                scroller.pack(side = tk.RIGHT, fill = tk.Y)
                textArea.place(x = 700, y = 20)

                labelScroll = tk.Label(self, text = "Hover over the predicition box and scroll\n down to see the model accuracy")
                labelScroll.place(x = 660, y= 410)

                button1 = tk.Button(self, text="Back to Home", command=lambda: controller.show_frame(StartPage))
                button1.place(x = 725, y = 500)

                buttonZ = tk.Button(self, text="Prediction Graph", command=lambda: machineLearningModels.groupPlot(machineLearningModels.predSGD))
                buttonZ.place(x = 275, y = 400)