- Install Virtualbox
- Install XCode and the Command Line Tools
This file contains hidden or 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 torch.autograd import Variable | |
from torch import nn | |
import torch.nn.functional as F | |
class Net(nn.Module): | |
def __init__(self): | |
super(Net, self).__init__() | |
self.conv1 = nn.Conv2d(in_channels=1, out_channels=64, kernel_size=3, stride=2, padding=1) | |
self.conv2 = nn.Conv2d(in_channels=64, out_channels=128, kernel_size=3, stride=1, padding=1) |
This file contains hidden or 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
require 'nn'; | |
net = nn.Sequential() | |
conv1 = nn.SpatialConvolution(1,64,3,3,2,2,1,1) | |
conv2 = nn.SpatialConvolution(64,128,3,3,1,1,1,1) | |
conv3 = nn.SpatialConvolution(128,128,3,3,2,2,1,1) | |
conv4 = nn.SpatialConvolution(128,256,3,3,1,1,1,1) | |
conv5 = nn.SpatialConvolution(256,256,3,3,2,2,1,1) | |
conv6 = nn.SpatialConvolution(256,512,3,3,1,1,1,1) | |
conv11 = nn.SpatialConvolution(512,512,3,3,1,1,1,1) |
This file contains hidden or 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
# PIP | |
export PIP_DOWNLOAD_CACHE=$HOME/.pip_download_cache # http://stackoverflow.com/a/4806458/1094316 | |
# Path to your oh-my-zsh configuration. | |
ZSH=$HOME/.oh-my-zsh | |
# MYSQL | |
MYSQL=/usr/local/mysql/bin | |
export PATH=$PATH:$MYSQL | |
export DYLD_LIBRARY_PATH=/usr/local/mysql/lib:$DYLD_LIBRARY_PATH |
This file contains hidden or 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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, | |
# please see the online documentation at vagrantup.com. |
This file contains hidden or 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
[user] | |
name = Boris Kopin | |
email = [email protected] | |
[core] | |
editor = vim | |
[color] | |
branch = auto | |
diff = auto |
This file contains hidden or 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
currentNgModule.factory("Service1", function($log, $q, $timeout){ | |
return function() { | |
var deferred = $q.defer(); | |
$timeout(function(){ | |
$log.debug("In Service1"); | |
deferred.resolve("Service1"); | |
},1000); | |
return deferred.promise; | |
} | |
}); |
This file contains hidden or 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
# decorator | |
def pure_virtual(func): | |
def closure(*dt, **mp): | |
raise NotImplementedError("Method %s is pure virtual" % func.__name__) | |
return closure | |
class Abstarct(object): | |
""" Abstract class Class """ | |
@pure_virtual | |
def virtual_method(self): pass # Empty Virtual method |
This file contains hidden or 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
syntax on | |
set number | |
set hlsearch | |
" Get scheme from here: | |
" https://github.com/altercation/vim-colors-solarized | |
" colorscheme solarized§ | |
" set background=dark | |
" Disable the swap files creation |
NewerOlder