Skip to content

Instantly share code, notes, and snippets.

Elias Hasle EliasHasle

Block or report user

Report or block EliasHasle

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
EliasHasle /
Last active Apr 14, 2019
Retro SuperMarioBros-Nes wrapper that skips busy frames and converts to discrete action space (alpha, not thoroughly tested)
#Inspired by
#but copying directly from neither.
#Requires retro.
#Requires SuperMarioBros NES rom (USA/Japan). Once you have it, can be imported to retro:
#> python -m retro.import directory_name
#(identifies the ROM if it is there and has the .nes extension.)
EliasHasle / ball_bounce.m
Created Oct 7, 2017
Matlab function to calculate exact vertical position and velocity of a single bouncing ball (with given coefficient of restitution less than one) at any time or array of times
View ball_bounce.m
%There probably is room for more optimization in the form of vectorization.
%You see, Matlab is not my first language.
function [ values ] = ball_bounce( initials, k, tt)
%initials: column vector of initial vertical position and velocity
%k: coefficient of restitution (must be less than one)
%tt: array of times
You can’t perform that action at this time.