Closed ypxie closed 8 years ago
The map
operates over the examples in the mini batch, so x
in cosine_similarity
is effectively a matrix, and y
is a tensor3 (there's a mistake in the documentation, thank you for pointing that out!).
This is clearly not the best way to loop over the different batches, but I didn't find a cleaner way to directly work on the matrix/tensor3 version unfortunately.
z, _ = theano.map(step, sequences=[x, y]). Should x be in the non_sequence?