python - Theano: using dot "T" at the end of a dot product where number of dimensions is greater than one -


i going through lstm code jonathan raiman , encountered line of code in "layer" class

if x.ndim > 1:     return  t.nnet.sigmoid(t.dot(self.linear_matrix,x.t)  + self.bias_matrix[:,none]).t   

t "import theano.tensor t"

x symbolic variable

what x.t do? (return statement).t do??

please help.

x.t transpose of matrix x.

.t notation applies transpose numpy matrices, same numpy.transpose(x). should not confused name t import theano.tensor t

and

(return statement).t

returns transpose of output of sigmoid function applied on parameter: t.dot(self.linear_matrix,x.t) + self.bias_matrix[:,none]


Comments

Popular posts from this blog

matlab - error with cyclic autocorrelation function -

django - (fields.E300) Field defines a relation with model 'AbstractEmailUser' which is either not installed, or is abstract -

c# - What is a good .Net RefEdit control to use with ExcelDna? -