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 __future__ import print_function | |
from time import sleep | |
import os | |
type_to_rep = { | |
'empty': '.', | |
'head': 'H', | |
'tail': 'T', | |
'conductor': '=', |
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 __future__ import print_function | |
import theano | |
import theano.tensor as T | |
import numpy as np | |
import time | |
X = theano.shared(value=np.asarray([[0, 1], [1, 0], [0, 0], [1, 1]]), name='X') | |
y = theano.shared(value=np.asarray([[0], [0], [1], [1]]), name='y') | |
rng = np.random.RandomState(1234) |
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 __future__ import print_function | |
import json | |
import os | |
import numpy as np | |
from gensim.models import Word2Vec | |
from gensim.utils import simple_preprocess | |
from keras.engine import Input | |
from keras.layers import Embedding, merge |
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 FastScanner { | |
BufferedReader br; | |
StringTokenizer st; | |
public FastScanner() { | |
br = new BufferedReader(new InputStreamReader(System.in)); | |
} | |
String next() { | |
while (st == null || !st.hasMoreElements()) { |
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
// reference: http://codeforces.com/contest/697/problem/C | |
import java.util.HashMap; | |
import java.util.Map; | |
import java.util.Scanner; | |
public class Codeforces697ProblemC { | |
public static void main(String... args) { | |
Scanner s = new Scanner(System.in); | |
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
[>....................]how compare home insurance | |
Predicted: ([ 0.39381921])in order to calculate your annual premium for home insurance it be necessary answer some basic question about the risk and obtain a quote basic characteristic of the home will include the year build , square footage , type of roof , foundation type , number of bathroom , style of home , prior claim and identify information of the owner you may obtain a quote and buy home insurance online use an online link in multiple state ; it may be use by escrow / closing professional , mortgage professional , real estate agent directly consumer an exemplary online experience for all WEBSITELINK | |
Expected: ([ 0.38000157])start by talk to your Insurance Professional it be important not only compare coverage offering and policy extension and limitation , but also the company that be offer this protection proposal and suggest coverage shall be base upon the result of a careful Reconstruction Analysis which will determine the amount of recommend covera |
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 keras.optimizers import SGD, Adagrad, RMSprop, Adadelta, Adam, Adamax | |
import keras.backend as K | |
DEFAULT_NOISE = 0.05 | |
def ballpark_gradient(gradient, noise): | |
return [g * K.random_normal(shape=K.shape(g), mean=1.0, std=noise) for g in gradient] | |
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 keras.engine import InputSpec | |
from keras.layers import Dense | |
from keras.layers.wrappers import Wrapper, TimeDistributed | |
class Freeway(Wrapper): | |
def __init__(self, layer, gate=None, **kwargs): | |
self.supports_masking = True | |
self.gate = gate | |
super(Freeway, self).__init__(layer, **kwargs) |
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 __future__ import print_function | |
import numpy as np | |
from keras.engine import Input, Model | |
from keras.layers import Dense | |
X = np.asarray([[0, 1], [1, 0], [0, 0], [1, 1]]) | |
y = np.asarray([[0], [0], [1], [1]]) | |
input = Input(shape=(2,)) |
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
execute pathogen#infect() | |
colorscheme badwolf | |
" turns of syntax highlighting | |
syntax enable | |
" use spaces not tabs | |
set tabstop=8 softtabstop=0 expandtab shiftwidth=2 smarttab | |
" show line numbers |
OlderNewer