Skip to content
Snippets Groups Projects
Commit 558a0f20 authored by Richard Angersbach's avatar Richard Angersbach
Browse files

Expose new reduced assignments to pystencils interface

parent 543bf118
No related branches found
No related tags found
1 merge request!438Reduction Support
......@@ -38,6 +38,14 @@ from .simp import AssignmentCollection
from .sympyextensions.typed_sympy import TypedSymbol, DynamicType
from .sympyextensions import SymbolCreator
from .datahandling import create_data_handling
from .sympyextensions.reduction import (
AddReducedAssignment,
SubReducedAssignment,
MulReducedAssignment,
DivReducedAssignment,
MinReducedssignment,
MaxReducedssignment
)
__all__ = [
"Field",
......@@ -69,6 +77,12 @@ __all__ = [
"AssignmentCollection",
"Assignment",
"AddAugmentedAssignment",
"AddReducedAssignment",
"SubReducedAssignment",
"MulReducedAssignment",
"DivReducedAssignment",
"MinReducedssignment",
"MaxReducedssignment",
"assignment_from_stencil",
"SymbolCreator",
"create_data_handling",
......
......@@ -3,7 +3,7 @@ import numpy as np
import sympy as sp
import pystencils as ps
from sympyextensions.reduction import reduced_assign
from pystencils import AddReducedAssignment
@pytest.mark.parametrize('dtype', ["float64", "float32"])
......@@ -32,7 +32,7 @@ def test_log(dtype):
omega = sp.Symbol("omega")
reduction_assignment = reduced_assign(omega, "+", x.center())
reduction_assignment = AddReducedAssignment(omega, x.center())
ast_reduction = ps.create_kernel(reduction_assignment, default_dtype=dtype)
code_reduction = ps.get_code_str(ast_reduction)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment