diff --git a/.flake8 b/.flake8
index 5701df707c82aa801b4a6bb80a98a56b42cb1e8c..8b65d20eb6e409eb3d7a611be92c264d9662f1b9 100644
--- a/.flake8
+++ b/.flake8
@@ -1,6 +1,6 @@
 [flake8]
 max-line-length=120
-exclude=pystencils/jupyter.py,
-        pystencils/plot.py
-        pystencils/session.py
+exclude=src/pystencils/jupyter.py,
+        src/pystencils/plot.py
+        src/pystencils/session.py
 ignore = W293 W503 W291 C901 E741
diff --git a/.gitignore b/.gitignore
index 14a4632ba4d89311393748baf1fd7160fa02d025..992284e7dccd8d0b523d16017acb1672ad3e2fcb 100644
--- a/.gitignore
+++ b/.gitignore
@@ -15,12 +15,12 @@ _build
 _local_tmp
 RELEASE-VERSION
 test-report
-pystencils/boundaries/createindexlistcython.c
-pystencils/boundaries/createindexlistcython.*.so
-pystencils_tests/tmp
-pystencils_tests/var
-pystencils_tests/kerncraft_inputs/.2d-5pt.c_kerncraft/
-pystencils_tests/kerncraft_inputs/.3d-7pt.c_kerncraft/
+src/pystencils/boundaries/createindexlistcython.c
+src/pystencils/boundaries/createindexlistcython.*.so
+tests/tmp
+tests/var
+tests/kerncraft_inputs/.2d-5pt.c_kerncraft/
+tests/kerncraft_inputs/.3d-7pt.c_kerncraft/
 report.xml
 coverage_report/
 
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index f1ac3470f59d15a8ede4ad7a90b2601138376e66..c05cdb088684064f59151439bea2cf0640edc2a7 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -13,16 +13,17 @@ tests-and-coverage:
     variables:
       - $ENABLE_NIGHTLY_BUILDS
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
+  before_script:
+    - pip install -e .
   script:
-    - pip install sympy --upgrade
     - env
     - pip list
     - export NUM_CORES=$(nproc --all)
     - mkdir -p ~/.config/matplotlib
     - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
     - mkdir public
-    - py.test -v -n $NUM_CORES --cov-report html --cov-report xml --cov-report term --cov=. -m "not longrun" --html test-report/index.html --junitxml=report.xml
-    - python3 -m coverage xml
+    - pytest -v -n $NUM_CORES --cov-report html --cov-report xml --cov-report term --cov=. -m "not longrun" --html test-report/index.html --junitxml=report.xml
+    - python -m coverage xml
   tags:
     - docker
     - cuda11
@@ -45,8 +46,10 @@ tests-and-coverage-with-longrun:
   when: manual
   allow_failure: true
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
-  script:
+  before_script:
     - pip install sympy --upgrade
+    - pip install -e .
+  script:
     - env
     - pip list
     - export NUM_CORES=$(nproc --all)
@@ -66,9 +69,12 @@ latest-python:
     variables:
       - $ENABLE_NIGHTLY_BUILDS
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/latest_python
+  before_script:
+    - pip install -e .
   script:
     - env
     - pip list
+    - pip install -e .
     - export NUM_CORES=$(nproc --all)
     - mkdir -p ~/.config/matplotlib
     - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
@@ -107,18 +113,16 @@ ubuntu:
       - $ENABLE_NIGHTLY_BUILDS
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/ubuntu
   before_script:
-    - apt-get -y remove python3-sympy
     - ln -s /usr/include/locale.h /usr/include/xlocale.h
-    - pip3 install `grep -Eo 'sympy[>=]+[0-9\.]+' setup.py | sed 's/>/=/g'`
-    # - pip3 install `grep -Eo 'sympy[>=]+[0-9\.]+' setup.py | sed 's/>/=/g'`
+    - pip3 install -e .
   script:
     - export NUM_CORES=$(nproc --all)
     - mkdir -p ~/.config/matplotlib
     - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
     - sed -i 's/--doctest-modules //g' pytest.ini
     - env
-    - pip3 list
-    - pytest-3 -v -n $NUM_CORES -m "not longrun" --junitxml=report.xml
+    - pip list
+    - pytest -v -n $NUM_CORES -m "not longrun" --junitxml=report.xml
   tags:
     - docker
     - cuda11
@@ -134,6 +138,8 @@ ubuntu:
     variables:
       - $ENABLE_NIGHTLY_BUILDS
   before_script: &multiarch_before_script
+    # - pip3 install -v .
+    - export PYTHONPATH=src
     - python3 -c "import pystencils as ps; ps.cpu.cpujit.read_config()"
     - sed -i '/^fail_under.*/d' pytest.ini
   script:
@@ -143,7 +149,7 @@ ubuntu:
     - sed -i 's/--doctest-modules //g' pytest.ini
     - env
     - pip3 list
-    - pytest-3 -v -n $NUM_CORES --junitxml=report.xml pystencils_tests/test_*vec*.py pystencils_tests/test_random.py pystencils_tests/test_half_precision.py
+    - python3 -m pytest -v -n $NUM_CORES --junitxml=report.xml tests/test_*vec*.py tests/test_random.py tests/test_half_precision.py
   tags:
     - docker
     - AVX
@@ -199,8 +205,10 @@ minimal-conda:
     variables:
       - $ENABLE_NIGHTLY_BUILDS
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/minimal_conda
+  before_script:
+    - pip install -e .
   script:
-    - python setup.py quicktest
+    - python quicktest.py
   tags:
     - docker
     - cuda
@@ -212,9 +220,11 @@ minimal-sympy-master:
     variables:
       - $ENABLE_NIGHTLY_BUILDS
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/minimal_conda
+  before_script:
+    - pip install -e .
   script:
     - python -m pip install --upgrade git+https://github.com/sympy/sympy.git
-    - python setup.py quicktest
+    - python quicktest.py
   allow_failure: true
   tags:
     - docker
@@ -275,7 +285,7 @@ flake8-lint:
       - $ENABLE_NIGHTLY_BUILDS
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
   script:
-    - flake8 pystencils
+    - flake8 src/pystencils
   tags:
     - docker
 
@@ -283,8 +293,9 @@ flake8-lint:
 build-documentation:
   stage: test
   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/documentation
+  before_script:
+    - pip install -e .
   script:
-    - export PYTHONPATH=`pwd`
     - mkdir html_doc
     - sphinx-build -b html doc  html_doc
     - sphinx-build -W -b html doc  html_doc
diff --git a/MANIFEST.in b/MANIFEST.in
index 3d3c4785554f28413d417f1d059051d0967ba9cf..db0bf6352a30f5d23215e61ebcf2fd89982dc3c4 100644
--- a/MANIFEST.in
+++ b/MANIFEST.in
@@ -1,8 +1,3 @@
-include README.md
-include COPYING.txt
 include AUTHORS.txt
 include CONTRIBUTING.md
-CHANGELOG.md
-global-include *.pyx
-include versioneer.py
-include pystencils/_version.py
+include CHANGELOG.md
diff --git a/conftest.py b/conftest.py
index 4af58abc28902146267d07401c178097707638f8..2fd7f8e819a410f51cad0360300d187f50935c09 100644
--- a/conftest.py
+++ b/conftest.py
@@ -39,48 +39,48 @@ def add_path_to_ignore(path):
 
 
 collect_ignore = [os.path.join(SCRIPT_FOLDER, "doc", "conf.py"),
-                  os.path.join(SCRIPT_FOLDER, "pystencils", "opencl", "opencl.autoinit")]
-add_path_to_ignore('pystencils_tests/benchmark')
+                  os.path.join(SCRIPT_FOLDER, "src", "pystencils", "opencl", "opencl.autoinit")]
+add_path_to_ignore('tests/benchmark')
 add_path_to_ignore('_local_tmp')
 
 
 try:
     import cupy
 except ImportError:
-    collect_ignore += [os.path.join(SCRIPT_FOLDER, "pystencils_tests/test_gpu.py")]
-    add_path_to_ignore('pystencils/gpu')
+    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_gpu.py")]
+    add_path_to_ignore('src/pystencils/gpu')
 
 try:
     import waLBerla
 except ImportError:
-    collect_ignore += [os.path.join(SCRIPT_FOLDER, "pystencils_tests/test_aligned_array.py"),
-                       os.path.join(SCRIPT_FOLDER, "pystencils_tests/test_datahandling_parallel.py"),
+    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_aligned_array.py"),
+                       os.path.join(SCRIPT_FOLDER, "tests/test_datahandling_parallel.py"),
                        os.path.join(SCRIPT_FOLDER, "doc/notebooks/03_tutorial_datahandling.ipynb"),
-                       os.path.join(SCRIPT_FOLDER, "pystencils/datahandling/parallel_datahandling.py"),
-                       os.path.join(SCRIPT_FOLDER, "pystencils_tests/test_small_block_benchmark.ipynb")]
+                       os.path.join(SCRIPT_FOLDER, "src/pystencils/datahandling/parallel_datahandling.py"),
+                       os.path.join(SCRIPT_FOLDER, "tests/test_small_block_benchmark.ipynb")]
 
 try:
     import blitzdb
 except ImportError:
-    add_path_to_ignore('pystencils/runhelper')
-    collect_ignore += [os.path.join(SCRIPT_FOLDER, "pystencils_tests/test_parameterstudy.py")]
-    collect_ignore += [os.path.join(SCRIPT_FOLDER, "pystencils_tests/test_json_serializer.py")]
+    add_path_to_ignore('src/pystencils/runhelper')
+    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_parameterstudy.py")]
+    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_json_serializer.py")]
 
 try:
     import islpy
 except ImportError:
-    collect_ignore += [os.path.join(SCRIPT_FOLDER, "pystencils/integer_set_analysis.py")]
+    collect_ignore += [os.path.join(SCRIPT_FOLDER, "src/pystencils/integer_set_analysis.py")]
 
 try:
     import graphviz
 except ImportError:
-    collect_ignore += [os.path.join(SCRIPT_FOLDER, "pystencils/backends/dot.py")]
+    collect_ignore += [os.path.join(SCRIPT_FOLDER, "src/pystencils/backends/dot.py")]
     collect_ignore += [os.path.join(SCRIPT_FOLDER, "doc/notebooks/01_tutorial_getting_started.ipynb")]
 
 try:
     import pyevtk
 except ImportError:
-    collect_ignore += [os.path.join(SCRIPT_FOLDER, "pystencils/datahandling/vtk.py")]
+    collect_ignore += [os.path.join(SCRIPT_FOLDER, "src/pystencils/datahandling/vtk.py")]
 
 collect_ignore += [os.path.join(SCRIPT_FOLDER, 'setup.py')]
 
diff --git a/pyproject.toml b/pyproject.toml
new file mode 100644
index 0000000000000000000000000000000000000000..66d34842fbff613b0a13ca7033bcd81db70497c0
--- /dev/null
+++ b/pyproject.toml
@@ -0,0 +1,99 @@
+[project]
+name = "pystencils"
+description = "Speeding up stencil computations on CPUs and GPUs"
+dynamic = ["version"]
+readme = "README.md"
+authors = [
+    { name = "Martin Bauer" },
+    { name = "Jan Hönig " },
+    { name = "Markus Holzer" },
+    { name = "Frederik Hennig" },
+    { email = "cs10-codegen@fau.de" },
+]
+license = { file = "COPYING.txt" }
+requires-python = ">=3.10"
+dependencies = ["sympy>=1.6,<=1.11.1", "numpy>=1.8.0", "appdirs", "joblib", "pyyaml"]
+classifiers = [
+    "Development Status :: 4 - Beta",
+    "Framework :: Jupyter",
+    "Topic :: Software Development :: Code Generators",
+    "Topic :: Scientific/Engineering :: Physics",
+    "Intended Audience :: Developers",
+    "Intended Audience :: Science/Research",
+    "License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)",
+]
+
+[project.urls]
+"Bug Tracker" = "https://i10git.cs.fau.de/pycodegen/pystencils/-/issues"
+"Documentation" = "https://pycodegen.pages.i10git.cs.fau.de/pystencils/"
+"Source Code" = "https://i10git.cs.fau.de/pycodegen/pystencils"
+
+[project.optional-dependencies]
+gpu = ['cupy']
+alltrafos = ['islpy', 'py-cpuinfo']
+bench_db = ['blitzdb', 'pymongo', 'pandas']
+interactive = [
+    'matplotlib',
+    'ipy_table',
+    'imageio',
+    'jupyter',
+    'pyevtk',
+    'rich',
+    'graphviz',
+]
+use_cython = [
+    'Cython'
+]
+doc = [
+    'sphinx',
+    'sphinx_rtd_theme',
+    'nbsphinx',
+    'sphinxcontrib-bibtex',
+    'sphinx_autodoc_typehints',
+    'pandoc',
+]
+tests = [
+    'pytest',
+    'pytest-cov',
+    'pytest-html',
+    'ansi2html',
+    'pytest-xdist',
+    'flake8',
+    'nbformat',
+    'nbconvert',
+    'ipython',
+    'matplotlib',
+    'py-cpuinfo',
+    'randomgen>=1.18',
+]
+
+[build-system]
+requires = [
+    "setuptools>=61",
+    "versioneer>=0.29",
+    "tomli; python_version < '3.11'",
+    # 'Cython'
+]
+build-backend = "setuptools.build_meta"
+
+[tool.setuptools.package-data]
+pystencils = [
+    "include/*.h",
+    "boundaries/createindexlistcython.pyx"
+]
+
+[tool.setuptools.packages.find]
+where = ["src"]
+include = ["pystencils", "pystencils.*"]
+namespaces = false
+
+[tool.versioneer]
+# See the docstring in versioneer.py for instructions. Note that you must
+# re-run 'versioneer.py setup' after changing this section, and commit the
+# resulting files.
+VCS = "git"
+style = "pep440"
+versionfile_source = "src/pystencils/_version.py"
+versionfile_build = "pystencils/_version.py"
+tag_prefix = "release/"
+parentdir_prefix = "pystencils-"
diff --git a/pytest.ini b/pytest.ini
index 143e8aa345792eee9651c4568a6e1c3654de7b66..8c445bea68f8eda1ee9d80e452f4aa97599d30b0 100644
--- a/pytest.ini
+++ b/pytest.ini
@@ -1,4 +1,6 @@
 [pytest]
+testpaths = src tests doc/notebooks
+pythonpath = src
 python_files = test_*.py *_test.py scenario_*.py
 norecursedirs = *.egg-info .git .cache .ipynb_checkpoints htmlcov
 addopts = --doctest-modules --durations=20  --cov-config pytest.ini
@@ -17,20 +19,21 @@ filterwarnings =
 
 [run]
 branch = True
-source = pystencils
-         pystencils_tests
+source = src/pystencils
+         tests
 
 omit = doc/*
-       pystencils_tests/*
+       tests/*
        setup.py
+       quicktest.py
        conftest.py
        versioneer.py
-       pystencils/jupytersetup.py
-       pystencils/cpu/msvc_detection.py
-       pystencils/sympy_gmpy_bug_workaround.py
-       pystencils/cache.py
-       pystencils/pacxx/benchmark.py
-       pystencils/_version.py
+       src/pystencils/jupytersetup.py
+       src/pystencils/cpu/msvc_detection.py
+       src/pystencils/sympy_gmpy_bug_workaround.py
+       src/pystencils/cache.py
+       src/pystencils/pacxx/benchmark.py
+       src/pystencils/_version.py
        venv/
 
 [report]
diff --git a/quicktest.py b/quicktest.py
new file mode 100644
index 0000000000000000000000000000000000000000..804a70ce9becc7a455cff10a31a860961efb78a0
--- /dev/null
+++ b/quicktest.py
@@ -0,0 +1,22 @@
+#!/usr/bin/env python3
+
+from contextlib import redirect_stdout
+import io
+from tests.test_quicktests import (
+    test_basic_kernel,
+    test_basic_blocking_staggered,
+    test_basic_vectorization,
+)
+
+quick_tests = [
+    test_basic_kernel,
+    test_basic_blocking_staggered,
+    test_basic_vectorization,
+]
+
+if __name__ == "__main__":
+    print("Running pystencils quicktests")
+    for qt in quick_tests:
+        print(f"   -> {qt.__name__}")
+        with redirect_stdout(io.StringIO()):
+            qt()
diff --git a/setup.cfg b/setup.cfg
deleted file mode 100644
index 60288a36aaae0c5ae29abeb4257ef9045f96c944..0000000000000000000000000000000000000000
--- a/setup.cfg
+++ /dev/null
@@ -1,11 +0,0 @@
-# See the docstring in versioneer.py for instructions. Note that you must
-# re-run 'versioneer.py setup' after changing this section, and commit the
-# resulting files.
-
-[versioneer]
-VCS = git
-style = pep440
-versionfile_source = pystencils/_version.py
-versionfile_build = pystencils/_version.py
-tag_prefix = release/
-parentdir_prefix = pystencils-
diff --git a/setup.py b/setup.py
index fb6a5aeea28f360369e040e84b4d1bb5ef2a8993..13202a84fe9a1f31dde6dab5f6a515924573856f 100644
--- a/setup.py
+++ b/setup.py
@@ -1,136 +1,21 @@
-import distutils
-import io
-import os
-from contextlib import redirect_stdout
-from importlib import import_module
+from setuptools import setup, __version__ as setuptools_version
 
-import setuptools
+if int(setuptools_version.split('.')[0]) < 61:
+    raise Exception(
+        "[ERROR] pystencils requires at least setuptools version 61 to install.\n"
+        "If this error occurs during an installation via pip, it is likely that there is a conflict between "
+        "versions of setuptools installed by pip and the system package manager. "
+        "In this case, it is recommended to install pystencils into a virtual environment instead."
+    )
 
 import versioneer
 
-try:
-    import cython  # noqa
-
-    USE_CYTHON = True
-except ImportError:
-    USE_CYTHON = False
-
-quick_tests = [
-    'test_quicktests.test_basic_kernel',
-    'test_quicktests.test_basic_blocking_staggered',
-    'test_quicktests.test_basic_vectorization',
-]
-
-
-class SimpleTestRunner(distutils.cmd.Command):
-    """A custom command to run selected tests"""
-
-    description = 'run some quick tests'
-    user_options = []
-
-    @staticmethod
-    def _run_tests_in_module(test):
-        """Short test runner function - to work also if py.test is not installed."""
-        test = f'pystencils_tests.{test}'
-        mod, function_name = test.rsplit('.', 1)
-        if isinstance(mod, str):
-            mod = import_module(mod)
-
-        func = getattr(mod, function_name)
-        print(f"   -> {function_name} in {mod.__name__}")
-        with redirect_stdout(io.StringIO()):
-            func()
-
-    def initialize_options(self):
-        pass
-
-    def finalize_options(self):
-        pass
-
-    def run(self):
-        """Run command."""
-        for test in quick_tests:
-            self._run_tests_in_module(test)
-
-
-def readme():
-    with open('README.md') as f:
-        return f.read()
-
-
-def cython_extensions(*extensions):
-    from distutils.extension import Extension
-    if USE_CYTHON:
-        ext = '.pyx'
-        result = [Extension(e, [os.path.join(*e.split(".")) + ext]) for e in extensions]
-        from Cython.Build import cythonize
-        result = cythonize(result, language_level=3)
-        return result
-    elif all([os.path.exists(os.path.join(*e.split(".")) + '.c') for e in extensions]):
-        ext = '.c'
-        result = [Extension(e, [os.path.join(*e.split(".")) + ext]) for e in extensions]
-        return result
-    else:
-        return None
-
 
 def get_cmdclass():
-    cmdclass = {"quicktest": SimpleTestRunner}
-    cmdclass.update(versioneer.get_cmdclass())
-    return cmdclass
-
+    return versioneer.get_cmdclass()
 
-setuptools.setup(name='pystencils',
-                 description='Speeding up stencil computations on CPUs and GPUs',
-                 version=versioneer.get_version(),
-                 long_description=readme(),
-                 long_description_content_type="text/markdown",
-                 author='Martin Bauer, Jan Hönig, Markus Holzer',
-                 license='AGPLv3',
-                 author_email='cs10-codegen@fau.de',
-                 url='https://i10git.cs.fau.de/pycodegen/pystencils/',
-                 packages=['pystencils'] + ['pystencils.' + s for s in setuptools.find_packages('pystencils')],
-                 install_requires=['sympy>=1.6,<=1.11.1', 'numpy>=1.8.0', 'pymbolic>=2022.2', 'appdirs', 'joblib'],
-                 package_data={'pystencils': ['include/*.h',
-                                              'backends/cuda_known_functions.txt',
-                                              'backends/opencl1.1_known_functions.txt',
-                                              'boundaries/createindexlistcython.c',
-                                              'boundaries/createindexlistcython.pyx']},
-                 ext_modules=cython_extensions("pystencils.boundaries.createindexlistcython"),
-                 classifiers=[
-                     'Development Status :: 4 - Beta',
-                     'Framework :: Jupyter',
-                     'Topic :: Software Development :: Code Generators',
-                     'Topic :: Scientific/Engineering :: Physics',
-                     'Intended Audience :: Developers',
-                     'Intended Audience :: Science/Research',
-                     'License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)',
-                 ],
-                 project_urls={
-                     "Bug Tracker": "https://i10git.cs.fau.de/pycodegen/pystencils/-/issues",
-                     "Documentation": "https://pycodegen.pages.i10git.cs.fau.de/pystencils/",
-                     "Source Code": "https://i10git.cs.fau.de/pycodegen/pystencils",
-                 },
-                 extras_require={
-                     'gpu': ['cupy'],
-                     'alltrafos': ['islpy', 'py-cpuinfo'],
-                     'bench_db': ['blitzdb', 'pymongo', 'pandas'],
-                     'interactive': ['matplotlib', 'ipy_table', 'imageio', 'jupyter', 'pyevtk', 'rich', 'graphviz'],
-                     'doc': ['sphinx', 'sphinx_rtd_theme', 'nbsphinx',
-                             'sphinxcontrib-bibtex', 'sphinx_autodoc_typehints', 'pandoc'],
-                     'use_cython': ['Cython']
-                 },
-                 tests_require=['pytest',
-                                'pytest-cov',
-                                'pytest-html',
-                                'ansi2html',
-                                'pytest-xdist',
-                                'flake8',
-                                'nbformat',
-                                'nbconvert',
-                                'ipython',
-                                'randomgen>=1.18'],
 
-                 python_requires=">=3.10",
-                 cmdclass=get_cmdclass()
-                 )
+setup(
+    version=versioneer.get_version(),
+    cmdclass=get_cmdclass(),
+)
diff --git a/pystencils/__init__.py b/src/pystencils/__init__.py
similarity index 100%
rename from pystencils/__init__.py
rename to src/pystencils/__init__.py
diff --git a/pystencils/_version.py b/src/pystencils/_version.py
similarity index 100%
rename from pystencils/_version.py
rename to src/pystencils/_version.py
diff --git a/pystencils/alignedarray.py b/src/pystencils/alignedarray.py
similarity index 100%
rename from pystencils/alignedarray.py
rename to src/pystencils/alignedarray.py
diff --git a/pystencils/assignment.py b/src/pystencils/assignment.py
similarity index 100%
rename from pystencils/assignment.py
rename to src/pystencils/assignment.py
diff --git a/pystencils/astnodes.py b/src/pystencils/astnodes.py
similarity index 100%
rename from pystencils/astnodes.py
rename to src/pystencils/astnodes.py
diff --git a/pystencils/backends/__init__.py b/src/pystencils/backends/__init__.py
similarity index 100%
rename from pystencils/backends/__init__.py
rename to src/pystencils/backends/__init__.py
diff --git a/pystencils/backends/arm_instruction_sets.py b/src/pystencils/backends/arm_instruction_sets.py
similarity index 100%
rename from pystencils/backends/arm_instruction_sets.py
rename to src/pystencils/backends/arm_instruction_sets.py
diff --git a/pystencils/backends/cbackend.py b/src/pystencils/backends/cbackend.py
similarity index 100%
rename from pystencils/backends/cbackend.py
rename to src/pystencils/backends/cbackend.py
diff --git a/pystencils/backends/cuda_backend.py b/src/pystencils/backends/cuda_backend.py
similarity index 100%
rename from pystencils/backends/cuda_backend.py
rename to src/pystencils/backends/cuda_backend.py
diff --git a/pystencils/backends/dot.py b/src/pystencils/backends/dot.py
similarity index 100%
rename from pystencils/backends/dot.py
rename to src/pystencils/backends/dot.py
diff --git a/pystencils/backends/json.py b/src/pystencils/backends/json.py
similarity index 100%
rename from pystencils/backends/json.py
rename to src/pystencils/backends/json.py
diff --git a/pystencils/backends/ppc_instruction_sets.py b/src/pystencils/backends/ppc_instruction_sets.py
similarity index 100%
rename from pystencils/backends/ppc_instruction_sets.py
rename to src/pystencils/backends/ppc_instruction_sets.py
diff --git a/pystencils/backends/riscv_instruction_sets.py b/src/pystencils/backends/riscv_instruction_sets.py
similarity index 100%
rename from pystencils/backends/riscv_instruction_sets.py
rename to src/pystencils/backends/riscv_instruction_sets.py
diff --git a/pystencils/backends/simd_instruction_sets.py b/src/pystencils/backends/simd_instruction_sets.py
similarity index 100%
rename from pystencils/backends/simd_instruction_sets.py
rename to src/pystencils/backends/simd_instruction_sets.py
diff --git a/pystencils/backends/x86_instruction_sets.py b/src/pystencils/backends/x86_instruction_sets.py
similarity index 100%
rename from pystencils/backends/x86_instruction_sets.py
rename to src/pystencils/backends/x86_instruction_sets.py
diff --git a/pystencils/bit_masks.py b/src/pystencils/bit_masks.py
similarity index 100%
rename from pystencils/bit_masks.py
rename to src/pystencils/bit_masks.py
diff --git a/pystencils/boundaries/__init__.py b/src/pystencils/boundaries/__init__.py
similarity index 100%
rename from pystencils/boundaries/__init__.py
rename to src/pystencils/boundaries/__init__.py
diff --git a/pystencils/boundaries/boundaryconditions.py b/src/pystencils/boundaries/boundaryconditions.py
similarity index 100%
rename from pystencils/boundaries/boundaryconditions.py
rename to src/pystencils/boundaries/boundaryconditions.py
diff --git a/pystencils/boundaries/boundaryhandling.py b/src/pystencils/boundaries/boundaryhandling.py
similarity index 100%
rename from pystencils/boundaries/boundaryhandling.py
rename to src/pystencils/boundaries/boundaryhandling.py
diff --git a/pystencils/boundaries/createindexlist.py b/src/pystencils/boundaries/createindexlist.py
similarity index 59%
rename from pystencils/boundaries/createindexlist.py
rename to src/pystencils/boundaries/createindexlist.py
index 8619a31d6646ea7b5ce97500f0478388c0e2bcca..462d3f329263aa1d84e4e7b76897a4cf16b858f7 100644
--- a/pystencils/boundaries/createindexlist.py
+++ b/src/pystencils/boundaries/createindexlist.py
@@ -2,26 +2,22 @@ import warnings
 
 import numpy as np
 
+
 try:
-    # Try to import right away - assume compiled code is available
-    # compile with: python setup.py build_ext --inplace --use-cython
-    from pystencils.boundaries.createindexlistcython import create_boundary_neighbor_index_list_2d, \
-        create_boundary_neighbor_index_list_3d, create_boundary_cell_index_list_2d, create_boundary_cell_index_list_3d
+    import pyximport
 
+    pyximport.install(language_level=3)
     cython_funcs_available = True
 except ImportError:
-    try:
-        # If not, try development mode and import via pyximport
-        import pyximport
-
-        pyximport.install(language_level=3)
-        cython_funcs_available = True
-    except ImportError:
-        cython_funcs_available = False
-    if cython_funcs_available:
-        from pystencils.boundaries.createindexlistcython import create_boundary_neighbor_index_list_2d, \
-            create_boundary_neighbor_index_list_3d, create_boundary_cell_index_list_2d, \
-            create_boundary_cell_index_list_3d
+    cython_funcs_available = False
+
+if cython_funcs_available:
+    from pystencils.boundaries.createindexlistcython import (
+        create_boundary_neighbor_index_list_2d,
+        create_boundary_neighbor_index_list_3d,
+        create_boundary_cell_index_list_2d,
+        create_boundary_cell_index_list_3d,
+    )
 
 boundary_index_array_coordinate_names = ["x", "y", "z"]
 direction_member_name = "dir"
@@ -30,40 +26,59 @@ default_index_array_dtype = np.int32
 
 def numpy_data_type_for_boundary_object(boundary_object, dim):
     coordinate_names = boundary_index_array_coordinate_names[:dim]
-    return np.dtype([(name, default_index_array_dtype) for name in coordinate_names]
-                    + [(direction_member_name, default_index_array_dtype)]
-                    + [(i[0], i[1].numpy_dtype) for i in boundary_object.additional_data], align=True)
-
-
-def _create_index_list_python(flag_field_arr, boundary_mask,
-                              fluid_mask, stencil, single_link, inner_or_boundary=False, nr_of_ghost_layers=None):
-
+    return np.dtype(
+        [(name, default_index_array_dtype) for name in coordinate_names]
+        + [(direction_member_name, default_index_array_dtype)]
+        + [(i[0], i[1].numpy_dtype) for i in boundary_object.additional_data],
+        align=True,
+    )
+
+
+def _create_index_list_python(
+    flag_field_arr,
+    boundary_mask,
+    fluid_mask,
+    stencil,
+    single_link,
+    inner_or_boundary=False,
+    nr_of_ghost_layers=None,
+):
     if inner_or_boundary and nr_of_ghost_layers is None:
-        raise ValueError("If inner_or_boundary is set True the number of ghost layers "
-                         "around the inner domain has to be specified")
+        raise ValueError(
+            "If inner_or_boundary is set True the number of ghost layers "
+            "around the inner domain has to be specified"
+        )
 
     if nr_of_ghost_layers is None:
         nr_of_ghost_layers = 0
 
-    coordinate_names = boundary_index_array_coordinate_names[:len(flag_field_arr.shape)]
-    index_arr_dtype = np.dtype([(name, default_index_array_dtype) for name in coordinate_names]
-                               + [(direction_member_name, default_index_array_dtype)])
+    coordinate_names = boundary_index_array_coordinate_names[
+        : len(flag_field_arr.shape)
+    ]
+    index_arr_dtype = np.dtype(
+        [(name, default_index_array_dtype) for name in coordinate_names]
+        + [(direction_member_name, default_index_array_dtype)]
+    )
 
     # boundary cells are extracted via np.where. To ensure continous memory access in the compute kernel these cells
     # have to be sorted.
     boundary_cells = np.transpose(np.nonzero(flag_field_arr == boundary_mask))
     for i in range(len(flag_field_arr.shape)):
-        boundary_cells = boundary_cells[boundary_cells[:, i].argsort(kind='mergesort')]
+        boundary_cells = boundary_cells[boundary_cells[:, i].argsort(kind="mergesort")]
 
     # First a set is created to save all fluid cells which are near boundary
     fluid_cells = set()
     for cell in boundary_cells:
         cell = tuple(cell)
         for dir_idx, direction in enumerate(stencil):
-            neighbor_cell = tuple([cell_i + dir_i for cell_i, dir_i in zip(cell, direction)])
+            neighbor_cell = tuple(
+                [cell_i + dir_i for cell_i, dir_i in zip(cell, direction)]
+            )
             # prevent out ouf bounds access. If boundary cell is at the border, some stencil directions would be out.
-            if any(not 0 + nr_of_ghost_layers <= e < upper - nr_of_ghost_layers
-                   for e, upper in zip(neighbor_cell, flag_field_arr.shape)):
+            if any(
+                not 0 + nr_of_ghost_layers <= e < upper - nr_of_ghost_layers
+                for e, upper in zip(neighbor_cell, flag_field_arr.shape)
+            ):
                 continue
             if flag_field_arr[neighbor_cell] & fluid_mask:
                 fluid_cells.add(neighbor_cell)
@@ -83,9 +98,14 @@ def _create_index_list_python(flag_field_arr, boundary_mask,
         cell = tuple(cell)
         sum_cells = np.zeros(len(cell))
         for dir_idx, direction in enumerate(stencil):
-            neighbor_cell = tuple([cell_i + dir_i for cell_i, dir_i in zip(cell, direction)])
+            neighbor_cell = tuple(
+                [cell_i + dir_i for cell_i, dir_i in zip(cell, direction)]
+            )
             # prevent out ouf bounds access. If boundary cell is at the border, some stencil directions would be out.
-            if any(not 0 <= e < upper for e, upper in zip(neighbor_cell, flag_field_arr.shape)):
+            if any(
+                not 0 <= e < upper
+                for e, upper in zip(neighbor_cell, flag_field_arr.shape)
+            ):
                 continue
             if flag_field_arr[neighbor_cell] & checkmask:
                 if single_link:
@@ -101,8 +121,15 @@ def _create_index_list_python(flag_field_arr, boundary_mask,
     return np.array(result, dtype=index_arr_dtype)
 
 
-def create_boundary_index_list(flag_field, stencil, boundary_mask, fluid_mask,
-                               nr_of_ghost_layers=1, inner_or_boundary=True, single_link=False):
+def create_boundary_index_list(
+    flag_field,
+    stencil,
+    boundary_mask,
+    fluid_mask,
+    nr_of_ghost_layers=1,
+    inner_or_boundary=True,
+    single_link=False,
+):
     """Creates a numpy array storing links (connections) between domain cells and boundary cells.
 
     Args:
@@ -119,11 +146,20 @@ def create_boundary_index_list(flag_field, stencil, boundary_mask, fluid_mask,
     """
     dim = len(flag_field.shape)
     coordinate_names = boundary_index_array_coordinate_names[:dim]
-    index_arr_dtype = np.dtype([(name, default_index_array_dtype) for name in coordinate_names]
-                               + [(direction_member_name, default_index_array_dtype)])
+    index_arr_dtype = np.dtype(
+        [(name, default_index_array_dtype) for name in coordinate_names]
+        + [(direction_member_name, default_index_array_dtype)]
+    )
 
     stencil = np.array(stencil, dtype=default_index_array_dtype)
-    args = (flag_field, nr_of_ghost_layers, boundary_mask, fluid_mask, stencil, single_link)
+    args = (
+        flag_field,
+        nr_of_ghost_layers,
+        boundary_mask,
+        fluid_mask,
+        stencil,
+        single_link,
+    )
     args_no_gl = (flag_field, boundary_mask, fluid_mask, stencil, single_link)
 
     if cython_funcs_available:
@@ -142,22 +178,42 @@ def create_boundary_index_list(flag_field, stencil, boundary_mask, fluid_mask,
         return np.array(idx_list, dtype=index_arr_dtype)
     else:
         if flag_field.size > 1e6:
-            warnings.warn("Boundary setup may take very long! Consider installing cython to speed it up")
-        return _create_index_list_python(*args_no_gl, inner_or_boundary=inner_or_boundary,
-                                         nr_of_ghost_layers=nr_of_ghost_layers)
-
-
-def create_boundary_index_array(flag_field, stencil, boundary_mask, fluid_mask, boundary_object,
-                                nr_of_ghost_layers=1, inner_or_boundary=True, single_link=False):
-    idx_array = create_boundary_index_list(flag_field, stencil, boundary_mask, fluid_mask,
-                                           nr_of_ghost_layers, inner_or_boundary, single_link)
+            warnings.warn(
+                "Boundary setup may take very long! Consider installing cython to speed it up"
+            )
+        return _create_index_list_python(
+            *args_no_gl,
+            inner_or_boundary=inner_or_boundary,
+            nr_of_ghost_layers=nr_of_ghost_layers,
+        )
+
+
+def create_boundary_index_array(
+    flag_field,
+    stencil,
+    boundary_mask,
+    fluid_mask,
+    boundary_object,
+    nr_of_ghost_layers=1,
+    inner_or_boundary=True,
+    single_link=False,
+):
+    idx_array = create_boundary_index_list(
+        flag_field,
+        stencil,
+        boundary_mask,
+        fluid_mask,
+        nr_of_ghost_layers,
+        inner_or_boundary,
+        single_link,
+    )
     dim = len(flag_field.shape)
 
     if boundary_object.additional_data:
         coordinate_names = boundary_index_array_coordinate_names[:dim]
         index_arr_dtype = numpy_data_type_for_boundary_object(boundary_object, dim)
         extended_idx_field = np.empty(len(idx_array), dtype=index_arr_dtype)
-        for prop in coordinate_names + ['dir']:
+        for prop in coordinate_names + ["dir"]:
             extended_idx_field[prop] = idx_array[prop]
 
         idx_array = extended_idx_field
diff --git a/pystencils/boundaries/createindexlistcython.pyx b/src/pystencils/boundaries/createindexlistcython.pyx
similarity index 97%
rename from pystencils/boundaries/createindexlistcython.pyx
rename to src/pystencils/boundaries/createindexlistcython.pyx
index bd30fc1bafc91d007c5a3a41ff6e6adefafd1eed..36f57431b88c7041cfd47acc9ed84709b0dddd37 100644
--- a/pystencils/boundaries/createindexlistcython.pyx
+++ b/src/pystencils/boundaries/createindexlistcython.pyx
@@ -1,7 +1,4 @@
-# distutils: language=c
-# Workaround for cython bug
-# see https://stackoverflow.com/questions/8024805/cython-compiled-c-extension-importerror-dynamic-module-does-not-define-init-fu
-WORKAROUND = "Something"
+# cython: language_level=3str
 
 import cython
 
diff --git a/pystencils/boundaries/inkernel.py b/src/pystencils/boundaries/inkernel.py
similarity index 100%
rename from pystencils/boundaries/inkernel.py
rename to src/pystencils/boundaries/inkernel.py
diff --git a/pystencils/cache.py b/src/pystencils/cache.py
similarity index 100%
rename from pystencils/cache.py
rename to src/pystencils/cache.py
diff --git a/pystencils/config.py b/src/pystencils/config.py
similarity index 100%
rename from pystencils/config.py
rename to src/pystencils/config.py
diff --git a/pystencils/cpu/__init__.py b/src/pystencils/cpu/__init__.py
similarity index 100%
rename from pystencils/cpu/__init__.py
rename to src/pystencils/cpu/__init__.py
diff --git a/pystencils/cpu/cpujit.py b/src/pystencils/cpu/cpujit.py
similarity index 100%
rename from pystencils/cpu/cpujit.py
rename to src/pystencils/cpu/cpujit.py
diff --git a/pystencils/cpu/kernelcreation.py b/src/pystencils/cpu/kernelcreation.py
similarity index 100%
rename from pystencils/cpu/kernelcreation.py
rename to src/pystencils/cpu/kernelcreation.py
diff --git a/pystencils/cpu/msvc_detection.py b/src/pystencils/cpu/msvc_detection.py
similarity index 100%
rename from pystencils/cpu/msvc_detection.py
rename to src/pystencils/cpu/msvc_detection.py
diff --git a/pystencils/cpu/vectorization.py b/src/pystencils/cpu/vectorization.py
similarity index 100%
rename from pystencils/cpu/vectorization.py
rename to src/pystencils/cpu/vectorization.py
diff --git a/pystencils/datahandling/__init__.py b/src/pystencils/datahandling/__init__.py
similarity index 100%
rename from pystencils/datahandling/__init__.py
rename to src/pystencils/datahandling/__init__.py
diff --git a/pystencils/datahandling/blockiteration.py b/src/pystencils/datahandling/blockiteration.py
similarity index 100%
rename from pystencils/datahandling/blockiteration.py
rename to src/pystencils/datahandling/blockiteration.py
diff --git a/pystencils/datahandling/datahandling_interface.py b/src/pystencils/datahandling/datahandling_interface.py
similarity index 100%
rename from pystencils/datahandling/datahandling_interface.py
rename to src/pystencils/datahandling/datahandling_interface.py
diff --git a/pystencils/datahandling/parallel_datahandling.py b/src/pystencils/datahandling/parallel_datahandling.py
similarity index 100%
rename from pystencils/datahandling/parallel_datahandling.py
rename to src/pystencils/datahandling/parallel_datahandling.py
diff --git a/pystencils/datahandling/serial_datahandling.py b/src/pystencils/datahandling/serial_datahandling.py
similarity index 100%
rename from pystencils/datahandling/serial_datahandling.py
rename to src/pystencils/datahandling/serial_datahandling.py
diff --git a/pystencils/datahandling/vtk.py b/src/pystencils/datahandling/vtk.py
similarity index 100%
rename from pystencils/datahandling/vtk.py
rename to src/pystencils/datahandling/vtk.py
diff --git a/pystencils/display_utils.py b/src/pystencils/display_utils.py
similarity index 100%
rename from pystencils/display_utils.py
rename to src/pystencils/display_utils.py
diff --git a/pystencils/enums.py b/src/pystencils/enums.py
similarity index 100%
rename from pystencils/enums.py
rename to src/pystencils/enums.py
diff --git a/pystencils/fast_approximation.py b/src/pystencils/fast_approximation.py
similarity index 100%
rename from pystencils/fast_approximation.py
rename to src/pystencils/fast_approximation.py
diff --git a/pystencils/fd/__init__.py b/src/pystencils/fd/__init__.py
similarity index 100%
rename from pystencils/fd/__init__.py
rename to src/pystencils/fd/__init__.py
diff --git a/pystencils/fd/derivation.py b/src/pystencils/fd/derivation.py
similarity index 100%
rename from pystencils/fd/derivation.py
rename to src/pystencils/fd/derivation.py
diff --git a/pystencils/fd/derivative.py b/src/pystencils/fd/derivative.py
similarity index 100%
rename from pystencils/fd/derivative.py
rename to src/pystencils/fd/derivative.py
diff --git a/pystencils/fd/finitedifferences.py b/src/pystencils/fd/finitedifferences.py
similarity index 100%
rename from pystencils/fd/finitedifferences.py
rename to src/pystencils/fd/finitedifferences.py
diff --git a/pystencils/fd/finitevolumes.py b/src/pystencils/fd/finitevolumes.py
similarity index 100%
rename from pystencils/fd/finitevolumes.py
rename to src/pystencils/fd/finitevolumes.py
diff --git a/pystencils/fd/spatial.py b/src/pystencils/fd/spatial.py
similarity index 100%
rename from pystencils/fd/spatial.py
rename to src/pystencils/fd/spatial.py
diff --git a/pystencils/field.py b/src/pystencils/field.py
similarity index 100%
rename from pystencils/field.py
rename to src/pystencils/field.py
diff --git a/pystencils/functions.py b/src/pystencils/functions.py
similarity index 100%
rename from pystencils/functions.py
rename to src/pystencils/functions.py
diff --git a/pystencils/gpu/__init__.py b/src/pystencils/gpu/__init__.py
similarity index 100%
rename from pystencils/gpu/__init__.py
rename to src/pystencils/gpu/__init__.py
diff --git a/pystencils/gpu/gpu_array_handler.py b/src/pystencils/gpu/gpu_array_handler.py
similarity index 100%
rename from pystencils/gpu/gpu_array_handler.py
rename to src/pystencils/gpu/gpu_array_handler.py
diff --git a/pystencils/gpu/gpujit.py b/src/pystencils/gpu/gpujit.py
similarity index 100%
rename from pystencils/gpu/gpujit.py
rename to src/pystencils/gpu/gpujit.py
diff --git a/pystencils/gpu/indexing.py b/src/pystencils/gpu/indexing.py
similarity index 100%
rename from pystencils/gpu/indexing.py
rename to src/pystencils/gpu/indexing.py
diff --git a/pystencils/gpu/kernelcreation.py b/src/pystencils/gpu/kernelcreation.py
similarity index 100%
rename from pystencils/gpu/kernelcreation.py
rename to src/pystencils/gpu/kernelcreation.py
diff --git a/pystencils/gpu/periodicity.py b/src/pystencils/gpu/periodicity.py
similarity index 100%
rename from pystencils/gpu/periodicity.py
rename to src/pystencils/gpu/periodicity.py
diff --git a/pystencils/include/PyStencilsField.h b/src/pystencils/include/PyStencilsField.h
similarity index 100%
rename from pystencils/include/PyStencilsField.h
rename to src/pystencils/include/PyStencilsField.h
diff --git a/pystencils/include/__init__.py b/src/pystencils/include/__init__.py
similarity index 100%
rename from pystencils/include/__init__.py
rename to src/pystencils/include/__init__.py
diff --git a/pystencils/include/aesni_rand.h b/src/pystencils/include/aesni_rand.h
similarity index 100%
rename from pystencils/include/aesni_rand.h
rename to src/pystencils/include/aesni_rand.h
diff --git a/pystencils/include/arm_neon_helpers.h b/src/pystencils/include/arm_neon_helpers.h
similarity index 100%
rename from pystencils/include/arm_neon_helpers.h
rename to src/pystencils/include/arm_neon_helpers.h
diff --git a/pystencils/include/gpu_defines.h b/src/pystencils/include/gpu_defines.h
similarity index 100%
rename from pystencils/include/gpu_defines.h
rename to src/pystencils/include/gpu_defines.h
diff --git a/pystencils/include/half_precision.h b/src/pystencils/include/half_precision.h
similarity index 100%
rename from pystencils/include/half_precision.h
rename to src/pystencils/include/half_precision.h
diff --git a/pystencils/include/myintrin.h b/src/pystencils/include/myintrin.h
similarity index 100%
rename from pystencils/include/myintrin.h
rename to src/pystencils/include/myintrin.h
diff --git a/pystencils/include/philox_rand.h b/src/pystencils/include/philox_rand.h
similarity index 100%
rename from pystencils/include/philox_rand.h
rename to src/pystencils/include/philox_rand.h
diff --git a/pystencils/include/ppc_altivec_helpers.h b/src/pystencils/include/ppc_altivec_helpers.h
similarity index 100%
rename from pystencils/include/ppc_altivec_helpers.h
rename to src/pystencils/include/ppc_altivec_helpers.h
diff --git a/pystencils/integer_functions.py b/src/pystencils/integer_functions.py
similarity index 100%
rename from pystencils/integer_functions.py
rename to src/pystencils/integer_functions.py
diff --git a/pystencils/integer_set_analysis.py b/src/pystencils/integer_set_analysis.py
similarity index 100%
rename from pystencils/integer_set_analysis.py
rename to src/pystencils/integer_set_analysis.py
diff --git a/pystencils/jupyter.py b/src/pystencils/jupyter.py
similarity index 100%
rename from pystencils/jupyter.py
rename to src/pystencils/jupyter.py
diff --git a/pystencils/kernel_contrains_check.py b/src/pystencils/kernel_contrains_check.py
similarity index 100%
rename from pystencils/kernel_contrains_check.py
rename to src/pystencils/kernel_contrains_check.py
diff --git a/pystencils/kernel_decorator.py b/src/pystencils/kernel_decorator.py
similarity index 100%
rename from pystencils/kernel_decorator.py
rename to src/pystencils/kernel_decorator.py
diff --git a/pystencils/kernel_wrapper.py b/src/pystencils/kernel_wrapper.py
similarity index 100%
rename from pystencils/kernel_wrapper.py
rename to src/pystencils/kernel_wrapper.py
diff --git a/pystencils/kernelcreation.py b/src/pystencils/kernelcreation.py
similarity index 100%
rename from pystencils/kernelcreation.py
rename to src/pystencils/kernelcreation.py
diff --git a/pystencils/nbackend/__init__.py b/src/pystencils/nbackend/__init__.py
similarity index 100%
rename from pystencils/nbackend/__init__.py
rename to src/pystencils/nbackend/__init__.py
diff --git a/pystencils/nbackend/arrays.py b/src/pystencils/nbackend/arrays.py
similarity index 100%
rename from pystencils/nbackend/arrays.py
rename to src/pystencils/nbackend/arrays.py
diff --git a/pystencils/nbackend/ast/__init__.py b/src/pystencils/nbackend/ast/__init__.py
similarity index 100%
rename from pystencils/nbackend/ast/__init__.py
rename to src/pystencils/nbackend/ast/__init__.py
diff --git a/pystencils/nbackend/ast/analysis.py b/src/pystencils/nbackend/ast/analysis.py
similarity index 100%
rename from pystencils/nbackend/ast/analysis.py
rename to src/pystencils/nbackend/ast/analysis.py
diff --git a/pystencils/nbackend/ast/constraints.py b/src/pystencils/nbackend/ast/constraints.py
similarity index 100%
rename from pystencils/nbackend/ast/constraints.py
rename to src/pystencils/nbackend/ast/constraints.py
diff --git a/pystencils/nbackend/ast/dispatcher.py b/src/pystencils/nbackend/ast/dispatcher.py
similarity index 100%
rename from pystencils/nbackend/ast/dispatcher.py
rename to src/pystencils/nbackend/ast/dispatcher.py
diff --git a/pystencils/nbackend/ast/kernelfunction.py b/src/pystencils/nbackend/ast/kernelfunction.py
similarity index 100%
rename from pystencils/nbackend/ast/kernelfunction.py
rename to src/pystencils/nbackend/ast/kernelfunction.py
diff --git a/pystencils/nbackend/ast/nodes.py b/src/pystencils/nbackend/ast/nodes.py
similarity index 100%
rename from pystencils/nbackend/ast/nodes.py
rename to src/pystencils/nbackend/ast/nodes.py
diff --git a/pystencils/nbackend/ast/transformations.py b/src/pystencils/nbackend/ast/transformations.py
similarity index 100%
rename from pystencils/nbackend/ast/transformations.py
rename to src/pystencils/nbackend/ast/transformations.py
diff --git a/pystencils/nbackend/ast/util.py b/src/pystencils/nbackend/ast/util.py
similarity index 100%
rename from pystencils/nbackend/ast/util.py
rename to src/pystencils/nbackend/ast/util.py
diff --git a/pystencils/nbackend/emission.py b/src/pystencils/nbackend/emission.py
similarity index 100%
rename from pystencils/nbackend/emission.py
rename to src/pystencils/nbackend/emission.py
diff --git a/pystencils/nbackend/exceptions.py b/src/pystencils/nbackend/exceptions.py
similarity index 100%
rename from pystencils/nbackend/exceptions.py
rename to src/pystencils/nbackend/exceptions.py
diff --git a/pystencils/nbackend/jit/cpu_extension_module.py b/src/pystencils/nbackend/jit/cpu_extension_module.py
similarity index 100%
rename from pystencils/nbackend/jit/cpu_extension_module.py
rename to src/pystencils/nbackend/jit/cpu_extension_module.py
diff --git a/pystencils/nbackend/sympy_mapper.py b/src/pystencils/nbackend/sympy_mapper.py
similarity index 100%
rename from pystencils/nbackend/sympy_mapper.py
rename to src/pystencils/nbackend/sympy_mapper.py
diff --git a/pystencils/nbackend/typed_expressions.py b/src/pystencils/nbackend/typed_expressions.py
similarity index 100%
rename from pystencils/nbackend/typed_expressions.py
rename to src/pystencils/nbackend/typed_expressions.py
diff --git a/pystencils/nbackend/types/__init__.py b/src/pystencils/nbackend/types/__init__.py
similarity index 100%
rename from pystencils/nbackend/types/__init__.py
rename to src/pystencils/nbackend/types/__init__.py
diff --git a/pystencils/nbackend/types/basic_types.py b/src/pystencils/nbackend/types/basic_types.py
similarity index 100%
rename from pystencils/nbackend/types/basic_types.py
rename to src/pystencils/nbackend/types/basic_types.py
diff --git a/pystencils/nbackend/types/exception.py b/src/pystencils/nbackend/types/exception.py
similarity index 100%
rename from pystencils/nbackend/types/exception.py
rename to src/pystencils/nbackend/types/exception.py
diff --git a/pystencils/nbackend/types/parsing.py b/src/pystencils/nbackend/types/parsing.py
similarity index 100%
rename from pystencils/nbackend/types/parsing.py
rename to src/pystencils/nbackend/types/parsing.py
diff --git a/pystencils/nbackend/types/quick.py b/src/pystencils/nbackend/types/quick.py
similarity index 100%
rename from pystencils/nbackend/types/quick.py
rename to src/pystencils/nbackend/types/quick.py
diff --git a/pystencils/node_collection.py b/src/pystencils/node_collection.py
similarity index 100%
rename from pystencils/node_collection.py
rename to src/pystencils/node_collection.py
diff --git a/pystencils/placeholder_function.py b/src/pystencils/placeholder_function.py
similarity index 100%
rename from pystencils/placeholder_function.py
rename to src/pystencils/placeholder_function.py
diff --git a/pystencils/plot.py b/src/pystencils/plot.py
similarity index 100%
rename from pystencils/plot.py
rename to src/pystencils/plot.py
diff --git a/pystencils/rng.py b/src/pystencils/rng.py
similarity index 100%
rename from pystencils/rng.py
rename to src/pystencils/rng.py
diff --git a/pystencils/runhelper/__init__.py b/src/pystencils/runhelper/__init__.py
similarity index 100%
rename from pystencils/runhelper/__init__.py
rename to src/pystencils/runhelper/__init__.py
diff --git a/pystencils/runhelper/db.py b/src/pystencils/runhelper/db.py
similarity index 100%
rename from pystencils/runhelper/db.py
rename to src/pystencils/runhelper/db.py
diff --git a/pystencils/runhelper/parameterstudy.py b/src/pystencils/runhelper/parameterstudy.py
similarity index 100%
rename from pystencils/runhelper/parameterstudy.py
rename to src/pystencils/runhelper/parameterstudy.py
diff --git a/pystencils/session.py b/src/pystencils/session.py
similarity index 100%
rename from pystencils/session.py
rename to src/pystencils/session.py
diff --git a/pystencils/simp/__init__.py b/src/pystencils/simp/__init__.py
similarity index 100%
rename from pystencils/simp/__init__.py
rename to src/pystencils/simp/__init__.py
diff --git a/pystencils/simp/assignment_collection.py b/src/pystencils/simp/assignment_collection.py
similarity index 100%
rename from pystencils/simp/assignment_collection.py
rename to src/pystencils/simp/assignment_collection.py
diff --git a/pystencils/simp/simplifications.py b/src/pystencils/simp/simplifications.py
similarity index 100%
rename from pystencils/simp/simplifications.py
rename to src/pystencils/simp/simplifications.py
diff --git a/pystencils/simp/simplificationstrategy.py b/src/pystencils/simp/simplificationstrategy.py
similarity index 100%
rename from pystencils/simp/simplificationstrategy.py
rename to src/pystencils/simp/simplificationstrategy.py
diff --git a/pystencils/simp/subexpression_insertion.py b/src/pystencils/simp/subexpression_insertion.py
similarity index 100%
rename from pystencils/simp/subexpression_insertion.py
rename to src/pystencils/simp/subexpression_insertion.py
diff --git a/pystencils/simplificationfactory.py b/src/pystencils/simplificationfactory.py
similarity index 100%
rename from pystencils/simplificationfactory.py
rename to src/pystencils/simplificationfactory.py
diff --git a/pystencils/slicing.py b/src/pystencils/slicing.py
similarity index 100%
rename from pystencils/slicing.py
rename to src/pystencils/slicing.py
diff --git a/pystencils/spatial_coordinates.py b/src/pystencils/spatial_coordinates.py
similarity index 100%
rename from pystencils/spatial_coordinates.py
rename to src/pystencils/spatial_coordinates.py
diff --git a/pystencils/stencil.py b/src/pystencils/stencil.py
similarity index 100%
rename from pystencils/stencil.py
rename to src/pystencils/stencil.py
diff --git a/pystencils/sympyextensions.py b/src/pystencils/sympyextensions.py
similarity index 100%
rename from pystencils/sympyextensions.py
rename to src/pystencils/sympyextensions.py
diff --git a/pystencils/timeloop.py b/src/pystencils/timeloop.py
similarity index 100%
rename from pystencils/timeloop.py
rename to src/pystencils/timeloop.py
diff --git a/pystencils/transformations.py b/src/pystencils/transformations.py
similarity index 100%
rename from pystencils/transformations.py
rename to src/pystencils/transformations.py
diff --git a/pystencils/typing/__init__.py b/src/pystencils/typing/__init__.py
similarity index 100%
rename from pystencils/typing/__init__.py
rename to src/pystencils/typing/__init__.py
diff --git a/pystencils/typing/cast_functions.py b/src/pystencils/typing/cast_functions.py
similarity index 100%
rename from pystencils/typing/cast_functions.py
rename to src/pystencils/typing/cast_functions.py
diff --git a/pystencils/typing/leaf_typing.py b/src/pystencils/typing/leaf_typing.py
similarity index 100%
rename from pystencils/typing/leaf_typing.py
rename to src/pystencils/typing/leaf_typing.py
diff --git a/pystencils/typing/transformations.py b/src/pystencils/typing/transformations.py
similarity index 100%
rename from pystencils/typing/transformations.py
rename to src/pystencils/typing/transformations.py
diff --git a/pystencils/typing/typed_sympy.py b/src/pystencils/typing/typed_sympy.py
similarity index 100%
rename from pystencils/typing/typed_sympy.py
rename to src/pystencils/typing/typed_sympy.py
diff --git a/pystencils/typing/types.py b/src/pystencils/typing/types.py
similarity index 100%
rename from pystencils/typing/types.py
rename to src/pystencils/typing/types.py
diff --git a/pystencils/typing/utilities.py b/src/pystencils/typing/utilities.py
similarity index 100%
rename from pystencils/typing/utilities.py
rename to src/pystencils/typing/utilities.py
diff --git a/pystencils/utils.py b/src/pystencils/utils.py
similarity index 100%
rename from pystencils/utils.py
rename to src/pystencils/utils.py
diff --git a/pystencils_tests/__init__.py b/tests/__init__.py
similarity index 100%
rename from pystencils_tests/__init__.py
rename to tests/__init__.py
diff --git a/pystencils_tests/nbackend/test_basic_printing.py b/tests/nbackend/test_basic_printing.py
similarity index 100%
rename from pystencils_tests/nbackend/test_basic_printing.py
rename to tests/nbackend/test_basic_printing.py
diff --git a/pystencils_tests/nbackend/test_constant_folding.py b/tests/nbackend/test_constant_folding.py
similarity index 100%
rename from pystencils_tests/nbackend/test_constant_folding.py
rename to tests/nbackend/test_constant_folding.py
diff --git a/pystencils_tests/nbackend/types/test_constants.py b/tests/nbackend/types/test_constants.py
similarity index 100%
rename from pystencils_tests/nbackend/types/test_constants.py
rename to tests/nbackend/types/test_constants.py
diff --git a/pystencils_tests/nbackend/types/test_quick_types.py b/tests/nbackend/types/test_quick_types.py
similarity index 100%
rename from pystencils_tests/nbackend/types/test_quick_types.py
rename to tests/nbackend/types/test_quick_types.py
diff --git a/pystencils_tests/test_Min_Max.py b/tests/test_Min_Max.py
similarity index 100%
rename from pystencils_tests/test_Min_Max.py
rename to tests/test_Min_Max.py
diff --git a/pystencils_tests/test_abs.py b/tests/test_abs.py
similarity index 100%
rename from pystencils_tests/test_abs.py
rename to tests/test_abs.py
diff --git a/pystencils_tests/test_address_of.py b/tests/test_address_of.py
similarity index 100%
rename from pystencils_tests/test_address_of.py
rename to tests/test_address_of.py
diff --git a/pystencils_tests/test_aligned_array.py b/tests/test_aligned_array.py
similarity index 100%
rename from pystencils_tests/test_aligned_array.py
rename to tests/test_aligned_array.py
diff --git a/pystencils_tests/test_assignment_collection.py b/tests/test_assignment_collection.py
similarity index 100%
rename from pystencils_tests/test_assignment_collection.py
rename to tests/test_assignment_collection.py
diff --git a/pystencils_tests/test_assignment_collection_dict_conversion.py b/tests/test_assignment_collection_dict_conversion.py
similarity index 100%
rename from pystencils_tests/test_assignment_collection_dict_conversion.py
rename to tests/test_assignment_collection_dict_conversion.py
diff --git a/pystencils_tests/test_assignment_from_stencil.py b/tests/test_assignment_from_stencil.py
similarity index 100%
rename from pystencils_tests/test_assignment_from_stencil.py
rename to tests/test_assignment_from_stencil.py
diff --git a/pystencils_tests/test_astnodes.py b/tests/test_astnodes.py
similarity index 100%
rename from pystencils_tests/test_astnodes.py
rename to tests/test_astnodes.py
diff --git a/pystencils_tests/test_augmented_assignment.py b/tests/test_augmented_assignment.py
similarity index 100%
rename from pystencils_tests/test_augmented_assignment.py
rename to tests/test_augmented_assignment.py
diff --git a/pystencils_tests/test_base_pointer_specification.py b/tests/test_base_pointer_specification.py
similarity index 100%
rename from pystencils_tests/test_base_pointer_specification.py
rename to tests/test_base_pointer_specification.py
diff --git a/pystencils_tests/test_bit_masks.py b/tests/test_bit_masks.py
similarity index 100%
rename from pystencils_tests/test_bit_masks.py
rename to tests/test_bit_masks.py
diff --git a/pystencils_tests/test_blocking.py b/tests/test_blocking.py
similarity index 100%
rename from pystencils_tests/test_blocking.py
rename to tests/test_blocking.py
diff --git a/pystencils_tests/test_blocking_staggered.py b/tests/test_blocking_staggered.py
similarity index 100%
rename from pystencils_tests/test_blocking_staggered.py
rename to tests/test_blocking_staggered.py
diff --git a/pystencils_tests/test_boundary.py b/tests/test_boundary.py
similarity index 100%
rename from pystencils_tests/test_boundary.py
rename to tests/test_boundary.py
diff --git a/pystencils_tests/test_boundary_indexlist_creation.py b/tests/test_boundary_indexlist_creation.py
similarity index 100%
rename from pystencils_tests/test_boundary_indexlist_creation.py
rename to tests/test_boundary_indexlist_creation.py
diff --git a/pystencils_tests/test_buffer.py b/tests/test_buffer.py
similarity index 100%
rename from pystencils_tests/test_buffer.py
rename to tests/test_buffer.py
diff --git a/pystencils_tests/test_buffer_gpu.py b/tests/test_buffer_gpu.py
similarity index 100%
rename from pystencils_tests/test_buffer_gpu.py
rename to tests/test_buffer_gpu.py
diff --git a/pystencils_tests/test_conditional_field_access.py b/tests/test_conditional_field_access.py
similarity index 100%
rename from pystencils_tests/test_conditional_field_access.py
rename to tests/test_conditional_field_access.py
diff --git a/pystencils_tests/test_conditional_vec.py b/tests/test_conditional_vec.py
similarity index 100%
rename from pystencils_tests/test_conditional_vec.py
rename to tests/test_conditional_vec.py
diff --git a/pystencils_tests/test_config.py b/tests/test_config.py
similarity index 100%
rename from pystencils_tests/test_config.py
rename to tests/test_config.py
diff --git a/pystencils_tests/test_create_kernel_config.py b/tests/test_create_kernel_config.py
similarity index 100%
rename from pystencils_tests/test_create_kernel_config.py
rename to tests/test_create_kernel_config.py
diff --git a/pystencils_tests/test_custom_backends.py b/tests/test_custom_backends.py
similarity index 100%
rename from pystencils_tests/test_custom_backends.py
rename to tests/test_custom_backends.py
diff --git a/pystencils_tests/test_data/datahandling_load_test.npz b/tests/test_data/datahandling_load_test.npz
similarity index 100%
rename from pystencils_tests/test_data/datahandling_load_test.npz
rename to tests/test_data/datahandling_load_test.npz
diff --git a/pystencils_tests/test_data/datahandling_parallel_load_test/dst.dat b/tests/test_data/datahandling_parallel_load_test/dst.dat
similarity index 100%
rename from pystencils_tests/test_data/datahandling_parallel_load_test/dst.dat
rename to tests/test_data/datahandling_parallel_load_test/dst.dat
diff --git a/pystencils_tests/test_data/datahandling_parallel_load_test/src.dat b/tests/test_data/datahandling_parallel_load_test/src.dat
similarity index 100%
rename from pystencils_tests/test_data/datahandling_parallel_load_test/src.dat
rename to tests/test_data/datahandling_parallel_load_test/src.dat
diff --git a/pystencils_tests/test_data/datahandling_parallel_save_test/dst.dat b/tests/test_data/datahandling_parallel_save_test/dst.dat
similarity index 100%
rename from pystencils_tests/test_data/datahandling_parallel_save_test/dst.dat
rename to tests/test_data/datahandling_parallel_save_test/dst.dat
diff --git a/pystencils_tests/test_data/datahandling_parallel_save_test/src.dat b/tests/test_data/datahandling_parallel_save_test/src.dat
similarity index 100%
rename from pystencils_tests/test_data/datahandling_parallel_save_test/src.dat
rename to tests/test_data/datahandling_parallel_save_test/src.dat
diff --git a/pystencils_tests/test_data/datahandling_save_test.npz b/tests/test_data/datahandling_save_test.npz
similarity index 100%
rename from pystencils_tests/test_data/datahandling_save_test.npz
rename to tests/test_data/datahandling_save_test.npz
diff --git a/pystencils_tests/test_data/lenna.png b/tests/test_data/lenna.png
similarity index 100%
rename from pystencils_tests/test_data/lenna.png
rename to tests/test_data/lenna.png
diff --git a/pystencils_tests/test_data/test_vessel2d_mask.png b/tests/test_data/test_vessel2d_mask.png
similarity index 100%
rename from pystencils_tests/test_data/test_vessel2d_mask.png
rename to tests/test_data/test_vessel2d_mask.png
diff --git a/pystencils_tests/test_datahandling.py b/tests/test_datahandling.py
similarity index 100%
rename from pystencils_tests/test_datahandling.py
rename to tests/test_datahandling.py
diff --git a/pystencils_tests/test_datahandling_parallel.py b/tests/test_datahandling_parallel.py
similarity index 99%
rename from pystencils_tests/test_datahandling_parallel.py
rename to tests/test_datahandling_parallel.py
index b5aa9832470b8e19d712f73697ab3af4549eaf7e..f572cf3269a3d9db90ca90bcf6413485f6fa2f2e 100644
--- a/pystencils_tests/test_datahandling_parallel.py
+++ b/tests/test_datahandling_parallel.py
@@ -11,7 +11,7 @@ from pystencils.slicing import slice_from_direction
 
 from pystencils.datahandling.parallel_datahandling import ParallelDataHandling
 from pystencils.datahandling import create_data_handling
-from pystencils_tests.test_datahandling import (
+from tests.test_datahandling import (
     access_and_gather, kernel_execution_jacobi, reduction, synchronization, vtk_output)
 
 SCRIPT_FOLDER = Path(__file__).parent.absolute()
diff --git a/pystencils_tests/test_derivative.py b/tests/test_derivative.py
similarity index 100%
rename from pystencils_tests/test_derivative.py
rename to tests/test_derivative.py
diff --git a/pystencils_tests/test_dot_printer.ipynb b/tests/test_dot_printer.ipynb
similarity index 100%
rename from pystencils_tests/test_dot_printer.ipynb
rename to tests/test_dot_printer.ipynb
diff --git a/pystencils_tests/test_dot_printer.py b/tests/test_dot_printer.py
similarity index 100%
rename from pystencils_tests/test_dot_printer.py
rename to tests/test_dot_printer.py
diff --git a/pystencils_tests/test_dtype_check.py b/tests/test_dtype_check.py
similarity index 100%
rename from pystencils_tests/test_dtype_check.py
rename to tests/test_dtype_check.py
diff --git a/pystencils_tests/test_fast_approximation.py b/tests/test_fast_approximation.py
similarity index 100%
rename from pystencils_tests/test_fast_approximation.py
rename to tests/test_fast_approximation.py
diff --git a/pystencils_tests/test_fd_derivation.ipynb b/tests/test_fd_derivation.ipynb
similarity index 100%
rename from pystencils_tests/test_fd_derivation.ipynb
rename to tests/test_fd_derivation.ipynb
diff --git a/pystencils_tests/test_fd_derivation_via_rotation.ipynb b/tests/test_fd_derivation_via_rotation.ipynb
similarity index 100%
rename from pystencils_tests/test_fd_derivation_via_rotation.ipynb
rename to tests/test_fd_derivation_via_rotation.ipynb
diff --git a/pystencils_tests/test_fd_derivative.py b/tests/test_fd_derivative.py
similarity index 100%
rename from pystencils_tests/test_fd_derivative.py
rename to tests/test_fd_derivative.py
diff --git a/pystencils_tests/test_field.py b/tests/test_field.py
similarity index 100%
rename from pystencils_tests/test_field.py
rename to tests/test_field.py
diff --git a/pystencils_tests/test_field_access_poly.py b/tests/test_field_access_poly.py
similarity index 100%
rename from pystencils_tests/test_field_access_poly.py
rename to tests/test_field_access_poly.py
diff --git a/pystencils_tests/test_field_equality.ipynb b/tests/test_field_equality.ipynb
similarity index 100%
rename from pystencils_tests/test_field_equality.ipynb
rename to tests/test_field_equality.ipynb
diff --git a/pystencils_tests/test_finite_differences.py b/tests/test_finite_differences.py
similarity index 100%
rename from pystencils_tests/test_finite_differences.py
rename to tests/test_finite_differences.py
diff --git a/pystencils_tests/test_floor_ceil_int_optimization.py b/tests/test_floor_ceil_int_optimization.py
similarity index 100%
rename from pystencils_tests/test_floor_ceil_int_optimization.py
rename to tests/test_floor_ceil_int_optimization.py
diff --git a/pystencils_tests/test_fvm.py b/tests/test_fvm.py
similarity index 100%
rename from pystencils_tests/test_fvm.py
rename to tests/test_fvm.py
diff --git a/pystencils_tests/test_global_definitions.py b/tests/test_global_definitions.py
similarity index 100%
rename from pystencils_tests/test_global_definitions.py
rename to tests/test_global_definitions.py
diff --git a/pystencils_tests/test_gpu.py b/tests/test_gpu.py
similarity index 100%
rename from pystencils_tests/test_gpu.py
rename to tests/test_gpu.py
diff --git a/pystencils_tests/test_half_precision.py b/tests/test_half_precision.py
similarity index 100%
rename from pystencils_tests/test_half_precision.py
rename to tests/test_half_precision.py
diff --git a/pystencils_tests/test_helpful_errors.py b/tests/test_helpful_errors.py
similarity index 100%
rename from pystencils_tests/test_helpful_errors.py
rename to tests/test_helpful_errors.py
diff --git a/pystencils_tests/test_indexed_kernels.py b/tests/test_indexed_kernels.py
similarity index 100%
rename from pystencils_tests/test_indexed_kernels.py
rename to tests/test_indexed_kernels.py
diff --git a/pystencils_tests/test_jacobi_cbackend.py b/tests/test_jacobi_cbackend.py
similarity index 100%
rename from pystencils_tests/test_jacobi_cbackend.py
rename to tests/test_jacobi_cbackend.py
diff --git a/pystencils_tests/test_json_backend.py b/tests/test_json_backend.py
similarity index 100%
rename from pystencils_tests/test_json_backend.py
rename to tests/test_json_backend.py
diff --git a/pystencils_tests/test_json_serializer.py b/tests/test_json_serializer.py
similarity index 100%
rename from pystencils_tests/test_json_serializer.py
rename to tests/test_json_serializer.py
diff --git a/pystencils_tests/test_jupyter_extensions.ipynb b/tests/test_jupyter_extensions.ipynb
similarity index 100%
rename from pystencils_tests/test_jupyter_extensions.ipynb
rename to tests/test_jupyter_extensions.ipynb
diff --git a/pystencils_tests/test_logarithm.py b/tests/test_logarithm.py
similarity index 100%
rename from pystencils_tests/test_logarithm.py
rename to tests/test_logarithm.py
diff --git a/pystencils_tests/test_loop_cutting.py b/tests/test_loop_cutting.py
similarity index 100%
rename from pystencils_tests/test_loop_cutting.py
rename to tests/test_loop_cutting.py
diff --git a/pystencils_tests/test_match_subs_for_assignment_collection.py b/tests/test_match_subs_for_assignment_collection.py
similarity index 100%
rename from pystencils_tests/test_match_subs_for_assignment_collection.py
rename to tests/test_match_subs_for_assignment_collection.py
diff --git a/pystencils_tests/test_math_functions.py b/tests/test_math_functions.py
similarity index 100%
rename from pystencils_tests/test_math_functions.py
rename to tests/test_math_functions.py
diff --git a/pystencils_tests/test_modulo.py b/tests/test_modulo.py
similarity index 100%
rename from pystencils_tests/test_modulo.py
rename to tests/test_modulo.py
diff --git a/pystencils_tests/test_move_constant_before_loop.py b/tests/test_move_constant_before_loop.py
similarity index 100%
rename from pystencils_tests/test_move_constant_before_loop.py
rename to tests/test_move_constant_before_loop.py
diff --git a/pystencils_tests/test_nodecollection.py b/tests/test_nodecollection.py
similarity index 100%
rename from pystencils_tests/test_nodecollection.py
rename to tests/test_nodecollection.py
diff --git a/pystencils_tests/test_parameterstudy.py b/tests/test_parameterstudy.py
similarity index 100%
rename from pystencils_tests/test_parameterstudy.py
rename to tests/test_parameterstudy.py
diff --git a/pystencils_tests/test_phasefield_dentritic_3D.ipynb b/tests/test_phasefield_dentritic_3D.ipynb
similarity index 100%
rename from pystencils_tests/test_phasefield_dentritic_3D.ipynb
rename to tests/test_phasefield_dentritic_3D.ipynb
diff --git a/pystencils_tests/test_pickle_support.py b/tests/test_pickle_support.py
similarity index 100%
rename from pystencils_tests/test_pickle_support.py
rename to tests/test_pickle_support.py
diff --git a/pystencils_tests/test_plot.py b/tests/test_plot.py
similarity index 100%
rename from pystencils_tests/test_plot.py
rename to tests/test_plot.py
diff --git a/pystencils_tests/test_printing.py b/tests/test_printing.py
similarity index 100%
rename from pystencils_tests/test_printing.py
rename to tests/test_printing.py
diff --git a/pystencils_tests/test_quicktests.py b/tests/test_quicktests.py
similarity index 100%
rename from pystencils_tests/test_quicktests.py
rename to tests/test_quicktests.py
diff --git a/pystencils_tests/test_random.py b/tests/test_random.py
similarity index 100%
rename from pystencils_tests/test_random.py
rename to tests/test_random.py
diff --git a/pystencils_tests/test_sharedmethodcache.py b/tests/test_sharedmethodcache.py
similarity index 100%
rename from pystencils_tests/test_sharedmethodcache.py
rename to tests/test_sharedmethodcache.py
diff --git a/pystencils_tests/test_simplification_strategy.py b/tests/test_simplification_strategy.py
similarity index 100%
rename from pystencils_tests/test_simplification_strategy.py
rename to tests/test_simplification_strategy.py
diff --git a/pystencils_tests/test_simplifications.py b/tests/test_simplifications.py
similarity index 100%
rename from pystencils_tests/test_simplifications.py
rename to tests/test_simplifications.py
diff --git a/pystencils_tests/test_size_and_layout_checks.py b/tests/test_size_and_layout_checks.py
similarity index 100%
rename from pystencils_tests/test_size_and_layout_checks.py
rename to tests/test_size_and_layout_checks.py
diff --git a/pystencils_tests/test_sliced_iteration.py b/tests/test_sliced_iteration.py
similarity index 100%
rename from pystencils_tests/test_sliced_iteration.py
rename to tests/test_sliced_iteration.py
diff --git a/pystencils_tests/test_slicing.py b/tests/test_slicing.py
similarity index 100%
rename from pystencils_tests/test_slicing.py
rename to tests/test_slicing.py
diff --git a/pystencils_tests/test_small_block_benchmark.ipynb b/tests/test_small_block_benchmark.ipynb
similarity index 100%
rename from pystencils_tests/test_small_block_benchmark.ipynb
rename to tests/test_small_block_benchmark.ipynb
diff --git a/pystencils_tests/test_source_code_comment.py b/tests/test_source_code_comment.py
similarity index 100%
rename from pystencils_tests/test_source_code_comment.py
rename to tests/test_source_code_comment.py
diff --git a/pystencils_tests/test_staggered_kernel.py b/tests/test_staggered_kernel.py
similarity index 100%
rename from pystencils_tests/test_staggered_kernel.py
rename to tests/test_staggered_kernel.py
diff --git a/pystencils_tests/test_stencil_plot.ipynb b/tests/test_stencil_plot.ipynb
similarity index 100%
rename from pystencils_tests/test_stencil_plot.ipynb
rename to tests/test_stencil_plot.ipynb
diff --git a/pystencils_tests/test_stencils.py b/tests/test_stencils.py
similarity index 100%
rename from pystencils_tests/test_stencils.py
rename to tests/test_stencils.py
diff --git a/pystencils_tests/test_struct_types.py b/tests/test_struct_types.py
similarity index 100%
rename from pystencils_tests/test_struct_types.py
rename to tests/test_struct_types.py
diff --git a/pystencils_tests/test_subexpression_insertion.py b/tests/test_subexpression_insertion.py
similarity index 100%
rename from pystencils_tests/test_subexpression_insertion.py
rename to tests/test_subexpression_insertion.py
diff --git a/pystencils_tests/test_sum_prod.py b/tests/test_sum_prod.py
similarity index 100%
rename from pystencils_tests/test_sum_prod.py
rename to tests/test_sum_prod.py
diff --git a/pystencils_tests/test_sympyextensions.py b/tests/test_sympyextensions.py
similarity index 100%
rename from pystencils_tests/test_sympyextensions.py
rename to tests/test_sympyextensions.py
diff --git a/pystencils_tests/test_timeloop.py b/tests/test_timeloop.py
similarity index 100%
rename from pystencils_tests/test_timeloop.py
rename to tests/test_timeloop.py
diff --git a/pystencils_tests/test_transformations.py b/tests/test_transformations.py
similarity index 100%
rename from pystencils_tests/test_transformations.py
rename to tests/test_transformations.py
diff --git a/pystencils_tests/test_type_interference.py b/tests/test_type_interference.py
similarity index 100%
rename from pystencils_tests/test_type_interference.py
rename to tests/test_type_interference.py
diff --git a/pystencils_tests/test_types.py b/tests/test_types.py
similarity index 100%
rename from pystencils_tests/test_types.py
rename to tests/test_types.py
diff --git a/pystencils_tests/test_utils.py b/tests/test_utils.py
similarity index 100%
rename from pystencils_tests/test_utils.py
rename to tests/test_utils.py
diff --git a/pystencils_tests/test_vectorization.py b/tests/test_vectorization.py
similarity index 100%
rename from pystencils_tests/test_vectorization.py
rename to tests/test_vectorization.py
diff --git a/pystencils_tests/test_vectorization_specific.py b/tests/test_vectorization_specific.py
similarity index 100%
rename from pystencils_tests/test_vectorization_specific.py
rename to tests/test_vectorization_specific.py
diff --git a/pystencils_tests/test_version_string.py b/tests/test_version_string.py
similarity index 100%
rename from pystencils_tests/test_version_string.py
rename to tests/test_version_string.py