Tasked with brainstorming, designing,and implementing a project which utilizes Artificial Intelligence. (Can be anything you want to code, just has to utilize some form of A.I) (This section below...

1 answer below »

Tasked with brainstorming, designing,and implementing a project which utilizes Artificial Intelligence. (Can be anything you want to code, just has to utilize some form of A.I)




(This section below needs to get done and sent to me asap. This part is specifically Due at 3/13/21)


Must write/define the “Minimum Viable Product” (MVP) and three or more “Stretch Goals”. The Minimum Viable Product is the bare minimum that can be delivered while still performing the necessary functions for the chosen project to be considered acceptable. Also include the AI algorithm(s) you plan on using.




All this information doesn’t have to be long. This can be less than 3 sentences for all I care, it just has to get the point across.




(This section below doesn’t need to be sent to me immediately. Send this to me when done with the project)


Must write down what went through the development process from start to finish. Do not skip over what went wrong!




-------------------------------------------------------------------------------------------------------------------------------


Code you can use:



Java



If you use a flat directory structure (i.e. not using packages), then please only provide your .java files. Your .class files, .jar files, and any Eclipse, NetBeans, BlueJ, etc. folders and metadata are not necessary. If you are using packages, then make sure your directories are correctly formatted in your compressed file.


/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\



C/C++



Any IDE files and metadata are unnecessary. Please only include .c, .cpp, and .h files. I will use GCC v4.9.2 (32 bit) on Windows OR Microsoft Visual C++ 2019 to compile the code, so if you use compiler-specific features that are not compatible, please include a .exe file as well.


/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\



C#


All Visual Studio files are unnecessary. Please only include .cs files. If you're using a preview branch of the .NET framework beyond 5.0, please include a .exe file as well.


/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\



Python



Any IDE files and metadata are unnecessary. Please only include .py files. I will use Python 3.3.0 to run the code. Note that Python versions are notoriously incompatible- so if you're using a 2.x distribution, please include an .exe file along with your code or let me know beforehand.



Answered 1 days AfterMar 12, 2021

Answer To: Tasked with brainstorming, designing,and implementing a project which utilizes Artificial...

Neha answered on Mar 13 2021
146 Votes
77560 - AI/Handwritten digit recognizer/gui_digit_recognizer.py
from keras.models import load_model
from tkinter import *
import tkinter as tk
import win32gui
from PIL import ImageGrab, Image
import
numpy as np
model = load_model('mnist.h5')
def predict_digit(img):
img = img.resize((32,32))
img = img.convert('L')
img = np.array(img)
img = img.reshape(1,28,28,1)
img = img/255.0
res = model.predict([img])[0]
return np.argmax(res), max(res)
class App(tk.Tk):
def __init__(self):
tk.Tk.__init__(self)
self.x = self.y = 0
self.canvas = tk.Canvas(self, width=300, height=300, bg = "white", cursor="cross")
self.label = tk.Label(self, text="Draw..", font=("Helvetica", 48))
self.classify_btn = tk.Button(self, text = "Recognise", command = self.classify_handwriting)
self.button_clear = tk.Button(self, text = "Clear", command = self.clear_all)

self.canvas.grid(row=0, column=0, pady=2, sticky=W, )
self.label.grid(row=0, column=1,pady=2, padx=2)
self.classify_btn.grid(row=1, column=1, pady=2, padx=2)
self.button_clear.grid(row=1, column=0, pady=2)

self.canvas.bind("", self.draw_lines)
def clear_all(self):
self.canvas.delete("all")

def classify_handwriting(self):
HWND = self.canvas.winfo_id()
rect = win32gui.GetWindowRect(HWND)
a,b,c,d = rect
rect=(a+4,b+4,c-4,d-4)
im = ImageGrab.grab(rect)
digit, acc = predict_digit(im)
self.label.configure(text= str(digit)+', '+ str(int(acc*100))+'%')
def draw_lines(self, event):
self.x = event.x
self.y = event.y
r=8
self.canvas.create_oval(self.x-r, self.y-r, self.x + r, self.y + r, fill='black')

app = App()
mainloop()
77560 - AI/Handwritten digit recognizer/mnist.h5
77560 - AI/Handwritten digit recognizer/train_digit_recognizer.py
import keras
from keras.datasets...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here