class Point:

    def __init__(self, x, y):
        self._x = x
self._y = y

def __eq__(self, other):
    return self._x == other._x and self._y == other._y

def __hash__(self):
    pass
Accessing a dictionary value by custom object value in Python?