forked from ZiadSheriif/Sa7a7LY
-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.py
39 lines (36 loc) · 1.38 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
from excel import runExcel
def interface():
print("---------------------------------------")
print(" GRADES AUTOFILLER ")
print("---------------------------------------")
print("Method for converting Student IDs:")
print("-> Enter 1 for an already-made OCR")
print("-> Enter 2 for features + classifier")
codesChoice = 0
while True:
codesChoice = input("Choice: ")
if (codesChoice == "1" or codesChoice == "2"):
break
else:
print("Error! You can only choose between 1 and 2. Please try again")
print("---------------------------------------")
print("Method for converting Numbers:")
print("-> Enter 1 for an already-made OCR")
print("-> Enter 2 for features + classifier")
digitsChoice = 0
while True:
digitsChoice = input("Choice: ")
if (digitsChoice == "1" or digitsChoice == "2"):
break
else:
print("Error! You can only choose between 1 and 2. Please try again")
print("---------------------------------------")
return int(codesChoice), int(digitsChoice)
def run():
codesChoice, numbersChoice = interface()
print("Processing...")
runExcel(codesChoice, numbersChoice)
print("---------------------------------------")
print("DONE! Output written to 'autoFiller.xls'")
if __name__ == "__main__":
run()