diff --git a/__init__.py b/__init__.py index 1a81830067bba340a602f87f2e20369500502930..513808744da84e549813b49a97970783bdb67d05 100644 --- a/__init__.py +++ b/__init__.py @@ -1,3 +1,3 @@ from pystencils.field import Field, extractCommonSubexpressions -from pystencils.types import TypedSymbol +from pystencils.data_types import TypedSymbol from pystencils.slicing import makeSlice diff --git a/astnodes.py b/astnodes.py index cdaf8fbc2046a3fd8390e7d1268ff3a42baff620..001be76b6b4fad421f995637cb043e46f5aa1790 100644 --- a/astnodes.py +++ b/astnodes.py @@ -1,7 +1,7 @@ import sympy as sp from sympy.tensor import IndexedBase from pystencils.field import Field -from pystencils.types import TypedSymbol, createType, get_type_from_sympy, createTypeFromString, castFunc +from pystencils.data_types import TypedSymbol, createType, get_type_from_sympy, createTypeFromString, castFunc class ResolvedFieldAccess(sp.Indexed): diff --git a/backends/cbackend.py b/backends/cbackend.py index 98d4b9c238b655ecad9b7d4dc176c57223976cf0..2086973ddc1dfcee68452dc0ed6cd753414270dd 100644 --- a/backends/cbackend.py +++ b/backends/cbackend.py @@ -9,7 +9,7 @@ from sympy.core.mul import _keep_coeff from sympy.core import S from pystencils.astnodes import Node, ResolvedFieldAccess, SympyAssignment -from pystencils.types import createType, PointerType, getTypeOfExpression, VectorType, castFunc +from pystencils.data_types import createType, PointerType, getTypeOfExpression, VectorType, castFunc from pystencils.backends.simd_instruction_sets import selectedInstructionSet diff --git a/backends/llvm.py b/backends/llvm.py index 3a7e3f1940383062bfdd83f0e1bf4b8e65a9e2ca..34fed3765007d1e5bb5ab5ae51958b03c3df77db 100644 --- a/backends/llvm.py +++ b/backends/llvm.py @@ -6,7 +6,7 @@ from sympy import S # S is numbers? from pystencils.llvm.control_flow import Loop -from ..types import createType +from ..data_types import createType from ..astnodes import Indexed diff --git a/cpu/cpujit.py b/cpu/cpujit.py index e893a7771912399e385b10a7a41c51e7fbb0be2e..a64f045298099650295ff9692dba5646c0ab8008 100644 --- a/cpu/cpujit.py +++ b/cpu/cpujit.py @@ -73,7 +73,7 @@ from ctypes import cdll from pystencils.backends.cbackend import generateC, getHeaders from collections import OrderedDict, Mapping from pystencils.transformations import symbolNameToVariableName -from pystencils.types import toCtypes, getBaseType, StructType +from pystencils.data_types import toCtypes, getBaseType, StructType def makePythonFunction(kernelFunctionNode, argumentDict={}): diff --git a/cpu/kernelcreation.py b/cpu/kernelcreation.py index 718dd1cb93f0d7b84d047a3886cb61634e071a57..616c89253d368c8e4ce21dd3f84b29b57ea2b34c 100644 --- a/cpu/kernelcreation.py +++ b/cpu/kernelcreation.py @@ -4,7 +4,7 @@ from pystencils.astnodes import SympyAssignment, Block, LoopOverCoordinate, Kern from pystencils.transformations import resolveFieldAccesses, makeLoopOverDomain, \ typeAllEquations, getOptimalLoopOrdering, parseBasePointerInfo, moveConstantsBeforeLoop, splitInnerLoop, \ substituteArrayAccessesWithConstants -from pystencils.types import TypedSymbol, BasicType, StructType, createType +from pystencils.data_types import TypedSymbol, BasicType, StructType, createType from pystencils.field import Field import pystencils.astnodes as ast diff --git a/types.py b/data_types.py similarity index 100% rename from types.py rename to data_types.py diff --git a/field.py b/field.py index fd8641c74e3ff4dfa9ea42f596a8bdebb19ee99c..4ad087243a4a11a41f7983b7b54b85dd1b0d26d9 100644 --- a/field.py +++ b/field.py @@ -3,7 +3,7 @@ import numpy as np import sympy as sp from sympy.core.cache import cacheit from sympy.tensor import IndexedBase -from pystencils.types import TypedSymbol, createType +from pystencils.data_types import TypedSymbol, createType class Field(object): diff --git a/gpucuda/cudajit.py b/gpucuda/cudajit.py index 6c6bc09d953b77b9ac798de2a98cfbff53a48ef3..04561e8b638dd837627faeda88bcce33d13764ab 100644 --- a/gpucuda/cudajit.py +++ b/gpucuda/cudajit.py @@ -4,7 +4,7 @@ import pycuda.autoinit from pycuda.compiler import SourceModule from pystencils.backends.cbackend import generateC from pystencils.transformations import symbolNameToVariableName -from pystencils.types import StructType, getBaseType +from pystencils.data_types import StructType, getBaseType def makePythonFunction(kernelFunctionNode, argumentDict={}): diff --git a/gpucuda/indexing.py b/gpucuda/indexing.py index 9c7f1be6bb6b2e728076211b263f9637608da58d..000be750d8f684b63fecc8304d6c6d5c28ee2035 100644 --- a/gpucuda/indexing.py +++ b/gpucuda/indexing.py @@ -6,7 +6,7 @@ import pycuda.autoinit from pystencils.astnodes import Conditional, Block from pystencils.slicing import normalizeSlice -from pystencils.types import TypedSymbol, createTypeFromString +from pystencils.data_types import TypedSymbol, createTypeFromString BLOCK_IDX = [TypedSymbol("blockIdx." + coord, createTypeFromString("int")) for coord in ('x', 'y', 'z')] THREAD_IDX = [TypedSymbol("threadIdx." + coord, createTypeFromString("int")) for coord in ('x', 'y', 'z')] diff --git a/gpucuda/kernelcreation.py b/gpucuda/kernelcreation.py index fa067348851381353d83a24a021e71ac79ff96d4..959a94b49dcb6591105ed10d48ffb3f1c1953122 100644 --- a/gpucuda/kernelcreation.py +++ b/gpucuda/kernelcreation.py @@ -2,7 +2,7 @@ from pystencils.gpucuda.indexing import BlockIndexing from pystencils.transformations import resolveFieldAccesses, typeAllEquations, parseBasePointerInfo, getCommonShape, \ substituteArrayAccessesWithConstants from pystencils.astnodes import Block, KernelFunction, SympyAssignment, LoopOverCoordinate -from pystencils.types import TypedSymbol, BasicType, StructType +from pystencils.data_types import TypedSymbol, BasicType, StructType from pystencils import Field diff --git a/kerncraft/generate_benchmark.py b/kerncraft/generate_benchmark.py index 12c3401de28446270044675093b2c8360a481e43..ede96d12b7d437d5b20ac098189f9c9d34d21e90 100644 --- a/kerncraft/generate_benchmark.py +++ b/kerncraft/generate_benchmark.py @@ -1,7 +1,7 @@ from jinja2 import Template from pystencils.cpu import generateC from pystencils.sympyextensions import prod -from pystencils.types import getBaseType +from pystencils.data_types import getBaseType benchmarkTemplate = Template(""" #include "kerncraft.h" diff --git a/llvm/jit.py b/llvm/jit.py index aa53eb285859dee7807f4d839e6191ec26a108fc..918c202f3e19355ee4f6ca43aca8d2e6e2595b91 100644 --- a/llvm/jit.py +++ b/llvm/jit.py @@ -1,6 +1,6 @@ import llvmlite.ir as ir import llvmlite.binding as llvm -from ..types import toCtypes, createType +from ..data_types import toCtypes, createType import ctypes as ct diff --git a/llvm/kernelcreation.py b/llvm/kernelcreation.py index 5473b9ce7ed5034de38fb748affd176a2a17b05f..403c9bb537b1573e436acb50e02fc73524302062 100644 --- a/llvm/kernelcreation.py +++ b/llvm/kernelcreation.py @@ -2,7 +2,7 @@ import sympy as sp from pystencils.transformations import resolveFieldAccesses, makeLoopOverDomain, typingFromSympyInspection, \ typeAllEquations, getOptimalLoopOrdering, parseBasePointerInfo, moveConstantsBeforeLoop, splitInnerLoop, \ desympy_ast, insert_casts -from pystencils.types import TypedSymbol +from pystencils.data_types import TypedSymbol from pystencils.field import Field import pystencils.astnodes as ast diff --git a/transformations.py b/transformations.py index 38c6717b0ca67189264de918f70c84b70e2f13e5..b7ac891f56347391603e41874e9b9b7d9ae19a19 100644 --- a/transformations.py +++ b/transformations.py @@ -7,7 +7,7 @@ from sympy.logic.boolalg import Boolean from sympy.tensor import IndexedBase from pystencils.field import Field, offsetComponentToDirectionString -from pystencils.types import TypedSymbol, createType, PointerType, StructType, getBaseType, castFunc +from pystencils.data_types import TypedSymbol, createType, PointerType, StructType, getBaseType, castFunc from pystencils.slicing import normalizeSlice import pystencils.astnodes as ast diff --git a/vectorization.py b/vectorization.py index c933a5fe0754be9ec5e1612eda05156d1bebafe6..3f9a359c9e3136b62abe82cfa19ae2b0a141cef0 100644 --- a/vectorization.py +++ b/vectorization.py @@ -2,7 +2,7 @@ import sympy as sp import warnings from pystencils.transformations import filteredTreeIteration -from pystencils.types import TypedSymbol, VectorType, BasicType, getTypeOfExpression, castFunc, collateTypes +from pystencils.data_types import TypedSymbol, VectorType, BasicType, getTypeOfExpression, castFunc, collateTypes import pystencils.astnodes as ast