Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

Jean-Gabriel Young jg-you

View GitHub Profile
@laurencee9
laurencee9 / draw_curved_edges.py
Last active Sep 8, 2018
Draw curved network edges in python
View draw_curved_edges.py
import numpy as np
import matplotlib.patches as mpatches
import networkx as nx
from matplotlib.patches import FancyArrowPatch as ArrowPath
from matplotlib.font_manager import FontProperties
def draw_curved_edges(edges, pos, ax, mu=0.05, edge_color="black", edge_width=1.0, alpha=1.0, arrow_scale=20.0, loopsize=0):
"""
@ByoungInKim
ByoungInKim / create_directory.py
Last active Apr 24, 2019
python - create directory if path if it doesn`t exist for file write
View create_directory.py
import os
directroy = '/home/kenny/gist'
if not os.path.exists(directory):
os.makedirs(directory)
@ksimek
ksimek / program_options_boilerplate.cpp
Last active Feb 20, 2018
Boilerplate code for a C++ program using boost program options. Usage string is automatically generated from positional arguments.
View program_options_boilerplate.cpp
#include <boost/program_options.hpp>
#include <sstream>
#include <fstream>
#include <iterator>
#include <algorithm>
namespace po = boost::program_options;
class Options
{
View project-euler-sha1-hashed-solutions.json
{
"1": "7642c4c2e24b176ed442153e3097e819bf5ca80e",
"2": "b3d784bbaf1286612ad44308231aa58350da17a6",
"3": "a05cb173c1ba1c6ae30bcf5edbd5d5e19566e764",
"4": "55d264f8671b50b5dbaffa56d1ee719fd429e8f4",
"5": "478ec952d186329f825db4ee7978e31dd42de622",
"6": "e82bd73e8c188d151ed790b5ad5a24fa01533fa0",
"7": "28a9dfb84ef81592f21ed285d7cf09be0b605988",
"8": "e98c13fc9df6a893efa0c57bcfa548be664ab8c8",
"9": "af316e6df5bded14f9b268fcbffe7892eb5f244c",
You can’t perform that action at this time.