Skip to content

Instantly share code, notes, and snippets.

View Ueva's full-sized avatar

Joshua Evans Ueva

View GitHub Profile
import networkx as nx
def create_graph(transitions):
# Add an edge for each transition to the graph.
stg = nx.DiGraph()
for state, next_state in transitions:
stg.add_node(state)
stg.add_node(next_state)
stg.add_edge(state, next_state)
import copy
import math
import operator
import functools
import numpy as np
import networkx as nx
from barl_envs.envs.hanoi import HanoiEnvironment
@Ueva
Ueva / latex_imports.tex
Last active September 2, 2020 02:21
Generic Latex Imports & Setup
%%
%% Default imports and settings that I use whenever starting a new LaTeX
%% project. Designed to be as portable as possible, and as a result there might
%% be some imports which are redundant based on your distribution.
%%
%% Should provide you with a relatively nice starting point and
%% provide most of the functionality you could ever need.
%% For citations, this uses natbib by default, with support for
%% the harvard package's syntax.
%%