.. _f-citytour: module ``challenge.city_tour`` ============================== .. inheritance-diagram:: ensae_projects.challenge.city_tour Short summary +++++++++++++ module ``ensae_projects.challenge.city_tour`` Function to solve the problem of the `Route Inspection Problem `_. :githublink:`%|py|6` Classes +++++++ +-----------------------------------------------------------------------------------+-------------------------+ | class | truncated documentation | +===================================================================================+=========================+ | :class:`SolutionException ` | wrong solution | +-----------------------------------------------------------------------------------+-------------------------+ Functions +++++++++ +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | function | truncated documentation | +====================================================================================+==========================================================================================================================+ | :func:`_delete_edge ` | Removes an edge from the graph. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`_euler_path ` | Computes an Eulerian path. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`_explore_path ` | Explores an Eulerian path, remove used edges from *edges_from*. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`bellman_distances ` | Computes shortest distances between all vertices. It assumes edges are symmetric. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`best_euler_path ` | Computes the final solution for the Eulerian path. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`compute_degrees ` | Compute the degree of vertices. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`dijkstra_path ` | Returns the best path between two vertices. Uses `Dikjstra `_ ... | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`distance_solution ` | Checks if a solution is really a solution and returns the distance of it, None if it is not a solution. The function ... | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`distance_vertices ` | Computes the length of edges if distances is None. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`euler_path ` | Computes an Eulerian path. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`haversine_distance ` | Computes `Haversine formula `_. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ | :func:`matching_vertices ` | Finds the best match between vertices. | +------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------+ Documentation +++++++++++++ .. automodule:: ensae_projects.challenge.city_tour :members: :special-members: __init__ :show-inheritance: