fixed and I added an additional commit.


On Tue, Dec 10, 2013 at 5:17 PM, Pascal Lamblin <notifications@github.com>wrote:

> In theano/tensor/basic.py:
>
> > @@ -3335,6 +3335,36 @@ def R_op(self, inputs, eval_points):
> >              return [None]
> >          return self(*eval_points, **dict(return_list=True))
> >
> > +    def c_code(self, node, nodename, inp, out, sub):
> > +        iname, = inp
> > +        oname, = out
> > +        if isinstance(node.inputs[0].type, TensorType):
> > +            code = ""
> > +            for axis, value in self.axis.iteritems():
> > +                if value:
> > +                    code += """
> > +                if(PyArray_DIMS(%(iname)s)[%(axis)s] != 1){
> > +                    PyErr_Format(PyExc_ValueError,
> > +                        "Dimension %(axis)s in Rebroadcast's input was"
> > +                        " supposed to be 1 (got %s instead)",
>
> Should be %%s, I think.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/Theano/Theano/pull/1659/files#r8249997>
> .
>