@@ -198,16 +198,16 @@ sentences, dimension of the embedding space X context window size).
198198
199199Let's compile a theano function to do so
200200
201- >>> x
201+ >>> sample
202202 array([0, 1, 2, 3, 4], dtype=int32)
203- >>> cx = contextwin(x , 7)
203+ >>> csample = contextwin(sample , 7)
204204 [[-1, -1, -1, 0, 1, 2, 3],
205205 [-1, -1, 0, 1, 2, 3, 4],
206206 [-1, 0, 1, 2, 3, 4,-1],
207207 [ 0, 1, 2, 3, 4,-1,-1],
208208 [ 1, 2, 3, 4,-1,-1,-1]]
209209 >>> f = theano.function(inputs=[idxs], outputs=x)
210- >>> f(cx )
210+ >>> f(csample )
211211 array([[-0.08088442, 0.08458307, 0.05064092, ..., 0.06876887,
212212 -0.06648078, -0.15192257],
213213 [-0.08088442, 0.08458307, 0.05064092, ..., 0.11192625,
@@ -218,7 +218,7 @@ Let's compile a theano function to do so
218218 0.10804889, 0.1247109 ],
219219 [ 0.18738101, 0.14727569, -0.069544 , ..., -0.00937143,
220220 0.10804889, 0.1247109 ]], dtype=float32)
221- >>> f(cx ).shape
221+ >>> f(csample ).shape
222222 (5, 350)
223223
224224
0 commit comments