Calculating distance matrix finished. R script calls the Python script, and then combines the edge distance info with its own edge attribute distance info.