Models | Examples |
---|---|
Display ads | Yahoo! |
Search ads |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class A | |
class A2 extends A | |
class B | |
trait M[X] | |
// | |
// Upper Type Bound | |
// | |
def upperTypeBound[AA <: A](x: AA): A = x |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[merge] | |
keepBackup = false | |
tool = custom | |
[mergetool "custom"] | |
cmd = /Applications/p4merge.app/Contents/Resources/launchp4merge "$PWD/$BASE" "$PWD/$REMOTE" "$PWD/$LOCAL" "$PWD/$MERGED" | |
keepTemporaries = false | |
trustExitCode = false | |
keepBackup = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Convert Markdown to Wordpress blogging format | |
# Required program(s) | |
req_progs=(ascii2uni pandoc) | |
for p in ${req_progs[@]}; do | |
hash "$p" 2>&- || \ | |
{ echo >&2 " Required program \"$p\" not installed."; exit 1; } | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from scipy import linalg | |
from sklearn.utils import array2d, as_float_array | |
from sklearn.base import TransformerMixin, BaseEstimator | |
class ZCA(BaseEstimator, TransformerMixin): | |
def __init__(self, regularization=10**-5, copy=False): | |
self.regularization = regularization |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Add Google Analytics tracking code to HTML response | |
# | |
# Usage: | |
# set $tracking_id 'UA-12345678-9'; | |
# include incl/analytics.conf; | |
# | |
# It needs nginx compiled with option --with-http_sub_module. | |
# Uses optimized GA code from: http://mathiasbynens.be/notes/async-analytics-snippet | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Distributions | |
export Measure, DiscreteMeasure, Estimator, EstimatorQuality, | |
blb, randsubset | |
abstract Measure | |
type DiscreteMeasure{S<:Number,T<:Number} <: Measure | |
points :: Vector{S} | |
weights :: Vector{T} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:precise | |
MAINTAINER Bohdan Mushkevych | |
# Installing Oracle JDK | |
RUN apt-get -y install python-software-properties ;\ | |
add-apt-repository ppa:webupd8team/java ;\ | |
apt-get update && apt-get -y upgrade ;\ | |
echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections ;\ | |
apt-get -y install oracle-java7-installer && apt-get clean ;\ | |
update-alternatives --display java ;\ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* bisecting <master> <input> <nNodes> <subIterations> | |
* | |
* divisive hierarchical clustering using bisecting k-means | |
* assumes input is a text file, each row is a data point | |
* given as numbers separated by spaces | |
* | |
*/ | |
import org.apache.spark.SparkContext |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo | |
sudo sed -i s/\$releasever/6/g /etc/yum.repos.d/epel-apache-maven.repo | |
sudo yum install -y apache-maven | |
mvn --version |
OlderNewer