Skip to content

Instantly share code, notes, and snippets.

Mohammad Rashid dopplesoldner

Block or report user

Report or block dopplesoldner

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
@dopplesoldner
dopplesoldner / autodeploy.json
Last active May 5, 2017
Kubernetes GPU autodeploy file
View autodeploy.json
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"dnsNamePrefix": {
"type": "string",
"metadata": {
"description": "Sets the Domain name prefix for the cluster. The concatenation of the domain name and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address."
}
},
View setup.sh
#!/bin/sh
sudo apt-get -y update
# Install nvidia drivers
sudo apt-get install -y ubuntu-drivers-common
sudo ubuntu-drivers devices
sudo apt-get -y install $(sudo ubuntu-drivers devices | grep "driver" | grep "recommended" | grep -o '\bnvidia-\w*')
sudo apt-get -y install nvidia-modprobe
#Set up docker repository
sudo apt-get install -y --no-install-recommends \
apt-transport-https \
View install_cuda.sh
wget http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1404/x86_64/cuda-repo-ubuntu1404_7.5-18_amd64.deb
sudo dpkg -i cuda-repo-ubuntu1404_7.5-18_amd64.deb
sudo apt-get update
sudo apt-get upgrade -y
sudo apt-get install -y opencl-headers build-essential protobuf-compiler \
libprotoc-dev libboost-all-dev libleveldb-dev hdf5-tools libhdf5-serial-dev \
libopencv-core-dev libopencv-highgui-dev libsnappy-dev libsnappy1 \
libatlas-base-dev cmake libstdc++6-4.8-dbg libgoogle-glog0 libgoogle-glog-dev \
libgflags-dev liblmdb-dev git python-pip gfortran
View update_gitignore.sh
git rm -r --cached .
git add .
View gist:3fa7923a185ec26f5ba7
mkdir -p ~/.vim/after/plugin
ln -s ~/.vim/bundle/ultisnips/after/plugin/* ~/.vim/after/plugin
mkdir ~/.vim/ftdetect
ln -s ~/.vim/bundle/ultisnips/ftdetect/* ~/.vim/ftdetect
View Serializer.cs
public static class Serializer
{
public static byte[] Serialize<T>(T obj)
{
var serializer = new DataContractSerializer(typeof(T));
var stream = new MemoryStream();
using (var writer =
XmlDictionaryWriter.CreateBinaryWriter(stream))
{
serializer.WriteObject(writer, obj);
View gist:9602502
# Get latest Sun Java SDK in v6 from Oracle
wget http://download.oracle.com/otn-pub/java/jdk/6u31-b04/jdk-6u31-linux-x64-rpm.bin
# make it exec
chmod +x jdk-6u31-linux-x64-rpm.bin
# Install Java
sudo ./jdk-6u31-linux-x64-rpm.bin
# Check if the default java version is set to sun jdk
View gist:9365046
# First verify the version of Java being used is not SunJSK.
java -version
# Get the latest Sun Java SDK from Oracle http://www.oracle.com/technetwork/java/javase/downloads/jdk-7u1-download-513651.html
wget http://download.oracle.com/otn-pub/java/jdk/7u1-b08/jdk-7u1-linux-i586.rpm
# Rename the file downloaded, just to be nice
mv jdk-7u1-linux-i586.rpm\?e\=1320265424\&h\=916f87354faed15fe652d9f76d64c844 jdk-7u1-linux-i586.rpm
# Install Java
You can’t perform that action at this time.