15 lines
356 B
Python
15 lines
356 B
Python
import pickle
|
|
import sys
|
|
|
|
|
|
def prediction(warzywo, nawoz ,srodek, stan_wzrostu):
|
|
filename = 'decisionTree.sav'
|
|
tree = pickle.load(open(filename, 'rb'))
|
|
print(tree.predict([[warzywo, nawoz, srodek, stan_wzrostu]]))
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
# Map command line arguments to function arguments.
|
|
prediction(*sys.argv[1:])
|