diff --git a/python/waLBerla/__init__.py b/python/waLBerla/__init__.py index e9527a2660a6eac5de353fc416537bcae1e972b7..db838d8351dccaa400c450f1bf35d7d3daef60da 100644 --- a/python/waLBerla/__init__.py +++ b/python/waLBerla/__init__.py @@ -5,12 +5,12 @@ from .callbacks import memberCallback as member_callback # noqa:F401 import sys try: - from .walberla_cpp import field, cuda, geometry, lbm, postprocessing, timeloop, mpi + from .walberla_cpp import * # noqa: F403 cpp_available = True except ImportError: try: - from walberla_cpp import field, cuda, geometry, lbm, postprocessing, timeloop, mpi + from walberla_cpp import * # noqa: F403 cpp_available = True except ImportError: @@ -38,29 +38,29 @@ if cpp_available: if 'field' in globals(): # check if field was exported # Update modules dict to be able to write e.g. from waLBerla import field # otherwise "field" would only be a scope not a module - sys.modules[__name__ + '.field'] = field + sys.modules[__name__ + '.field'] = field # noqa: F405 # extend the C++ module with some python functions from .field_extension import extend as extend_field - extend_field(field) + extend_field(field) # noqa: F405 if 'cuda' in globals(): - sys.modules[__name__ + '.cuda'] = cuda + sys.modules[__name__ + '.cuda'] = cuda # noqa: F405 from .cuda_extension import extend as extend_cuda - extend_cuda(cuda) + extend_cuda(cuda) # noqa: F405 if 'geometry' in globals(): - sys.modules[__name__ + '.geometry'] = geometry + sys.modules[__name__ + '.geometry'] = geometry # noqa: F405 if 'lbm' in globals(): - sys.modules[__name__ + '.lbm'] = lbm + sys.modules[__name__ + '.lbm'] = lbm # noqa: F405 if 'postprocessing' in globals(): - sys.modules[__name__ + 'postprocessing'] = postprocessing + sys.modules[__name__ + 'postprocessing'] = postprocessing # noqa: F405 if 'mpi' in globals(): - sys.modules[__name__ + '.mpi'] = mpi + sys.modules[__name__ + '.mpi'] = mpi # noqa: F405 if 'timeloop' in globals(): - sys.modules[__name__ + '.timeloop'] = timeloop + sys.modules[__name__ + '.timeloop'] = timeloop # noqa: F405 from .timeloop_extension import extend as extend_timeloop - extend_timeloop(timeloop) + extend_timeloop(timeloop) # noqa: F405 else: class Dummy: pass