def cells_to_directed_edge()

in src/h3/api/memview_int/__init__.py [0:0]


def cells_to_directed_edge(origin, destination):
    """
    Create an H3 Index denoting a unidirectional edge.

    The edge is constructed from neighboring cells ``origin`` and
    ``destination``.

    Parameters
    ----------
    origin : H3Cell
    destination : H3Cell

    Raises
    ------
    ValueError
        When cells are not adjacent.

    Returns
    -------
    H3Edge
    """
    o = _in_scalar(origin)
    d = _in_scalar(destination)
    e = _cy.cells_to_directed_edge(o, d)
    e = _out_scalar(e)

    return e