I'm writing an heuristic algorithm for the Travelling Salesman Problem. In one step, I have to generate a random path of length $n$ in a graph $G$. There is a real number in $[0, 1]$ associated to each edge. I want to generate a random path with a probability that is proportional to the sum (or product) of these weights for all edges in the given path. I don't even know if these weights actually form a probability function, or I have to do some scaling first.
EDIT:
The question is how to generate such a path. I'm also open to suggestions on how to generate a path that favors edges with higher preference values, even if it doesn't follow the exact distribution I mentioned. I just to want to have random paths that somehow favor my preferences.