Created
November 29, 2015 10:08
-
-
Save zeffii/7979b80c1dd61d3028c3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
layout_dict["links"] = [(f_n, f_s, t_n, t_s) for f_n, f_s, t_n, t_s in links | |
if set((f_n, t_n)).isdisjoint(reroutes)] | |
# vs | |
FN = 0 | |
TN = 2 | |
layout_dict["links"] = [tuple(d) for d in links if set((d[FN], d[TN])).isdisjoint(reroutes)] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment