Skip to content

Instantly share code, notes, and snippets.

#include "mtrain.hpp"
#include "bsp.h"
#include <unistd.h>
#include "PinDefs.hpp"
USBD_HandleTypeDef USBD_Device;
class TempObj {
#include "mtrain.hpp"
#include "bsp.h"
#include <unistd.h>
#include "PinDefs.hpp"
USBD_HandleTypeDef USBD_Device;
// Doesn't crash
import main
import robocup
import behavior
import constants
import enum
import standard_play
import evaluation.shooting
import evaluation.passing
import tactics.coordinated_pass
#include <string>
#include <regex>
#include <iostream>
#include <algorithm>
int main(int argc, char *argv[]) {
std::string input = "5mm asdf 6mm asdf";
std::string output = "";
// If we get a good string from user, use that
#pragma once
#include <deque>
#include <flann/algorithms/dist.h>
#include <flann/algorithms/kdtree_single_index.h>
#include <flann/flann.hpp>
#include <functional>
#include <list>
#include <memory>
#include <rrt/StateSpace.hpp>
import play
import behavior
import robocup
import main
import constants
class TestIdle(play.Play):
def __init__(self):
super().__init__(continuous=True)
self.add_transition(behavior.Behavior.State.start,
TEST(WindowEvaluator, test_bug) {
SystemState state;
OurRobot* obstacleBot = state.self[0];
obstacleBot->visible = true;
obstacleBot->pos = Point(0, 3.5);
Segment ourGoalSegment(
Point(Field_Dimensions::Current_Dimensions.GoalWidth() / 2.0, 0),
Point(-Field_Dimensions::Current_Dimensions.GoalWidth() / 2.0, 0));
Clear[bUpper, bLower, kmean, kstdev, r1mean, r1stdev, r2mean, \
r2stdev, r3mean, r3stdev]
ClearAll["Global'*"]
bUpper = 1; bLower = -1; kmean = 0; kstdev = .1;
r1stdev = 0.1; r2stdev = 0.1; r3stdev = .1;
bounds = UnitStep[x - bUpper] + (1 - UnitStep[x - bLower]);
kickdistr = PDF[NormalDistribution[kmean, kstdev], x];
(* "Complement" of a normal distribution*)
r1form = Sqrt[2*Pi] * r1stdev *
@JNeiger
JNeiger / Robocup.nb
Last active February 14, 2017 20:32
Clear[r1mean, r1stdev, r2mean, r2stdev, r3mean, r3stdev, kmean,
kstdev, bUpper, bLower];
r1mean = -1; r1stdev = .1; r2mean = 0; r2stdev = .1; r3mean = 0.5; \
r3stdev = .2;
kmean = 0; kstdev = .1; bUpper = 2; bLower = -2;
robots = Sqrt[2*Pi] * r1stdev *
PDF[NormalDistribution[r1mean, r1stdev], x] +
Sqrt[2*Pi] * r2stdev *
PDF[NormalDistribution[r2mean, r2stdev], x] +
Sqrt[2*Pi] * r3stdev * PDF[NormalDistribution[r3mean, r3stdev], x];
function robocup_graph()
% Turn off warnings due to lineintersect
% producing warnings about possible float errors for
% values near zero
warning('off','all');
l = 10;
w = 5;
num_l = 100;
num_w = 50;
num_graphs = 4;