API Documentation

This documentation covers Theano module-wise. This is suited to finding the Types and Ops that you can use to build and compile expression graphs.

There are also some top-level imports that you might find more convenient:


Alias for theano.compile.function.function()


Alias for theano.compile.function.function_dump()


Alias for theano.compile.sharedvalue.shared()

class theano.In[source]

Alias for function.In

theano.dot(x, y)[source]

Works like tensor.dot() for both sparse and dense matrix products

theano.clone_replace(output: Collection[theano.graph.basic.Variable], replace: Optional[Dict[theano.graph.basic.Variable, theano.graph.basic.Variable]] = None, strict: bool = True, share_inputs: bool = True) → Collection[theano.graph.basic.Variable][source]

Clone a graph and replace subgraphs within it.

It returns a copy of the initial subgraph with the corresponding substitutions.

  • output (Theano Variables (or Theano expressions)) – Theano expression that represents the computational graph.
  • replace (dict) – Dictionary describing which subgraphs should be replaced by what.
  • share_inputs (bool) – If True, use the same inputs (and shared variables) as the original graph. If False, clone them. Note that cloned shared variables still use the same underlying storage, so they will always have the same value.