--- theano/compile/builders.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/compile/builders.py 2019-08-22 13:25:53.896813593 -0600 @@ -15,7 +15,7 @@ from theano.gradient import Disconnected class OpFromGraph(gof.Op): - """ + r""" This creates an ``Op`` from inputs and outputs lists of variables. The signature is similar to :func:`theano.function ` and the resulting ``Op``'s perform will do the same operation as:: --- theano/compile/function.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/compile/function.py 2019-08-22 13:33:40.346557969 -0600 @@ -243,7 +243,7 @@ def function(inputs, outputs=None, mode= if name is None: # Determine possible file names - source_file = re.sub('\.pyc?', '.py', __file__) + source_file = re.sub(r'\.pyc?', '.py', __file__) compiled_file = source_file + 'c' stack = tb.extract_stack() --- theano/configdefaults.py.orig 2019-08-23 08:49:26.259908947 -0600 +++ theano/configdefaults.py 2019-08-23 08:50:57.173227993 -0600 @@ -1614,7 +1614,7 @@ AddConfigVar("compiledir_format", def default_compiledirname(): formatted = theano.config.compiledir_format % compiledir_format_dict - safe = re.sub("[\(\)\s,]+", "_", formatted) + safe = re.sub(r"[\(\)\s,]+", "_", formatted) return safe --- theano/gof/op.py.orig 2019-08-22 16:26:01.760679539 -0600 +++ theano/gof/op.py 2019-08-23 10:23:51.024394207 -0600 @@ -280,13 +280,13 @@ class CLinkerOp(CLinkerObject): string is the name of a C variable pointing to that input. The type of the variable depends on the declared type of the input. There is a corresponding python variable that - can be accessed by prepending "py_" to the name in the + can be accessed by prepending ```"py_"``` to the name in the list. outputs : list of strings Each string is the name of a C variable where the Op should store its output. The type depends on the declared type of the output. There is a corresponding python variable that - can be accessed by prepending "py_" to the name in the + can be accessed by prepending ```"py_"``` to the name in the list. In some cases the outputs will be preallocated and the value of the variable may be pre-filled. The value for an unallocated output is type-dependent. @@ -343,13 +343,13 @@ class CLinkerOp(CLinkerObject): string is the name of a C variable pointing to that input. The type of the variable depends on the declared type of the input. There is a corresponding python variable that - can be accessed by prepending "py_" to the name in the + can be accessed by prepending ```"py_"``` to the name in the list. outputs : list of strings Each string is the name of a C variable correspoinding to one of the outputs of the Op. The type depends on the declared type of the output. There is a corresponding - python variable that can be accessed by prepending "py_" to + python variable that can be accessed by prepending ```"py_"``` to the name in the list. sub : dict of strings extra symbols defined in `CLinker` sub symbols (such as 'fail'). @@ -784,7 +784,7 @@ class PureOp(object): folded when all its inputs are constant. This allows it to choose where it puts its memory/speed trade-off. Also, it could make things faster as constants can't be used for inplace - operations (see *IncSubtensor). + operations (see *IncSubtensor*). """ return True --- theano/gof/opt.py.orig 2019-08-22 14:06:43.820896086 -0600 +++ theano/gof/opt.py 2019-08-23 08:50:57.175227956 -0600 @@ -112,9 +112,9 @@ class Optimizer(object): Add features to the fgraph that are required to apply the optimization. For example: - fgraph.attach_feature(History()) - fgraph.attach_feature(MyFeature()) - etc. + fgraph.attach_feature(History()) + fgraph.attach_feature(MyFeature()) + etc. """ pass --- theano/gof/unify.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/gof/unify.py 2019-08-22 13:24:58.420815328 -0600 @@ -322,7 +322,7 @@ def unify_walk(a, b, U): @comm_guard(OrVariable, NotVariable) # noqa def unify_walk(o, n, U): - """ + r""" OrV(list1) == NV(list2) == OrV(list1 \ list2) """ --- theano/gof/utils.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/gof/utils.py 2019-08-22 13:22:15.449758115 -0600 @@ -307,7 +307,7 @@ def uniq(seq): def difference(seq1, seq2): - """ + r""" Returns all elements in seq1 which are not in seq2: i.e ``seq1\seq2``. """ --- theano/gpuarray/fft.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/gpuarray/fft.py 2019-08-22 13:36:08.241971287 -0600 @@ -283,7 +283,7 @@ cuirfft_op = CuIRFFTOp() def curfft(inp, norm=None): - """ + r""" Performs the fast Fourier transform of a real-valued input on the GPU. The input must be a real-valued float32 variable of dimensions (m, ..., n). @@ -317,7 +317,7 @@ def curfft(inp, norm=None): def cuirfft(inp, norm=None, is_odd=False): - """ + r""" Performs the inverse fast Fourier Transform with real-valued output on the GPU. The input is a variable of dimensions (m, ..., n//2+1, 2) with --- theano/sandbox/linalg/ops.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/sandbox/linalg/ops.py 2019-08-22 13:37:11.588863356 -0600 @@ -199,7 +199,7 @@ theano.compile.mode.optdb.register('Hint def psd(v): - """ + r""" Apply a hint that the variable `v` is positive semi-definite, i.e. it is a symmetric matrix and :math:`x^T A x \ge 0` for any vector x. --- theano/sparse/basic.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/sparse/basic.py 2019-08-22 16:27:29.828134864 -0600 @@ -4219,9 +4219,9 @@ class ConstructSparseFromList(gof.Op): This create a sparse matrix with the same shape as `x`. Its values are the rows of `values` moved. Pseudo-code:: - output = csc_matrix.zeros_like(x, dtype=values.dtype) - for in_idx, out_idx in enumerate(ilist): - output[out_idx] = values[in_idx] + output = csc_matrix.zeros_like(x, dtype=values.dtype) + for in_idx, out_idx in enumerate(ilist): + output[out_idx] = values[in_idx] """ x_ = theano.tensor.as_tensor_variable(x) --- theano/tensor/fft.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/fft.py 2019-08-22 13:36:23.986695912 -0600 @@ -117,7 +117,7 @@ irfft_op = IRFFTOp() def rfft(inp, norm=None): - """ + r""" Performs the fast Fourier transform of a real-valued input. The input must be a real-valued variable of dimensions (m, ..., n). @@ -151,7 +151,7 @@ def rfft(inp, norm=None): def irfft(inp, norm=None, is_odd=False): - """ + r""" Performs the inverse fast Fourier Transform with real-valued output. The input is a variable of dimensions (m, ..., n//2+1, 2) --- theano/tensor/nlinalg.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/nlinalg.py 2019-08-22 13:34:43.660450608 -0600 @@ -75,7 +75,7 @@ pinv = MatrixPinv() class MatrixInverse(Op): - """Computes the inverse of a matrix :math:`A`. + r"""Computes the inverse of a matrix :math:`A`. Given a square matrix :math:`A`, ``matrix_inverse`` returns a square matrix :math:`A_{inv}` such that the dot product :math:`A \cdot A_{inv}` @@ -149,7 +149,7 @@ matrix_inverse = MatrixInverse() def matrix_dot(*args): - """ Shorthand for product between several dots. + r""" Shorthand for product between several dots. Given :math:`N` matrices :math:`A_0, A_1, .., A_N`, ``matrix_dot`` will generate the matrix product between all in the given order, namely --- theano/tensor/nnet/conv.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/nnet/conv.py 2019-08-22 13:35:27.978675488 -0600 @@ -157,7 +157,7 @@ def conv2d(input, filters, image_shape=N class ConvOp(OpenMPOp): - """ + r""" This Op serves a dual purpose: it can implement a vanilla 2D convolution (as taught in any signal processing class) or implement the convolutional layers found in Convolutional Neural Networks. --- theano/tensor/nnet/neighbours.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/nnet/neighbours.py 2019-08-22 13:36:36.213482065 -0600 @@ -618,7 +618,7 @@ class Images2Neibs(Op): def images2neibs(ten4, neib_shape, neib_step=None, mode='valid'): - """ + r""" Function :func:`images2neibs ` allows to apply a sliding window operation to a tensor containing images or other two-dimensional objects. --- theano/tensor/nnet/nnet.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/nnet/nnet.py 2019-08-22 13:35:17.270862767 -0600 @@ -409,7 +409,7 @@ softmax_grad = SoftmaxGrad() class Softmax(gof.Op): - """ + r""" Softmax activation function :math:`\\varphi(\\mathbf{x})_j = \\frac{e^{\mathbf{x}_j}}{\sum_{k=1}^K e^{\mathbf{x}_k}}` @@ -600,7 +600,7 @@ softmax_op = Softmax() class LogSoftmax(gof.Op): - """ + r""" LogSoftmax activation function :math:`\\varphi(\\mathbf{x})_j = \\e^{(\mathbf{x}_j - log{\sum_{k=1}^K e^{\mathbf{x}_k})}} @@ -1412,7 +1412,7 @@ crossentropy_categorical_1hot_grad = Cro class CrossentropyCategorical1Hot(gof.Op): - """ + r""" Compute the cross entropy between a coding distribution and a true distribution of the form [0, 0, ... 0, 1, 0, ..., 0]. @@ -2051,7 +2051,7 @@ def sigmoid_binary_crossentropy(output, def categorical_crossentropy(coding_dist, true_dist): - """ + r""" Return the cross-entropy between an approximating distribution and a true distribution. --- theano/tensor/opt.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/opt.py 2019-08-22 13:34:16.709921972 -0600 @@ -4582,7 +4582,7 @@ register_canonicalize(gof.OpRemove(T.ten class Canonizer(gof.LocalOptimizer): - """ + r""" Simplification tool. The variable is a local_optimizer. It is best used with a TopoOptimizer in in_to_out order. @@ -4650,7 +4650,7 @@ class Canonizer(gof.LocalOptimizer): return [self.main, self.inverse, self.reciprocal] def get_num_denum(self, input): - """ + r""" This extract two lists, num and denum, such that the input is: self.inverse(self.main(\*num), self.main(\*denum)). It returns the two lists in a (num, denum) pair. @@ -4751,7 +4751,7 @@ class Canonizer(gof.LocalOptimizer): return num, denum def merge_num_denum(self, num, denum): - """ + r""" Utility function which takes two lists, num and denum, and returns something which is equivalent to inverse(main(\*num), main(\*denum)), but depends on the length of num and the length --- theano/tensor/slinalg.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/slinalg.py 2019-08-22 13:36:53.541179005 -0600 @@ -266,7 +266,7 @@ class Solve(Op): return [(rows, cols)] def L_op(self, inputs, outputs, output_gradients): - """ + r""" Reverse-mode gradient updates for matrix solve operation c = A \\\ b. Symbolic expression for updates taken from [#]_. --- theano/tensor/tests/mlp_test.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ theano/tensor/tests/mlp_test.py 2019-08-22 16:30:23.307092085 -0600 @@ -93,7 +93,7 @@ class LogisticRegression(object): self.params = [self.W] def negative_log_likelihood(self, y): - """Return the mean of the negative log-likelihood of the prediction + r"""Return the mean of the negative log-likelihood of the prediction of this model under a given target distribution. .. math:: --- versioneer.py.orig 2019-01-15 14:13:57.000000000 -0700 +++ versioneer.py 2019-08-22 16:19:43.175333211 -0600 @@ -418,7 +418,7 @@ def run_command(commands, args, cwd=None return stdout, p.returncode -LONG_VERSION_PY['git'] = ''' +LONG_VERSION_PY['git'] = r''' # This file helps to compute a version number in source trees obtained from # git-archive tarball (such as those provided by githubs download-from-tag # feature). Distribution tarballs (built by setup.py sdist) and build