Merge branch 'devel' into mpi

这个提交包含在:
Nathan Mannall
2025-06-17 12:15:46 +01:00
当前提交 df8a6bd956
共有 36 个文件被更改,包括 143 次插入94 次删除

查看文件

@@ -7,6 +7,8 @@ version: 2
build:
os: ubuntu-22.04
apt_packages:
- mpich
tools:
python: "mambaforge-22.9"
jobs:

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This is the official list of entities and people who have contributed to gprMax
#
@@ -15,6 +16,5 @@ gprMax is a contribution to COST Action TU1208 'Civil Engineering Applications o
As well as the aforementioned authors, the following individuals have contributed to gprMax:
Oystein Bjorndal
John Hartley
Rajath Kumar
Tobias Schruff

查看文件

@@ -17,7 +17,7 @@ dependencies:
- pip:
- humanize
# - mpi4py
- mpi4py
- numpy-stl
# - pycuda
# - pyopencl

查看文件

@@ -78,104 +78,103 @@ Creating a model scene
Domain
------
.. autoclass:: gprMax.Domain
:members: __init__
.. autoclass:: gprMax.user_objects.cmds_singleuse.Domain
Discretisation
--------------
.. autoclass:: gprMax.Discretisation
.. autoclass:: gprMax.user_objects.cmds_singleuse.Discretisation
Time Window
-----------
.. autoclass:: gprMax.TimeWindow
.. autoclass:: gprMax.user_objects.cmds_singleuse.TimeWindow
General functions
=================
Title
-----
.. autoclass:: gprMax.Title
.. autoclass:: gprMax.user_objects.cmds_singleuse.Title
Number of OpenMP threads
------------------------
.. autoclass:: gprMax.OMPThreads
.. autoclass:: gprMax.user_objects.cmds_singleuse.OMPThreads
Time Step Stability Factor
--------------------------
.. autoclass:: gprMax.TimeStepStabilityFactor
.. autoclass:: gprMax.user_objects.cmds_singleuse.TimeStepStabilityFactor
Output Directory
----------------
.. autoclass:: gprMax.OutputDir
.. autoclass:: gprMax.user_objects.cmds_singleuse.OutputDir
Material functions
==================
Material
--------
.. autoclass:: gprMax.Material
.. autoclass:: gprMax.user_objects.cmds_multiuse.Material
Debye Dispersion
----------------
.. autoclass:: gprMax.AddDebyeDispersion
.. autoclass:: gprMax.user_objects.cmds_multiuse.AddDebyeDispersion
Lorentz Dispersion
------------------
.. autoclass:: gprMax.AddLorentzDispersion
.. autoclass:: gprMax.user_objects.cmds_multiuse.AddLorentzDispersion
Drude Dispersion
----------------
.. autoclass:: gprMax.AddDrudeDispersion
.. autoclass:: gprMax.user_objects.cmds_multiuse.AddDrudeDispersion
Soil Peplinski
--------------
.. autoclass:: gprMax.SoilPeplinski
.. autoclass:: gprMax.user_objects.cmds_multiuse.SoilPeplinski
Object construction functions
=============================
Object construction commands are processed in the order they appear in the scene. Therefore space in the model allocated to a specific material using for example the :class:`gprMax.cmds_geometry.box.Box` command can be reallocated to another material using the same or any other object construction command. Space in the model can be regarded as a canvas in which objects are introduced and one can be overlaid on top of the other overwriting its properties in order to produce the desired geometry. The object construction commands can therefore be used to create complex shapes and configurations.
Object construction commands are processed in the order they appear in the scene. Therefore space in the model allocated to a specific material using for example the :class:`gprMax.user_objects.cmds_geometry.box.Box` command can be reallocated to another material using the same or any other object construction command. Space in the model can be regarded as a canvas in which objects are introduced and one can be overlaid on top of the other overwriting its properties in order to produce the desired geometry. The object construction commands can therefore be used to create complex shapes and configurations.
Box
---
.. autoclass:: gprMax.Box
.. autoclass:: gprMax.user_objects.cmds_geometry.box.Box
Cone
----
.. autoclass:: gprMax.Cone
.. autoclass:: gprMax.user_objects.cmds_geometry.cone.Cone
Cylinder
--------
.. autoclass:: gprMax.Cylinder
.. autoclass:: gprMax.user_objects.cmds_geometry.cylinder.Cylinder
Cylindrical Sector
------------------
.. autoclass:: gprMax.CylindricalSector
.. autoclass:: gprMax.user_objects.cmds_geometry.cylindrical_sector.CylindricalSector
Edge
----
.. autoclass:: gprMax.Edge
.. autoclass:: gprMax.user_objects.cmds_geometry.edge.Edge
Ellipsoid
---------
.. autoclass:: gprMax.Ellipsoid
.. autoclass:: gprMax.user_objects.cmds_geometry.ellipsoid.Ellipsoid
Plate
-----
.. autoclass:: gprMax.Plate
.. autoclass:: gprMax.user_objects.cmds_geometry.plate.Plate
Sphere
------
.. autoclass:: gprMax.Sphere
.. autoclass:: gprMax.user_objects.cmds_geometry.sphere.Sphere
Triangle
--------
.. autoclass:: gprMax.Triangle
.. autoclass:: gprMax.user_objects.cmds_geometry.triangle.Triangle
Fractal Box
-----------
.. autoclass:: gprMax.FractalBox
.. autoclass:: gprMax.user_objects.cmds_geometry.fractal_box.FractalBox
.. note::
@@ -183,74 +182,74 @@ Fractal Box
Add Grass
---------
.. autoclass:: gprMax.AddGrass
.. autoclass:: gprMax.user_objects.cmds_geometry.add_grass.AddGrass
Add Surface Roughness
---------------------
.. autoclass:: gprMax.AddSurfaceRoughness
.. autoclass:: gprMax.user_objects.cmds_geometry.add_surface_roughness.AddSurfaceRoughness
Add Surface Water
-----------------
.. autoclass:: gprMax.AddSurfaceWater
.. autoclass:: gprMax.user_objects.cmds_geometry.add_surface_water.AddSurfaceWater
Geometry View
-------------
.. autoclass:: gprMax.GeometryView
.. autoclass:: gprMax.user_objects.cmds_multiuse.GeometryView
Geometry Objects Write
----------------------
.. autoclass:: gprMax.GeometryObjectsWrite
.. autoclass:: gprMax.user_objects.cmds_multiuse.GeometryObjectsWrite
Source and output functions
===========================
Waveform
--------
.. autoclass:: gprMax.Waveform
.. autoclass:: gprMax.user_objects.cmds_multiuse.Waveform
Voltage Source
--------------
.. autoclass:: gprMax.VoltageSource
.. autoclass:: gprMax.user_objects.cmds_multiuse.VoltageSource
Hertzian Dipole Source
----------------------
.. autoclass:: gprMax.HertzianDipole
.. autoclass:: gprMax.user_objects.cmds_multiuse.HertzianDipole
Magnetic Dipole Source
----------------------
.. autoclass:: gprMax.MagneticDipole
.. autoclass:: gprMax.user_objects.cmds_multiuse.MagneticDipole
Transmission Line
-----------------
.. autoclass:: gprMax.TransmissionLine
.. autoclass:: gprMax.user_objects.cmds_multiuse.TransmissionLine
Discrete Plane Wave
-------------------
.. autoclass:: gprMax.DiscretePlaneWave
.. autoclass:: gprMax.user_objects.cmds_multiuse.DiscretePlaneWave
Excitation File
---------------
.. autoclass:: gprMax.ExcitationFile
.. autoclass:: gprMax.user_objects.cmds_multiuse.ExcitationFile
Receiver
--------
.. autoclass:: gprMax.Rx
.. autoclass:: gprMax.user_objects.cmds_multiuse.Rx
Receiver Array
--------------
.. autoclass:: gprMax.RxArray
.. autoclass:: gprMax.user_objects.cmds_multiuse.RxArray
Source Steps
------------
.. autoclass:: gprMax.SrcSteps
.. autoclass:: gprMax.user_objects.cmds_singleuse.SrcSteps
Receiver Steps
--------------
.. autoclass:: gprMax.RxSteps
.. autoclass:: gprMax.user_objects.cmds_singleuse.RxSteps
Snapshot
--------
.. autoclass:: gprMax.Snapshot
.. autoclass:: gprMax.user_objects.cmds_multiuse.Snapshot
Subgrid
-------
@@ -266,13 +265,13 @@ The default behaviour for the absorbing boundary conditions (ABC) is first order
PML properties
--------------
.. autoclass:: gprMax.PMLProps
.. autoclass:: gprMax.user_objects.cmds_singleuse.PMLProps
PML CFS
-------
Allows you control of the specific parameters that are used to build each order of the PML. Up to a second order PML can currently be specified, i.e. by using two ``PMLCFS`` commands.
.. autoclass:: gprMax.PMLCFS
.. autoclass:: gprMax.user_objects.cmds_multiuse.PMLCFS
The CFS values (which are internally specified) used for the default standard first order PML are:
* ``alphascalingprofile = 'constant'``

查看文件

@@ -1,6 +1,6 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley, and
# Adittya Pal
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Adittya Pal, and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -408,20 +408,20 @@ def process_multicmds(multicmds):
poles = int(tmp[0])
material_ids = tmp[(3 * poles) + 1 : len(tmp)]
er_delta = []
tau = []
alpha = []
omega = []
delta = []
for pole in range(1, 3 * poles, 3):
er_delta.append(float(tmp[pole]))
tau.append(float(tmp[pole + 1]))
alpha.append(float(tmp[pole + 2]))
omega.append(float(tmp[pole + 1]))
delta.append(float(tmp[pole + 2]))
lorentz_dispersion = AddLorentzDispersion(
poles=poles,
material_ids=material_ids,
er_delta=er_delta,
tau=tau,
alpha=alpha,
omega=omega,
delta=delta,
)
scene_objects.append(lorentz_dispersion)
@@ -443,15 +443,15 @@ def process_multicmds(multicmds):
poles = int(tmp[0])
material_ids = tmp[(3 * poles) + 1 : len(tmp)]
tau = []
alpha = []
omega = []
gamma = []
for pole in range(1, 2 * poles, 2):
tau.append(float(tmp[pole]))
alpha.append(float(tmp[pole + 1]))
omega.append(float(tmp[pole]))
gamma.append(float(tmp[pole + 1]))
drude_dispersion = AddDrudeDispersion(
poles=poles, material_ids=material_ids, tau=tau, alpha=alpha
poles=poles, material_ids=material_ids, omega=omega, gamma=gamma
)
scene_objects.append(drude_dispersion)

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Tobias Schruff
# Authors: Craig Warren, Antonis Giannopoulos, Tobias Schruff,
# John Hartley, and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2024: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2024: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2024: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2024: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2024: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
@@ -1449,7 +1449,7 @@ class AddLorentzDispersion(GridUserObject):
f"{self.grid_name(grid)}Lorentz disperion added to {disp_material.ID} "
f"with delta_eps_r={', '.join(f'{deltaer:4.2f}' for deltaer in disp_material.deltaer)}, "
f"omega={', '.join(f'{omega:4.3e}' for omega in disp_material.tau)} secs, "
f"and gamma={', '.join(f'{delta:4.3e}' for delta in disp_material.alpha)} created."
f"and delta={', '.join(f'{delta:4.3e}' for delta in disp_material.alpha)} created."
)
@@ -1530,7 +1530,7 @@ class AddDrudeDispersion(GridUserObject):
logger.info(
f"{self.grid_name(grid)}Drude disperion added to {disp_material.ID} "
f"with omega={', '.join(f'{omega:4.3e}' for omega in disp_material.tau)} secs, "
f"and gamma={', '.join(f'{alpha:4.3e}' for alpha in disp_material.alpha)} secs created."
f"and alpha={', '.join(f'{alpha:4.3e}' for alpha in disp_material.alpha)} secs created."
)

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,5 +1,5 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.

查看文件

@@ -1,3 +1,22 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#
# gprMax is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# gprMax is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with gprMax. If not, see <http://www.gnu.org/licenses/>.
import os
from pathlib import Path

查看文件

@@ -1,3 +1,22 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#
# gprMax is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# gprMax is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with gprMax. If not, see <http://www.gnu.org/licenses/>.
site_configuration = {
"general": [
{

查看文件

@@ -8,7 +8,7 @@ humanize
jinja2
jupyter
matplotlib
# mpi4py
mpi4py
mpi4py-fft
numpy<2
numpy-stl

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#

查看文件

@@ -1,5 +1,6 @@
# Copyright (C) 2015-2025: The University of Edinburgh, United Kingdom
# Authors: Craig Warren, Antonis Giannopoulos, and John Hartley
# Authors: Craig Warren, Antonis Giannopoulos, John Hartley,
# and Nathan Mannall
#
# This file is part of gprMax.
#