Problems compiling forms with inv(tensor)*tensor
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
FFC |
Fix Released
|
Undecided
|
Kristian B. Ølgaard |
Bug Description
Making the following trivial modification to the Poisson demo (in DOLFIN),
...
I = Identity(
a = inner(inv(
L = v*f*dx - v*g*ds
...
causes ffc to fail with:
raceback (most recent call last):
File "demo.py", line 44, in <module>
problem = VariationalProb
File "pythonfoo/
self.a = Form(a)
File "pythonfoo/
(self.
File "pythonfoo/
return local_jit(*args, **kwargs)
File "pythonfoo/
return jit_compile(form, options)
File "pythonfoo/
return jit_form(object, options)
File "pythonfoo/
compile(form, signature, options)
File "pythonfoo/
form_code = generate_
File "pythonfoo/
codes.
File "pythonfoo/
code.
File "pythonfoo/
self.
File "pythonfoo/
integrals, Indent, format)
File "pythonfoo/
integral_code, num_ops = transformer.
File "pythonfoo/
loop_code = self.visit(
File "pythonfoo/
r = h(o)
File "pythonfoo/
ops.
File "pythonfoo/
r = h(o, *map(self.visit, o.operands()))
File "pythonfoo/
r = h(o)
File "pythonfoo/
code = self.visit(
File "pythonfoo/
r = h(o)
File "pythonfoo/
code = self.visit(
File "pythonfoo/
r = h(o)
File "pythonfoo/
ops.
File "pythonfoo/
r = h(o, *map(self.visit, o.operands()))
File "pythonfoo/
r = h(o)
File "pythonfoo/
code = self.visit(
File "pythonfoo/
r = h(o)
File "pythonfoo/
code = self.visit(
File "pythonfoo/
r = h(o, *map(self.visit, o.operands()))
File "pythonfoo/
code[key] = val + format_div + format_
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'
Changed in ffc: | |
status: | Confirmed → Fix Committed |
Changed in ffc: | |
status: | Fix Committed → Fix Released |
Quoting Harish Narayanan <email address hidden>:
> Public bug reported: v.cell( ).d) I)*grad( v), grad(u))*dx
>
> Making the following trivial modification to the Poisson demo (in
> DOLFIN),
>
> ...
> I = Identity(
> a = inner(inv(
> L = v*f*dx - v*g*ds
> ...
This should be fixed now.
Kristian
> causes ffc to fail with: lem(a, L, bc) dolfin/ variationalprob lem.py" , line 32, in __init__ dolfin/ form.py" , line 30, in __init__ compiled_ form, module, self.form_data) = jit(form, options) dolfin/ jit.py" , line 44, in mpi_jit dolfin/ jit.py" , line 108, in jit ffc/jit/ jit.py" , line 58, in jit ffc/jit/ jit.py" , line 91, in jit_form ffc/compiler/ compiler. py", line 90, in compile form_code( form_data, representations, prefix, ffc/compiler/ compiler. py", line 177, in generate_form_code code_generator. generate_ integrals( representations [i], ffc/compiler/ quadrature/ quadraturegener ator.py" , line 73, self.generate_ cell_integrals( form_representa tion, format)) ffc/compiler/ quadrature/ quadraturegener ator.py" , line 101, cell_integrals cell_integral( form_representa tion, transformer, integrals, ffc/compiler/ quadrature/ quadraturegener ator.py" , line 161, cell_integral ffc/compiler/ quadrature/ quadraturegener ator.py" , line 342, element_ tensor generate_ code(integral. integrand( ), ffc/compiler/ quadrature/ quadraturetrans formerbase. py", line integrand) ufl/algorithms/ transformations .py", line 132, in visit ffc/compiler/ quadrature/ quadraturetrans formerbase. py", line self.visit( summand) ) ufl/algorithms/ transformations .py", line 128, in visit ufl/algorithms/ transformations .py", line 132, in visit ffc/compiler/ quadrature/ quadraturetrans formerbase. py", line indexed_ expr) ufl/algorithms/ transformations .py", line 132, in visit ffc/compiler/ quadrature/ quadraturetrans formerbase. py", line component_ expr) ufl/algorithms/ transformations .py", line 132, in visit ffc/compiler/ quadrature/ quad...
>
> raceback (most recent call last):
> File "demo.py", line 44, in <module>
> problem = VariationalProb
> File "pythonfoo/
> self.a = Form(a)
> File "pythonfoo/
> (self._
> File "pythonfoo/
> return local_jit(*args, **kwargs)
> File "pythonfoo/
> return jit_compile(form, options)
> File "pythonfoo/
> return jit_form(object, options)
> File "pythonfoo/
> compile(form, signature, options)
> File "pythonfoo/
> form_code = generate_
> format.format, options)
> File "pythonfoo/
> codes.append(
> format))
> File "pythonfoo/
> in generate_integrals
> code.update(
> File "pythonfoo/
> in generate_
> self.generate_
> format)
> File "pythonfoo/
> in generate_
> integrals, Indent, format)
> File "pythonfoo/
> in __generate_
> integral_code, num_ops = transformer.
> Indent, interior)
> File "pythonfoo/
> 696, in generate_code
> loop_code = self.visit(
> File "pythonfoo/
> r = h(o)
> File "pythonfoo/
> 528, in index_sum
> ops.append(
> File "pythonfoo/
> r = h(o, *map(self.visit, o.operands()))
> File "pythonfoo/
> r = h(o)
> File "pythonfoo/
> 491, in indexed
> code = self.visit(
> File "pythonfoo/
> r = h(o)
> File "pythonfoo/
> 616, in component_tensor
> code = self.visit(
> File "pythonfoo/
> r = h(o)
> File "pythonfoo/