Sztuczna_Inteligencja-projekt/cases.py

259 lines
12 KiB
Python
Raw Normal View History

2021-06-03 16:06:34 +02:00
class Case:
def __init__(self, values, attributes, Class):
self.values = values
self.attributes = attributes
self.Class = Class
attributes = ["field.hydration", "field.fertility", "species", "ticks", "is_healthy", "field.tractor_there"]
cases = [Case([4, 0, "potato", 0, 1, 0], attributes, 0),
Case([2, 0, "sorrel", 1, 1, 0], attributes, 1),
Case([4, 1, "wheat", 0, 0, 1], attributes, 0),
Case([1, 1, "potato", 1, 0, 1], attributes, 0),
Case([2, 1, "potato", 0, 0, 1], attributes, 0),
Case([2, 0, "potato", 0, 1, 0], attributes, 0),
Case([1, 1, "strawberry", 1, 0, 1], attributes, -1),
Case([1, 0, "wheat", 1, 1, 1], attributes, 0),
Case([2, 0, "wheat", 1, 0, 1], attributes, 0),
Case([1, 1, "strawberry", 0, 1, 1], attributes, 0),
Case([3, 1, "potato", 1, 1, 0], attributes, 1),
Case([2, 1, "strawberry", 1, 0, 0], attributes, 0),
Case([4, 0, "wheat", 1, 1, 1], attributes, 0),
Case([4, 1, "wheat", 1, 0, 1], attributes, 0),
Case([5, 1, "potato", 1, 1, 1], attributes, 0),
Case([4, 0, "strawberry", 1, 0, 0], attributes, 0),
Case([1, 1, "sorrel", 1, 0, 0], attributes, 0),
Case([0, 0, "sorrel", 0, 0, 1], attributes, 0),
Case([2, 0, "sorrel", 1, 1, 0], attributes, 1),
Case([0, 1, "sorrel", 0, 1, 1], attributes, 0),
Case([0, 1, "strawberry", 1, 1, 0], attributes, -1),
Case([2, 0, "sorrel", 0, 1, 1], attributes, 0),
Case([4, 0, "wheat", 1, 0, 1], attributes, 0),
Case([5, 0, "wheat", 0, 0, 0], attributes, 0),
Case([0, 0, "strawberry", 1, 0, 0], attributes, -1),
Case([4, 0, "sorrel", 1, 0, 0], attributes, 0),
Case([3, 0, "sorrel", 0, 0, 1], attributes, 0),
Case([3, 1, "potato", 1, 0, 1], attributes, 0),
Case([4, 1, "potato", 0, 0, 1], attributes, 0),
Case([1, 1, "wheat", 0, 1, 1], attributes, 0),
Case([3, 0, "wheat", 0, 1, 1], attributes, 0),
Case([2, 0, "wheat", 0, 0, 0], attributes, 0),
Case([5, 1, "potato", 1, 1, 1], attributes, 0),
Case([4, 1, "strawberry", 0, 0, 1], attributes, 0),
Case([1, 0, "potato", 1, 1, 0], attributes, 0),
Case([4, 1, "sorrel", 1, 1, 1], attributes, 0),
Case([0, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([4, 0, "strawberry", 1, 0, 0], attributes, 0),
Case([4, 0, "sorrel", 1, 0, 0], attributes, 0),
Case([5, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([3, 1, "wheat", 1, 1, 1], attributes, 0),
Case([3, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([4, 0, "potato", 0, 0, 1], attributes, 0),
Case([5, 1, "wheat", 1, 1, 1], attributes, 0),
Case([3, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([3, 0, "sorrel", 0, 0, 1], attributes, 0),
Case([0, 0, "potato", 1, 1, 1], attributes, -1),
Case([4, 0, "strawberry", 1, 1, 1], attributes, 0),
Case([2, 1, "strawberry", 1, 0, 1], attributes, 0),
Case([2, 1, "wheat", 0, 0, 1], attributes, 0),
Case([2, 1, "sorrel", 1, 1, 0], attributes, 1),
Case([1, 0, "potato", 1, 0, 1], attributes, 0),
Case([4, 0, "strawberry", 1, 0, 0], attributes, 0),
Case([4, 1, "potato", 1, 1, 1], attributes, 0),
Case([0, 0, "strawberry", 1, 0, 1], attributes, -1),
Case([0, 1, "wheat", 0, 0, 0], attributes, 0),
Case([1, 1, "wheat", 0, 1, 0], attributes, 0),
Case([0, 0, "sorrel", 1, 1, 0], attributes, -1),
Case([2, 0, "sorrel", 0, 0, 1], attributes, 0),
Case([5, 1, "wheat", 1, 1, 1], attributes, 0),
Case([2, 0, "strawberry", 0, 1, 0], attributes, 0),
Case([2, 1, "wheat", 0, 0, 1], attributes, 0),
Case([3, 0, "potato", 1, 0, 1], attributes, 0),
Case([5, 0, "wheat", 1, 1, 1], attributes, 0),
Case([0, 1, "strawberry", 1, 0, 0], attributes, -1),
Case([0, 0, "wheat", 0, 0, 0], attributes, 0),
Case([5, 0, "potato", 1, 1, 0], attributes, 1),
Case([2, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([3, 1, "sorrel", 0, 1, 0], attributes, 0),
Case([2, 1, "potato", 1, 1, 1], attributes, 0),
Case([5, 0, "strawberry", 1, 1, 0], attributes, 1),
Case([5, 0, "wheat", 0, 0, 0], attributes, 0),
Case([5, 0, "wheat", 1, 1, 0], attributes, 1),
Case([2, 0, "potato", 1, 0, 0], attributes, 0),
Case([3, 1, "wheat", 0, 1, 0], attributes, 0),
Case([3, 0, "potato", 1, 1, 1], attributes, 0),
Case([0, 1, "sorrel", 1, 1, 1], attributes, -1),
Case([0, 0, "strawberry", 1, 1, 1], attributes, -1),
Case([2, 1, "strawberry", 0, 1, 0], attributes, 0),
Case([0, 1, "sorrel", 1, 1, 0], attributes, -1),
Case([3, 0, "wheat", 0, 1, 1], attributes, 0),
Case([4, 0, "strawberry", 1, 0, 1], attributes, 0),
Case([3, 1, "potato", 0, 0, 1], attributes, 0),
Case([1, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([5, 1, "wheat", 1, 0, 1], attributes, 0),
Case([5, 0, "potato", 1, 0, 1], attributes, 0),
Case([3, 0, "potato", 0, 0, 1], attributes, 0),
Case([1, 0, "wheat", 0, 1, 0], attributes, 0),
Case([5, 0, "sorrel", 0, 1, 1], attributes, 0),
Case([4, 0, "potato", 0, 1, 0], attributes, 0),
Case([0, 0, "strawberry", 0, 0, 0], attributes, 0),
Case([5, 0, "sorrel", 1, 1, 0], attributes, 1),
Case([4, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([1, 1, "strawberry", 1, 1, 0], attributes, -1),
Case([5, 0, "strawberry", 1, 0, 0], attributes, 0),
Case([5, 1, "wheat", 0, 0, 0], attributes, 0),
Case([0, 1, "sorrel", 1, 1, 0], attributes, -1),
Case([3, 1, "potato", 1, 0, 1], attributes, 0),
Case([1, 0, "sorrel", 0, 0, 0], attributes, 0),
Case([3, 0, "wheat", 0, 1, 1], attributes, 0),
Case([0, 0, "wheat", 0, 0, 1], attributes, 0),
Case([1, 0, "potato", 0, 0, 0], attributes, 0),
Case([1, 1, "sorrel", 0, 1, 0], attributes, 0),
Case([0, 1, "strawberry", 0, 1, 0], attributes, 0),
Case([5, 1, "potato", 1, 0, 1], attributes, 0),
Case([2, 0, "strawberry", 1, 1, 1], attributes, 0),
Case([4, 1, "wheat", 1, 0, 0], attributes, 0),
Case([0, 1, "sorrel", 1, 1, 0], attributes, -1),
Case([1, 0, "strawberry", 1, 1, 1], attributes, -1),
Case([4, 0, "wheat", 0, 0, 0], attributes, 0),
Case([4, 0, "strawberry", 0, 1, 0], attributes, 0),
Case([0, 0, "sorrel", 1, 0, 1], attributes, -1),
Case([1, 0, "strawberry", 0, 1, 0], attributes, 0),
Case([0, 0, "strawberry", 1, 1, 1], attributes, -1),
Case([2, 1, "potato", 0, 0, 0], attributes, 0),
Case([3, 1, "strawberry", 1, 1, 0], attributes, 1),
Case([1, 0, "sorrel", 1, 1, 1], attributes, 0),
Case([5, 1, "strawberry", 1, 1, 0], attributes, 1),
Case([2, 0, "wheat", 1, 1, 1], attributes, 0),
Case([5, 1, "strawberry", 0, 1, 0], attributes, 0),
Case([1, 1, "wheat", 0, 1, 1], attributes, 0),
Case([1, 1, "potato", 0, 1, 0], attributes, 0),
Case([4, 0, "potato", 1, 1, 0], attributes, 1),
Case([2, 1, "strawberry", 0, 0, 1], attributes, 0),
Case([0, 1, "potato", 0, 0, 1], attributes, 0),
Case([3, 0, "sorrel", 1, 0, 1], attributes, 0),
Case([4, 0, "wheat", 1, 0, 1], attributes, 0),
Case([5, 1, "sorrel", 1, 0, 0], attributes, 0),
Case([1, 0, "sorrel", 1, 0, 0], attributes, 0),
Case([5, 0, "sorrel", 1, 0, 1], attributes, 0),
Case([2, 1, "potato", 1, 0, 1], attributes, 0),
Case([1, 0, "potato", 1, 1, 1], attributes, 0),
Case([4, 0, "wheat", 1, 1, 0], attributes, 1),
Case([0, 0, "sorrel", 0, 1, 0], attributes, 0),
Case([2, 0, "wheat", 0, 0, 1], attributes, 0),
Case([0, 1, "potato", 1, 0, 1], attributes, -1),
Case([0, 1, "sorrel", 1, 0, 1], attributes, -1),
Case([1, 1, "potato", 0, 0, 1], attributes, 0),
Case([3, 0, "sorrel", 1, 1, 1], attributes, 0),
Case([0, 0, "potato", 1, 0, 1], attributes, -1),
Case([4, 0, "potato", 0, 0, 1], attributes, 0),
Case([0, 0, "strawberry", 1, 0, 0], attributes, -1),
Case([0, 0, "strawberry", 1, 1, 1], attributes, -1),
Case([5, 0, "potato", 0, 1, 1], attributes, 0),
Case([2, 0, "potato", 0, 0, 0], attributes, 0),
Case([0, 1, "potato", 1, 0, 0], attributes, -1),
Case([1, 0, "potato", 0, 0, 1], attributes, 0),
Case([4, 0, "sorrel", 1, 0, 1], attributes, 0),
Case([1, 0, "potato", 1, 0, 0], attributes, 0),
Case([5, 1, "potato", 1, 0, 1], attributes, 0),
Case([2, 1, "wheat", 1, 0, 0], attributes, 0),
Case([0, 1, "potato", 1, 1, 1], attributes, -1),
Case([5, 1, "strawberry", 0, 1, 0], attributes, 0),
Case([3, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([3, 0, "strawberry", 1, 0, 0], attributes, 0),
Case([0, 1, "strawberry", 0, 0, 1], attributes, 0),
Case([0, 1, "wheat", 0, 0, 0], attributes, 0),
Case([0, 1, "strawberry", 1, 0, 0], attributes, -1),
Case([1, 0, "potato", 0, 0, 1], attributes, 0),
Case([1, 1, "wheat", 0, 0, 0], attributes, 0),
Case([0, 1, "strawberry", 1, 0, 1], attributes, -1),
Case([1, 1, "potato", 0, 0, 1], attributes, 0),
Case([0, 0, "wheat", 0, 0, 1], attributes, 0),
Case([4, 1, "sorrel", 1, 1, 1], attributes, 0),
Case([5, 1, "wheat", 0, 0, 1], attributes, 0),
Case([5, 1, "strawberry", 0, 0, 0], attributes, 0),
Case([4, 1, "wheat", 0, 0, 1], attributes, 0),
Case([1, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([1, 1, "potato", 1, 1, 0], attributes, 0),
Case([0, 1, "sorrel", 1, 0, 0], attributes, -1),
Case([5, 0, "sorrel", 1, 0, 0], attributes, 0),
Case([0, 0, "strawberry", 1, 1, 1], attributes, -1),
Case([0, 0, "potato", 0, 0, 0], attributes, 0),
Case([0, 0, "strawberry", 1, 1, 1], attributes, -1),
Case([4, 0, "strawberry", 0, 0, 1], attributes, 0),
Case([2, 0, "potato", 1, 0, 0], attributes, 0),
Case([4, 0, "strawberry", 0, 0, 0], attributes, 0),
Case([0, 1, "strawberry", 0, 1, 1], attributes, 0),
Case([1, 1, "wheat", 1, 1, 0], attributes, 0),
Case([3, 0, "potato", 0, 1, 0], attributes, 0),
Case([1, 1, "wheat", 0, 1, 0], attributes, 0),
Case([1, 1, "sorrel", 0, 0, 1], attributes, 0),
Case([3, 1, "wheat", 0, 0, 0], attributes, 0),
Case([3, 1, "wheat", 0, 0, 0], attributes, 0),
Case([1, 0, "wheat", 0, 1, 1], attributes, 0),
Case([5, 1, "potato", 1, 0, 1], attributes, 0),
Case([5, 0, "wheat", 0, 0, 1], attributes, 0),
Case([2, 1, "sorrel", 0, 1, 0], attributes, 0),
Case([5, 0, "sorrel", 1, 0, 0], attributes, 0),
Case([1, 0, "potato", 1, 1, 1], attributes, 0),
Case([5, 1, "wheat", 1, 1, 0], attributes, 1),
Case([3, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([5, 0, "wheat", 0, 0, 1], attributes, 0),
Case([2, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([1, 0, "potato", 1, 1, 1], attributes, 0),
Case([0, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([5, 1, "potato", 1, 1, 0], attributes, 1),
Case([2, 0, "wheat", 0, 1, 0], attributes, 0),
Case([3, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([3, 0, "potato", 1, 1, 0], attributes, 0),
Case([1, 1, "potato", 0, 0, 0], attributes, 0),
Case([2, 1, "potato", 0, 1, 0], attributes, 0),
Case([2, 1, "wheat", 0, 1, 0], attributes, 0),
Case([2, 0, "sorrel", 1, 1, 0], attributes, 1),
Case([3, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([2, 0, "wheat", 1, 1, 1], attributes, 0),
Case([5, 0, "wheat", 1, 1, 0], attributes, 1),
Case([1, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([0, 1, "potato", 0, 0, 0], attributes, 0),
Case([5, 1, "strawberry", 1, 1, 1], attributes, 0),
Case([4, 1, "wheat", 1, 0, 0], attributes, 0),
Case([5, 1, "sorrel", 0, 0, 1], attributes, 0),
Case([1, 1, "wheat", 1, 0, 0], attributes, 0),
Case([5, 0, "strawberry", 1, 0, 1], attributes, 0),
Case([5, 0, "wheat", 1, 0, 1], attributes, 0),
Case([2, 0, "potato", 1, 0, 1], attributes, 0),
Case([3, 1, "wheat", 1, 0, 0], attributes, 0),
Case([0, 1, "strawberry", 1, 0, 0], attributes, -1),
Case([0, 1, "strawberry", 0, 1, 1], attributes, 0),
Case([3, 0, "wheat", 0, 1, 0], attributes, 0),
Case([4, 1, "potato", 1, 1, 1], attributes, 0),
Case([3, 0, "potato", 0, 0, 1], attributes, 0),
Case([2, 1, "strawberry", 1, 1, 0], attributes, 0),
Case([1, 1, "sorrel", 0, 0, 0], attributes, 0),
Case([4, 1, "wheat", 1, 0, 1], attributes, 0),
Case([2, 0, "potato", 0, 1, 0], attributes, 0),
Case([5, 0, "sorrel", 0, 1, 1], attributes, 0),
Case([0, 1, "wheat", 1, 1, 0], attributes, -1),
Case([5, 1, "wheat", 1, 0, 0], attributes, 0),
Case([2, 0, "potato", 0, 0, 0], attributes, 0),
Case([2, 0, "strawberry", 0, 1, 1], attributes, 0),
Case([4, 1, "potato", 0, 1, 1], attributes, 0),
Case([0, 1, "sorrel", 1, 1, 0], attributes, -1),
Case([1, 1, "strawberry", 1, 0, 1], attributes, -1),
Case([3, 0, "sorrel", 1, 1, 0], attributes, 1),
Case([5, 1, "wheat", 1, 0, 0], attributes, 0),
Case([4, 0, "sorrel", 1, 1, 0], attributes, 1),
Case([2, 1, "sorrel", 1, 0, 0], attributes, 0),
Case([0, 1, "wheat", 0, 1, 0], attributes, 0),
Case([5, 0, "potato", 1, 1, 0], attributes, 1),
Case([3, 1, "strawberry", 0, 1, 0], attributes, 0),
Case([5, 1, "strawberry", 0, 0, 0], attributes, 0),
Case([4, 1, "potato", 1, 1, 1], attributes, 0),
Case([5, 1, "potato", 1, 0, 1], attributes, 0),
Case([5, 1, "potato", 1, 1, 1], attributes, 0),
Case([0, 0, "sorrel", 0, 0, 0], attributes, 0),
Case([1, 1, "sorrel", 1, 1, 0], attributes, 1),
Case([0, 1, "potato", 0, 1, 0], attributes, 0),
Case([4, 1, "strawberry", 1, 1, 1], attributes, 0),
Case([0, 0, "wheat", 0, 1, 1], attributes, 0),
Case([3, 0, "wheat", 1, 1, 0], attributes, 1)]