-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better sum factorisation for coefficients #81
Conversation
COFFEE loop merger does not like them.
Seems to fix sum factorisation for coefficient derivatives.
Not need any more.
tensor = numpy.empty(expression.shape, dtype=object) | ||
for alpha in numpy.ndindex(expression.shape): | ||
tensor[alpha] = Indexed(expression, alpha) | ||
expression = ListTensor(tensor) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a redundant line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This converts a numpy array to a GEM object.
for alpha in numpy.ndindex(expression.shape): | ||
tensor[alpha] = Indexed(expression, alpha) | ||
expression = ListTensor(tensor) | ||
expression, = remove_componenttensors((ListTensor(tensor),)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This converts a numpy array to a GEM object.
As well as this line...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, I see...
This hopefully does right what #80 did not. Summary of changes:
IndexSum
nodesTicks three boxes in #75, and closes coneoproject/COFFEE#97.