import math


def bearing(obj_pos):
    """
    Return bearing of an object:
    https://en.wikipedia.org/wiki/Bearing_(navigation). Used to determine
    an objects center in x-direction (more to the left or right in the image)
    """
    angle = math.atan2(obj_pos[0], -obj_pos[2])
    return math.degrees(angle)