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
import networkx as nx | |
import matplotlib.pyplot as plt | |
def draw_weighted_graph(G, pos=None, | |
node_size=200, | |
edge_width=3, | |
font_size=12, | |
node_color='red', | |
color_map='Blues'): | |
"""Draw a networkx graph with weighted edges""" |
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
git config --global alias.cmp '!f() { git status && | |
read -p "Are you sure? " -n 1 -r && | |
if [[ $REPLY =~ ^[Yy]$ ]] | |
then | |
git add -A && git commit -m "$@" && git push | |
fi; }; f' |
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
git config --global alias.cmp '!f() { git status && | |
read -p "Are you sure? " -n 1 -r && | |
if [[ $REPLY =~ ^[Yy]$ ]] | |
then | |
git add -A && git commit -m "$@" && git push | |
fi; }; f' |