Skip to content

Instantly share code, notes, and snippets.

Avatar

Daryl Wilding-McBride DarylWM

  • The Walter & Eliza Hall Institute of Medical Research
  • Melbourne, Australia
View GitHub Profile
@DarylWM
DarylWM / deep-learning-setup.md
Last active Nov 18, 2016
Steps to set up a Deep Learning machine
View deep-learning-setup.md

Create a 16.04 bootable install USB drive

http://unetbootin.github.io/

Install Ubuntu 16.04

  • sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade
  • sudo apt-get install make cmake gcc g++

Install NVIDIA drivers

  • sudo apt-get install dkms build-essential linux-headers-generic
@DarylWM
DarylWM / tf8_aws.sh
Last active May 3, 2016 — forked from dennybritz/tf8_aws.sh
TensorFlow 0.8 on AWS GPU Ubuntu 14.04 instance
View tf8_aws.sh
# Install build tools
sudo apt-get update
sudo apt-get install -y build-essential git python-pip libfreetype6-dev libxft-dev libncurses-dev libopenblas-dev gfortran python3-matplotlib libblas-dev liblapack-dev libatlas-base-dev python3-dev linux-headers-generic linux-image-extra-virtual unzip python3-numpy swig python3-pandas python-sklearn unzip python3-pip
sudo pip3 install -U pip
sudo pip3 install -U ipython jupyter scikit-learn
# Install CUDA 7
# wget http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1410/x86_64/cuda-repo-ubuntu1410_7.0-28_amd64.deb
wget http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1504/x86_64/cuda-repo-ubuntu1504_7.5-18_amd64.deb
sudo dpkg -i cuda-repo-ubuntu1504_7.5-18_amd64.deb && rm cuda-repo-ubuntu1504_7.5-18_amd64.deb
View bundle out 2
[OnInit] Running program /odm_app/OpenDroneMap/bin/bundler
Loading images from file '/vagrant_data/odm_data/police/reconstruction-with-image-size-2400/list.txt'
[BundlerApp::OnInit] Processing options...
[BundlerApp::OnInit] Loading frame...
[BundlerApp::OnInit] Loading images...
[LoadMatchTable] Loading matches
[PruneDoubleMatches] Pruned[0,1] = 24 / 2180
[PruneDoubleMatches] Pruned[1,2] = 21 / 2201
[PruneDoubleMatches] Pruned[2,3] = 30 / 2645
[PruneDoubleMatches] Pruned[3,4] = 27 / 2601
View out
[OnInit] Running program /odm_app/OpenDroneMap/bin/bundler
Loading images from file '/vagrant_data/odm_data/police/reconstruction-with-image-size-2400/list.txt'
[BundlerApp::OnInit] Processing options...
[BundlerApp::OnInit] Loading frame...
[BundlerApp::OnInit] Loading images...
[LoadMatchTable] Loading matches
[PruneDoubleMatches] Pruned[0,1] = 24 / 2180
[PruneDoubleMatches] Pruned[1,2] = 21 / 2201
[PruneDoubleMatches] Pruned[2,3] = 30 / 2645
[PruneDoubleMatches] Pruned[3,4] = 27 / 2601
View gist:7701543
Feature: Testing Cucumber Integration
Scenario: Cucumber Integration # example.feature:3
Given I have setup Play # Steps.I_have_setup_Play()
When I go to the landing page # Steps.I_go_to_the_landing_page()
Then the title should be "Cucumber" # Steps.the_title_should_be(String)
1 Scenarios (1 passed)
3 Steps (3 passed)
0m2.092s
View gist:7701514
import com.google.inject.Inject;
import com.google.inject.name.Named;
import cucumber.api.java.en.Given;
import cucumber.api.java.en.Then;
import cucumber.api.java.en.When;
import play.test.TestBrowser;
import static org.fest.assertions.Assertions.assertThat;
public class Steps {
@Inject
View gist:7701508
import com.google.inject.Inject;
import cucumber.api.java.Before;
import play.test.TestBrowser;
import play.test.TestServer;
import static play.test.Helpers.*;
public class GlobalHooks {
@Inject
private TestBrowser testBrowser;
@Inject
View gist:7701502
import com.google.inject.AbstractModule;
import com.google.inject.name.Names;
import play.test.TestBrowser;
import play.test.TestServer;
import static play.test.Helpers.*;
public class CucumberModule extends AbstractModule {
private static int PORT = 3333;
private TestServer testServer = testServer(PORT, fakeApplication(inMemoryDatabase()));
private TestBrowser testBrowser = testBrowser(HTMLUNIT, PORT);
View ricky.sbt
name := "sample-with-cucumber"
version := "1.0-SNAPSHOT"
libraryDependencies ++= Seq(
javaJdbc,
javaEbean,
cache,
"com.google.inject" % "guice" % "3.0" % "test",
"info.cukes" % "cucumber-guice" % "1.1.5" % "test",