docs: def _vertex_net_cost(vertex, v2n, placements, has_wrap_around_links, machine):
      """Get the total cost of the nets connected to the given vertex.
  
      Parameters
      ----------
      vertex
          The vertex whose nets we're interested in.
      v2n : {vertex: [:py:class:`rig.netlist.Net`, ...], ...}
      placements : {vertex: (x, y), ...}
      has_wrap_around_links : bool
      machine : :py:class:`rig.place_and_route.Machine`
  
      Returns
      -------
      float
      """
      total_cost = 0.0
      for net in v2n[vertex]:
          total_cost += _net_cost(net, placements, has_wrap_around_links,
                                  machine)
  
      return total_cost