diff --git a/.github/workflows/doc-test.yml b/.github/workflows/doc-test.yml
new file mode 100644
index 00000000..43b96865
--- /dev/null
+++ b/.github/workflows/doc-test.yml
@@ -0,0 +1,13 @@
+name: "Pull Request Docs Check"
+on:
+- pull_request
+
+jobs:
+ docs:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v1
+ - uses: ammaraskar/sphinx-action@dev
+ with:
+ docs-folder: "docs/"
+ build-command: "sphinx-build -b html . _build"
diff --git a/.github/workflows/python-package.yml b/.github/workflows/python-package.yml
index df0729e4..ac015f3e 100644
--- a/.github/workflows/python-package.yml
+++ b/.github/workflows/python-package.yml
@@ -13,9 +13,10 @@ jobs:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
+ max-parallel: 3
matrix:
- python-version: ["3.8", "3.9", "3.10", "3.11"]
- package-name: ["geos_ats_package", "geosx_mesh_doctor", "geosx_mesh_tools_package", "geosx_xml_tools_package", "hdf5_wrapper_package", "pygeosx_tools_package", "timehistory_package"]
+ python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
+ package-name: ["geos-ats", "geos-mesh", "geos-timehistory", "geos-xml-tools", "hdf5-wrapper", "pygeos-tools"]
steps:
- uses: actions/checkout@v3
@@ -24,16 +25,17 @@ jobs:
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
+ cache: 'pip'
- name: Install package
- working-directory: ./${{ matrix.package-name }}
+ # working-directory: ./${{ matrix.package-name }}
run: |
python -m pip install --upgrade pip
python -m pip install pytest yapf toml
- python -m pip install .
+ python -m pip install ${{ matrix.package-name }}/
- name: Lint with yapf
- working-directory: ./${{ matrix.package-name }}
+ # working-directory: ./${{ matrix.package-name }}
run: |
- yapf -r --diff . --style ../.style.yapf
+ yapf -r --diff ${{ matrix.package-name }} --style .style.yapf
# - name: Test with pytest
# working-directory: ./${{ matrix.package-name }}
# run: |
diff --git a/.gitignore b/.gitignore
index 6bde2b4f..a47b528f 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,16 +1,165 @@
+#MACOS
+DS_Store
+
+# Byte-compiled / optimized / DLL files
+__pycache__/
+*.py[cod]
+*$py.class
+
+# C extensions
+*.so
+
+# Distribution / packaging
+.Python
+build/
+develop-eggs/
+dist/
+downloads/
+eggs/
+.eggs/
+lib/
+lib64/
+parts/
+sdist/
+var/
+wheels/
+share/python-wheels/
*.egg-info/
+.installed.cfg
+*.egg
+MANIFEST
*.exp
*.lib
-*.obj
-*.pyc
-*.pyd.manifest
-*.pyo
+
+# PyInstaller
+# Usually these files are written by a python script from a template
+# before PyInstaller builds the exe, so as to inject date/other infos into it.
+*.manifest
+*.spec
+
+# Installer logs
+pip-log.txt
+pip-delete-this-directory.txt
+
+# Unit test / coverage reports
+htmlcov/
+.tox/
+.nox/
+.coverage
+.coverage.*
.cache
-.DS_Store
-.idea
-.project
-.pydevproject
-.settings
-build
-dist
-__pycache__
+nosetests.xml
+coverage.xml
+*.cover
+*.py,cover
+.hypothesis/
+.pytest_cache/
+cover/
+
+# Translations
+*.mo
+*.pot
+
+# Django stuff:
+*.log
+local_settings.py
+db.sqlite3
+db.sqlite3-journal
+
+# Flask stuff:
+instance/
+.webassets-cache
+
+# Scrapy stuff:
+.scrapy
+
+# Sphinx documentation
+docs/_build/
+
+# PyBuilder
+.pybuilder/
+target/
+
+# Jupyter Notebook
+.ipynb_checkpoints
+
+# IPython
+profile_default/
+ipython_config.py
+
+# pyenv
+# For a library or package, you might want to ignore these files since the code is
+# intended to run in multiple environments; otherwise, check them in:
+# .python-version
+
+# pipenv
+# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
+# However, in case of collaboration, if having platform-specific dependencies or dependencies
+# having no cross-platform support, pipenv may install dependencies that don't work, or not
+# install all needed dependencies.
+#Pipfile.lock
+
+# poetry
+# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
+# This is especially recommended for binary packages to ensure reproducibility, and is more
+# commonly ignored for libraries.
+# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
+#poetry.lock
+
+# pdm
+# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
+#pdm.lock
+# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
+# in version control.
+# https://pdm.fming.dev/#use-with-ide
+.pdm.toml
+
+# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
+__pypackages__/
+
+# Celery stuff
+celerybeat-schedule
+celerybeat.pid
+
+# SageMath parsed files
+*.sage.py
+
+# Environments
+.env
+.venv
+env/
+venv/
+ENV/
+env.bak/
+venv.bak/
+
+# Spyder project settings
+.spyderproject
+.spyproject
+
+# Rope project settings
+.ropeproject
+
+# mkdocs documentation
+/site
+
+# mypy
+.mypy_cache/
+.dmypy.json
+dmypy.json
+
+# Pyre type checker
+.pyre/
+
+# pytype static type analyzer
+.pytype/
+
+# Cython debug symbols
+cython_debug/
+
+# PyCharm
+# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
+# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
+# and can be added to the global gitignore or merged into this file. For a more nuclear
+# option (not recommended) you can uncomment the following to ignore the entire idea folder.
+#.idea/
\ No newline at end of file
diff --git a/.readthedocs.yml b/.readthedocs.yml
index d6186290..98566eac 100644
--- a/.readthedocs.yml
+++ b/.readthedocs.yml
@@ -4,7 +4,7 @@
version: 2
build:
- os: "ubuntu-20.04"
+ os: ubuntu-22.04
apt_packages:
- npm
- plantuml
@@ -18,9 +18,9 @@ build:
- npm install -g @mermaid-js/mermaid-cli@10.3.1
# Set requirements to build the docs
-python:
- install:
- - requirements: docs/requirements.txt
+# python:
+# install:
+# - requirements: docs/requirements.txt
# Build documentation in the docs/ directory with Sphinx
sphinx:
diff --git a/docs/conf.py b/docs/conf.py
index f1cb4798..ea094f75 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -18,10 +18,9 @@
# Add python modules to be documented
python_root = '..'
-python_modules = ( 'geosx_mesh_tools_package', 'geosx_xml_tools_package', 'geosx_mesh_doctor', 'geos_ats_package',
- 'hdf5_wrapper_package', 'pygeosx_tools_package', 'timehistory_package' )
+python_modules = ( 'geos-xml-tools', 'geos-mesh', 'geos-ats', 'hdf5-wrapper', 'pygeos-tools', 'geos-timehistory' )
for m in python_modules:
- sys.path.insert( 0, os.path.abspath( os.path.join( python_root, m ) ) )
+ sys.path.insert( 0, os.path.abspath( os.path.join( python_root, m, 'src' ) ) )
# -- Project information -----------------------------------------------------
diff --git a/docs/geos_ats.rst b/docs/geos-ats.rst
similarity index 75%
rename from docs/geos_ats.rst
rename to docs/geos-ats.rst
index dfbbf85c..2327707d 100644
--- a/docs/geos_ats.rst
+++ b/docs/geos-ats.rst
@@ -2,7 +2,7 @@
GEOS ATS
==========
-The `geos_ats` python package includes tools for managing integrated tests for GEOS.
+The `geos-ats` python package includes tools for managing integrated tests for GEOS.
It is built using the `Automated Test System `_ (ATS) package.
The available console scripts for this package and its API are described below.
@@ -13,7 +13,7 @@ run_geos_ats
Primary entry point for running integrated tests.
.. argparse::
- :module: geos_ats.command_line_parsers
+ :module: geos.ats.command_line_parsers
:func: build_command_line_parser
:prog: run_geos_ats
@@ -29,11 +29,11 @@ Primary entry point for running integrated tests.
Debugging
------------------
-If for any reason you need to debug the geos_ats package, we recommend that you create a local copy of this entry point in the `build/integratedTests` directory: `geosPythonPackages/geos_ats_package/geos_ats/debug_geos_ats.py`.
+If for any reason you need to debug the geos-ats package, we recommend that you create a local copy of this entry point in the `build/integratedTests` directory: `geosPythonPackages/geos-ats_package/geos-ats/debug_geos-ats.py`.
This script is designed as a debugger entry point, and will read the autogenerated run script that was built during setup.
-To use it, you must either have geos_ats installed in your target python environment, or a copy of geosPythonPackages in the expected location (`/usr/workspace/[username]/geosPythonPackages`).
+To use it, you must either have geos-ats installed in your target python environment, or a copy of geosPythonPackages in the expected location (`/usr/workspace/[username]/geosPythonPackages`).
-We recommend that you use VSCode with the Python extension to debug geos_ats.
+We recommend that you use VSCode with the Python extension to debug geos-ats.
To begin the debugging session, you simply need to load the entry script, set any initial breakpoints you desire, then select the Debug run option.
Note that this approach can only be used to debug the python code associated with tests, and not the underlying GEOS tests.
@@ -45,14 +45,14 @@ API
Restart Check
^^^^^^^^^^^^^^^
-.. automodule:: geos_ats.helpers.restart_check
+.. automodule:: geos.ats.helpers.restart_check
:members:
Curve Check
^^^^^^^^^^^^^^^
-.. automodule:: geos_ats.helpers.curve_check
+.. automodule:: geos.ats.helpers.curve_check
:members:
diff --git a/docs/mesh_doctor.rst b/docs/geos-mesh.rst
similarity index 52%
rename from docs/mesh_doctor.rst
rename to docs/geos-mesh.rst
index 5d8540e7..8582f106 100644
--- a/docs/mesh_doctor.rst
+++ b/docs/geos-mesh.rst
@@ -1,35 +1,40 @@
+
+GEOS Mesh Tools
+====================
+
+
Mesh Doctor
---------------
-``mesh_doctor`` is a ``python`` executable that can be used through the command line to perform various checks, validations, and tiny fixes to the ``vtk`` mesh that are meant to be used in ``geos``.
-``mesh_doctor`` is organized as a collection of modules with their dedicated sets of options.
+``mesh-doctor`` is a ``python`` executable that can be used through the command line to perform various checks, validations, and tiny fixes to the ``vtk`` mesh that are meant to be used in ``geos``.
+``mesh-doctor`` is organized as a collection of modules with their dedicated sets of options.
The current page will introduce those modules, but the details and all the arguments can be retrieved by using the ``--help`` option for each module.
Modules
^^^^^^^
-To list all the modules available through ``mesh_doctor``, you can simply use the ``--help`` option, which will list all available modules as well as a quick summary.
+To list all the modules available through ``mesh-doctor``, you can simply use the ``--help`` option, which will list all available modules as well as a quick summary.
-.. command-output:: python mesh_doctor.py --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py --help
+ :cwd: ../geos-mesh
-Then, if you are interested in a specific module, you can ask for its documentation using the ``mesh_doctor module_name --help`` pattern.
+Then, if you are interested in a specific module, you can ask for its documentation using the ``mesh-doctor module_name --help`` pattern.
For example
-.. command-output:: python mesh_doctor.py collocated_nodes --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py collocated_nodes --help
+ :cwd: ../geos-mesh
-``mesh_doctor`` loads its module dynamically.
-If a module can't be loaded, ``mesh_doctor`` will proceed and try to load other modules.
+``mesh-doctor`` loads its module dynamically.
+If a module can't be loaded, ``mesh-doctor`` will proceed and try to load other modules.
If you see a message like
.. code-block:: bash
[1970-04-14 03:07:15,625][WARNING] Could not load module "collocated_nodes": No module named 'vtkmodules'
-then most likely ``mesh_doctor`` could not load the ``collocated_nodes`` module, because the ``vtk`` python package was not found.
+then most likely ``mesh-doctor`` could not load the ``collocated_nodes`` module, because the ``vtk`` python package was not found.
Thereafter, the documentation for module ``collocated_nodes`` will not be displayed.
-You can solve this issue by installing the dependencies of ``mesh_doctor`` defined in its ``requirements.txt`` file (``python -m pip install -r requirements.txt``).
+You can solve this issue by installing the dependencies of ``mesh-doctor`` defined in its ``requirements.txt`` file (``python -m pip install -r requirements.txt``).
Here is a list and brief description of all the modules available.
@@ -39,8 +44,8 @@ Here is a list and brief description of all the modules available.
Displays the neighboring nodes that are closer to each other than a prescribed threshold.
It is not uncommon to define multiple nodes for the exact same position, which will typically be an issue for ``geos`` and should be fixed.
-.. command-output:: python mesh_doctor.py collocated_nodes --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py collocated_nodes --help
+ :cwd: ../geos-mesh
``element_volumes``
"""""""""""""""""""
@@ -48,8 +53,8 @@ It is not uncommon to define multiple nodes for the exact same position, which w
Computes the volumes of all the cells and displays the ones that are below a prescribed threshold.
Cells with negative volumes will typically be an issue for ``geos`` and should be fixed.
-.. command-output:: python mesh_doctor.py element_volumes --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py element_volumes --help
+ :cwd: ../geos-mesh
``fix_elements_orderings``
""""""""""""""""""""""""""
@@ -58,8 +63,8 @@ It sometimes happens that an exported mesh does not abide by the ``vtk`` orderin
The ``fix_elements_orderings`` module can rearrange the nodes of given types of elements.
This can be convenient if you cannot regenerate the mesh.
-.. command-output:: python mesh_doctor.py fix_elements_orderings --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py fix_elements_orderings --help
+ :cwd: ../geos-mesh
``generate_cube``
"""""""""""""""""
@@ -68,8 +73,8 @@ This module conveniently generates cubic meshes in ``vtk``.
It can also generate fields with simple values.
This tool can also be useful to generate a trial mesh that will later be refined or customized.
-.. command-output:: python mesh_doctor.py generate_cube --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py generate_cube --help
+ :cwd: ../geos-mesh
``generate_fractures``
""""""""""""""""""""""
@@ -77,8 +82,8 @@ This tool can also be useful to generate a trial mesh that will later be refined
For a conformal fracture to be defined in a mesh, ``geos`` requires the mesh to be split at the faces where the fracture gets across the mesh.
The ``generate_fractures`` module will split the mesh and generate the multi-block ``vtk`` files.
-.. command-output:: python mesh_doctor.py generate_fractures --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py generate_fractures --help
+ :cwd: ../geos-mesh
``generate_global_ids``
"""""""""""""""""""""""
@@ -86,8 +91,8 @@ The ``generate_fractures`` module will split the mesh and generate the multi-blo
When running ``geos`` in parallel, `global ids` can be used to refer to data across multiple ranks.
The ``generate_global_ids`` can generate `global ids` for the imported ``vtk`` mesh.
-.. command-output:: python mesh_doctor.py generate_global_ids --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py generate_global_ids --help
+ :cwd: ../geos-mesh
``non_conformal``
"""""""""""""""""
@@ -97,8 +102,8 @@ This module will detect elements which are close enough (there's a user defined
The angle between two faces can also be precribed.
This module can be a bit time consuming.
-.. command-output:: python mesh_doctor.py non_conformal --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py non_conformal --help
+ :cwd: ../geos-mesh
``self_intersecting_elements``
""""""""""""""""""""""""""""""
@@ -106,8 +111,8 @@ This module can be a bit time consuming.
Some meshes can have cells that auto-intersect.
This module will display the elements that have faces intersecting.
-.. command-output:: python mesh_doctor.py self_intersecting_elements --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py self_intersecting_elements --help
+ :cwd: ../geos-mesh
``supported_elements``
""""""""""""""""""""""
@@ -120,5 +125,62 @@ But also prismes up to 11 faces.
The ``supported_elements`` check will validate that no unsupported element is included in the input mesh.
It will also verify that the ``VTK_POLYHEDRON`` cells can effectively get converted into a supported type of element.
-.. command-output:: python mesh_doctor.py supported_elements --help
- :cwd: ../geosx_mesh_doctor
+.. command-output:: python src/geos/mesh/doctor/mesh_doctor.py supported_elements --help
+ :cwd: ../geos-mesh
+
+
+
+Mesh Conversion
+--------------------------
+
+The `geos-mesh` python package includes tools for converting meshes from common formats (abaqus, etc.) to those that can be read by GEOS (gmsh, vtk).
+See :ref:`PythonToolsSetup` for details on setup instructions, and `External Mesh Guidelines `_ for a detailed description of how to use external meshes in GEOS.
+The available console scripts for this package and its API are described below.
+
+
+convert_abaqus
+^^^^^^^^^^^^^^
+
+Compile an xml file with advanced features into a single file that can be read by GEOS.
+
+.. argparse::
+ :module: geos.mesh.conversion.main
+ :func: build_abaqus_converter_input_parser
+ :prog: convert_abaqus
+
+
+.. note::
+ For vtk format meshes, the user also needs to determine the region ID numbers and names of nodesets to import into GEOS.
+ The following shows how these could look in an input XML file for a mesh with three regions (*REGIONA*, *REGIONB*, and *REGIONC*) and six nodesets (*xneg*, *xpos*, *yneg*, *ypos*, *zneg*, and *zpos*):
+
+
+.. code-block:: xml
+
+
+
+
+
+
+
+
+
+
+
+
+API
+^^^
+
+.. automodule:: geos.mesh.conversion.abaqus_converter
+ :members:
+
+
+
+
diff --git a/docs/timehistory.rst b/docs/geos-timehistory.rst
similarity index 54%
rename from docs/timehistory.rst
rename to docs/geos-timehistory.rst
index cf3ac46e..0ad2db57 100644
--- a/docs/timehistory.rst
+++ b/docs/geos-timehistory.rst
@@ -2,5 +2,5 @@
Time History Tools
--------------------------
-.. automodule:: timehistory.plot_time_history
+.. automodule:: geos.timehistory.plot_time_history
:members:
diff --git a/docs/geosx_xml_tools.rst b/docs/geos-xml-tools.rst
similarity index 65%
rename from docs/geosx_xml_tools.rst
rename to docs/geos-xml-tools.rst
index 97588396..72ef2a13 100644
--- a/docs/geosx_xml_tools.rst
+++ b/docs/geos-xml-tools.rst
@@ -4,7 +4,7 @@
GEOS XML Tools
--------------------------
-The `geosx_xml_tools` python package adds a set of advanced features to the GEOS xml format: units, parameters, and symbolic expressions.
+The `geos-xml-tools` python package adds a set of advanced features to the GEOS xml format: units, parameters, and symbolic expressions.
See :ref:`PythonToolsSetup` for details on setup instructions, and `Advanced XML Features `_ for a detailed description of the input format.
The available console scripts for this package and its API are described below.
@@ -15,7 +15,7 @@ convert_abaqus
Convert an abaqus format mesh file to gmsh or vtk format.
.. argparse::
- :module: geosx_xml_tools.command_line_parsers
+ :module: geos.xml_tools.command_line_parsers
:func: build_preprocessor_input_parser
:prog: preprocess_xml
@@ -26,7 +26,7 @@ format_xml
Formats an xml file.
.. argparse::
- :module: geosx_xml_tools.command_line_parsers
+ :module: geos.xml_tools.command_line_parsers
:func: build_xml_formatter_input_parser
:prog: format_xml
@@ -37,7 +37,7 @@ check_xml_attribute_coverage
Checks xml attribute coverage for files in the GEOS repository.
.. argparse::
- :module: geosx_xml_tools.command_line_parsers
+ :module: geos.xml_tools.command_line_parsers
:func: build_attribute_coverage_input_parser
:prog: check_xml_attribute_coverage
@@ -48,7 +48,7 @@ check_xml_redundancy
Checks for redundant attribute definitions in an xml file, such as those that duplicate the default value.
.. argparse::
- :module: geosx_xml_tools.command_line_parsers
+ :module: geos.xml_tools.command_line_parsers
:func: build_xml_redundancy_input_parser
:prog: check_xml_redundancy
@@ -56,27 +56,27 @@ Checks for redundant attribute definitions in an xml file, such as those that du
API
^^^
-.. automodule:: geosx_xml_tools.main
+.. automodule:: geos.xml_tools.main
:members:
-.. automodule:: geosx_xml_tools.xml_processor
+.. automodule:: geos.xml_tools.xml_processor
:members:
-.. automodule:: geosx_xml_tools.xml_formatter
+.. automodule:: geos.xml_tools.xml_formatter
:members:
-.. automodule:: geosx_xml_tools.unit_manager
+.. automodule:: geos.xml_tools.unit_manager
:members:
-.. automodule:: geosx_xml_tools.regex_tools
+.. automodule:: geos.xml_tools.regex_tools
:members:
-.. automodule:: geosx_xml_tools.xml_redundancy_check
+.. automodule:: geos.xml_tools.xml_redundancy_check
:members:
-.. automodule:: geosx_xml_tools.attribute_coverage
+.. automodule:: geos.xml_tools.attribute_coverage
:members:
-.. automodule:: geosx_xml_tools.table_generator
+.. automodule:: geos.xml_tools.table_generator
:members:
diff --git a/docs/geosx_mesh_tools.rst b/docs/geosx_mesh_tools.rst
deleted file mode 100644
index 2370d893..00000000
--- a/docs/geosx_mesh_tools.rst
+++ /dev/null
@@ -1,51 +0,0 @@
-
-GEOS Mesh Tools
---------------------------
-
-The `geosx_mesh_tools` python package includes tools for converting meshes from common formats (abaqus, etc.) to those that can be read by GEOS (gmsh, vtk).
-See :ref:`PythonToolsSetup` for details on setup instructions, and `External Mesh Guidelines `_ for a detailed description of how to use external meshes in GEOS.
-The available console scripts for this package and its API are described below.
-
-
-convert_abaqus
-^^^^^^^^^^^^^^
-
-Compile an xml file with advanced features into a single file that can be read by GEOS.
-
-.. argparse::
- :module: geosx_mesh_tools.main
- :func: build_abaqus_converter_input_parser
- :prog: convert_abaqus
-
-
-.. note::
- For vtk format meshes, the user also needs to determine the region ID numbers and names of nodesets to import into GEOS.
- The following shows how these could look in an input XML file for a mesh with three regions (*REGIONA*, *REGIONB*, and *REGIONC*) and six nodesets (*xneg*, *xpos*, *yneg*, *ypos*, *zneg*, and *zpos*):
-
-
-.. code-block:: xml
-
-
-
-
-
-
-
-
-
-
-
-
-API
-^^^
-
-.. automodule:: geosx_mesh_tools.abaqus_converter
- :members:
diff --git a/docs/hdf5_wrapper.rst b/docs/hdf5-wrapper.rst
similarity index 79%
rename from docs/hdf5_wrapper.rst
rename to docs/hdf5-wrapper.rst
index 01f1ad9f..a3038baa 100644
--- a/docs/hdf5_wrapper.rst
+++ b/docs/hdf5-wrapper.rst
@@ -2,7 +2,7 @@
HDF5 Wrapper
--------------------------
-The `hdf5_wrapper` python package adds a wrapper to `h5py` that greatly simplifies reading/writing to/from hdf5-format files.
+The `hdf5-wrapper` python package adds a wrapper to `h5py` that greatly simplifies reading/writing to/from hdf5-format files.
Usage
@@ -12,9 +12,9 @@ Once loaded, the contents of a file can be navigated in the same way as a native
.. code-block:: python
- import hdf5_wrapper
+ from geos.hdf5_wrapper import hdf5_wrapper
- data = hdf5_wrapper.hdf5_wrapper('data.hdf5')
+ data = hdf5_wrapper('data.hdf5')
test = data['test']
for k, v in data.items():
@@ -26,10 +26,10 @@ Note: for these changes to be written to the disk, the wrapper may need to be cl
.. code-block:: python
- import hdf5_wrapper
+ from geos.hdf5_wrapper import hdf5_wrapper
import numpy as np
- data = hdf5_wrapper.hdf5_wrapper('data.hdf5', mode='w')
+ data = hdf5_wrapper('data.hdf5', mode='w')
data['string'] = 'string'
data['integer'] = 123
data['array'] = np.random.randn(3, 4, 5)
@@ -56,5 +56,5 @@ And external hdf5 format files can be linked together:
API
^^^^^
-.. automodule:: hdf5_wrapper.wrapper
+.. automodule:: geos.hdf5_wrapper.wrapper
:members:
diff --git a/docs/index.rst b/docs/index.rst
index d72849e8..4a56ec79 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -43,9 +43,9 @@ To do this, you can clone a copy of the geosPythonPackages repository and instal
cd /path/to/store/python/tools
git clone https://github.com/GEOS-DEV/geosPythonPackages.git
- # Install/upgrade geos_ats
- cd geosPythonPackages/geos_ats_package
- python -m pip install --upgrade .
+ # Install/upgrade geos-ats
+ cd geosPythonPackages/
+ python -m pip install --upgrade geos-ats
.. note::
@@ -76,16 +76,14 @@ Packages
.. toctree::
:maxdepth: 1
- hdf5_wrapper
+ hdf5-wrapper
- geos_ats
+ geos-ats
- geosx_mesh_tools
+ geos-mesh
- geosx_xml_tools
+ geos-xml-tools
- pygeosx_tools
+ pygeos-tools
- timehistory
-
- mesh_doctor
+ geos-timehistory
diff --git a/docs/pygeosx_tools.rst b/docs/pygeos-tools.rst
similarity index 59%
rename from docs/pygeosx_tools.rst
rename to docs/pygeos-tools.rst
index 87973ca8..b3484f38 100644
--- a/docs/pygeosx_tools.rst
+++ b/docs/pygeos-tools.rst
@@ -1,8 +1,8 @@
-PyGEOSX Tools
+PyGEOS Tools
--------------------------
-The `pygeosx_tools` python package adds a variety of tools for working with pygeosx objects.
+The `pygeos-tools` python package adds a variety of tools for working with pygeosx objects.
These include common operations such as setting the value of geosx wrappers with python functions, parallel communication, and file IO.
Examples using these tools can be found here: `PYGEOSX Examples `_ .
@@ -10,15 +10,15 @@ Examples using these tools can be found here: `PYGEOSX Examples =0.17
# Installing the mesh_doctor requirements to be able to load all the modules and run the help.
--r ../geosx_mesh_doctor/requirements.txt
+vtk >= 9.1
+networkx >= 2.4
+tqdm
+numpy
diff --git a/geos-ats/pyproject.toml b/geos-ats/pyproject.toml
new file mode 100644
index 00000000..bb9a1c73
--- /dev/null
+++ b/geos-ats/pyproject.toml
@@ -0,0 +1,52 @@
+
+[build-system]
+build-backend = "setuptools.build_meta"
+requires = ["setuptools>=61.0", "wheel>=0.37.1"]
+
+[project]
+name = "geos-ats"
+version = "0.2.0"
+description = "ATS implementation for GEOS testing"
+authors = [{name = "GEOS Contributors" }]
+maintainers = [
+ {name = "Christopher Sherman", email = "sherman27@llnl.gov"}
+]
+license = {text = "LGPL-2.1"}
+classifiers = [
+ "Development Status :: 4 - Beta",
+ "Programming Language :: Python"
+]
+requires-python = ">=3.7"
+dependencies = [
+ "h5py",
+ "mpi4py",
+ "numpy",
+ "lxml",
+ "tabulate",
+ "pyyaml",
+ "tqdm",
+ "requests",
+ "GitPython",
+ "google-cloud-storage",
+ "pip-system-certs",
+ "ats @ https://github.com/LLNL/ATS/archive/refs/tags/7.0.105.tar.gz",
+]
+
+[project.scripts]
+run_geos_ats = "geos.ats.main:main"
+setup_ats_environment = "geos.ats.environment_setup:main"
+geos_ats_log_check = "geos.ats.helpers.log_check:main"
+geos_ats_restart_check = "geos.ats.helpers.restart_check:main"
+geos_ats_curve_check = "geos.ats.helpers.curve_check:main"
+
+[project.urls]
+Homepage = "https://github.com/GEOS-DEV/geosPythonPackages"
+Documentation = "https://geosx-geosx.readthedocs-hosted.com/projects/geosx-geospythonpackages/en/latest/"
+Repository = "https://github.com/GEOS-DEV/geosPythonPackages.git"
+"Bug Tracker" = "https://github.com/GEOS-DEV/geosPythonPackages/issues"
+
+[tool.setuptools]
+include-package-data = true
+
+[tool.setuptools.package-data]
+"*" = ["*.js", "*.css", "*.zip"]
diff --git a/geos_ats_package/geos_ats/__init__.py b/geos-ats/src/geos/ats/__init__.py
similarity index 100%
rename from geos_ats_package/geos_ats/__init__.py
rename to geos-ats/src/geos/ats/__init__.py
diff --git a/geos_ats_package/geos_ats/assets/__init__.py b/geos-ats/src/geos/ats/assets/__init__.py
similarity index 100%
rename from geos_ats_package/geos_ats/assets/__init__.py
rename to geos-ats/src/geos/ats/assets/__init__.py
diff --git a/geos_ats_package/geos_ats/assets/lightbox.zip b/geos-ats/src/geos/ats/assets/lightbox.zip
similarity index 100%
rename from geos_ats_package/geos_ats/assets/lightbox.zip
rename to geos-ats/src/geos/ats/assets/lightbox.zip
diff --git a/geos_ats_package/geos_ats/assets/sorttable.js b/geos-ats/src/geos/ats/assets/sorttable.js
similarity index 100%
rename from geos_ats_package/geos_ats/assets/sorttable.js
rename to geos-ats/src/geos/ats/assets/sorttable.js
diff --git a/geos_ats_package/geos_ats/assets/style.css b/geos-ats/src/geos/ats/assets/style.css
similarity index 100%
rename from geos_ats_package/geos_ats/assets/style.css
rename to geos-ats/src/geos/ats/assets/style.css
diff --git a/geos_ats_package/geos_ats/baseline_io.py b/geos-ats/src/geos/ats/baseline_io.py
similarity index 100%
rename from geos_ats_package/geos_ats/baseline_io.py
rename to geos-ats/src/geos/ats/baseline_io.py
diff --git a/geos_ats_package/geos_ats/command_line_parsers.py b/geos-ats/src/geos/ats/command_line_parsers.py
similarity index 100%
rename from geos_ats_package/geos_ats/command_line_parsers.py
rename to geos-ats/src/geos/ats/command_line_parsers.py
diff --git a/geos_ats_package/geos_ats/common_utilities.py b/geos-ats/src/geos/ats/common_utilities.py
similarity index 97%
rename from geos_ats_package/geos_ats/common_utilities.py
rename to geos-ats/src/geos/ats/common_utilities.py
index 3e32db15..5f506b61 100644
--- a/geos_ats_package/geos_ats/common_utilities.py
+++ b/geos-ats/src/geos/ats/common_utilities.py
@@ -10,7 +10,7 @@
# Common code for displaying information to the user.
################################################################################
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
def Error( msg ):
@@ -228,7 +228,7 @@ def process( self, args ):
def removeLogDirectories( dir ):
- # look for subdirs containing 'ats.log' and 'geos_ats.config'
+ # look for subdirs containing 'ats.log' and 'geos-ats.config'
# look for symlinks that point to such a directory
files = os.listdir( dir )
deldir = []
@@ -238,7 +238,7 @@ def removeLogDirectories( dir ):
tests = [
all( [
os.path.exists( os.path.join( ff, "ats.log" ) ),
- os.path.exists( os.path.join( ff, "geos_ats.config" ) )
+ os.path.exists( os.path.join( ff, "geos-ats.config" ) )
] ),
f.find( "TestLogs." ) == 0
]
diff --git a/geos_ats_package/geos_ats/configuration_record.py b/geos-ats/src/geos/ats/configuration_record.py
similarity index 99%
rename from geos_ats_package/geos_ats/configuration_record.py
rename to geos-ats/src/geos/ats/configuration_record.py
index d98cc510..1d8203a4 100644
--- a/geos_ats_package/geos_ats/configuration_record.py
+++ b/geos-ats/src/geos/ats/configuration_record.py
@@ -1,7 +1,7 @@
import os
import sys
-from geos_ats.common_utilities import TextTable, InfoTopic, Error, Log
-from geos_ats.suite_settings import testLabels
+from geos.ats.common_utilities import TextTable, InfoTopic, Error, Log
+from geos.ats.suite_settings import testLabels
import difflib
import logging
@@ -10,7 +10,7 @@
################################################################################
# Get the active logger instance
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
class ConfigItem( object ):
diff --git a/geos_ats_package/geos_ats/debug_geos_ats.py b/geos-ats/src/geos/ats/debug_geos_ats.py
similarity index 88%
rename from geos_ats_package/geos_ats/debug_geos_ats.py
rename to geos-ats/src/geos/ats/debug_geos_ats.py
index 5bedcb8f..2a71ff16 100644
--- a/geos_ats_package/geos_ats/debug_geos_ats.py
+++ b/geos-ats/src/geos/ats/debug_geos_ats.py
@@ -1,5 +1,5 @@
"""
-Entry point for debugging geos_ats
+Entry point for debugging geos-ats
To use this script, do the following:
- Setup your ats environment (using the 'make ats_environment' command)
@@ -19,7 +19,7 @@ def debug_geos_ats():
# Check for a copy of geos_ats in the user's workspace to use
# instead of any currently installed in python
user = os.environ.get( 'USER', '' )
- mod_path = f"/usr/workspace/{user}/geosPythonPackages/geos_ats_package"
+ mod_path = f"/usr/workspace/{user}/geosPythonPackages/geos-ats"
if os.path.isdir( mod_path ):
sys.path.insert( 0, os.path.join( mod_path ) )
@@ -29,7 +29,7 @@ def debug_geos_ats():
sys.argv.extend( args )
# Run ats
- from geos_ats import main
+ from geos.ats import main
main.main()
diff --git a/geos_ats_package/geos_ats/environment_setup.py b/geos-ats/src/geos/ats/environment_setup.py
similarity index 100%
rename from geos_ats_package/geos_ats/environment_setup.py
rename to geos-ats/src/geos/ats/environment_setup.py
diff --git a/geos_ats_package/geos_ats/helpers/__init__.py b/geos-ats/src/geos/ats/helpers/__init__.py
similarity index 100%
rename from geos_ats_package/geos_ats/helpers/__init__.py
rename to geos-ats/src/geos/ats/helpers/__init__.py
diff --git a/geos_ats_package/geos_ats/helpers/curve_check.py b/geos-ats/src/geos/ats/helpers/curve_check.py
similarity index 99%
rename from geos_ats_package/geos_ats/helpers/curve_check.py
rename to geos-ats/src/geos/ats/helpers/curve_check.py
index 1353f62d..a35b27fc 100644
--- a/geos_ats_package/geos_ats/helpers/curve_check.py
+++ b/geos-ats/src/geos/ats/helpers/curve_check.py
@@ -5,7 +5,7 @@
import numpy as np
from scipy.interpolate import interp1d
import matplotlib.pyplot as plt
-import hdf5_wrapper
+from geos.hdf5_wrapper import hdf5_wrapper
unit_map = {
'milliseconds': 1e-3,
@@ -223,7 +223,7 @@ def compare_time_history_curves( fname, baseline, curve, tolerance, output, outp
data_sizes = {}
for k, f in files.items():
if os.path.isfile( f ):
- data[ k ] = hdf5_wrapper.hdf5_wrapper( f ).get_copy()
+ data[ k ] = hdf5_wrapper( f ).get_copy()
else:
errors.append( f'{k} file not found: {f}' )
continue
diff --git a/geos_ats_package/geos_ats/helpers/log_check.py b/geos-ats/src/geos/ats/helpers/log_check.py
similarity index 100%
rename from geos_ats_package/geos_ats/helpers/log_check.py
rename to geos-ats/src/geos/ats/helpers/log_check.py
diff --git a/geos_ats_package/geos_ats/helpers/permute_array.py b/geos-ats/src/geos/ats/helpers/permute_array.py
similarity index 99%
rename from geos_ats_package/geos_ats/helpers/permute_array.py
rename to geos-ats/src/geos/ats/helpers/permute_array.py
index e1cc9c61..1b92df77 100644
--- a/geos_ats_package/geos_ats/helpers/permute_array.py
+++ b/geos-ats/src/geos/ats/helpers/permute_array.py
@@ -1,7 +1,7 @@
import numpy as np # type: ignore[import]
import logging
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
def permuteArray( data, shape, permutation ):
diff --git a/geos_ats_package/geos_ats/helpers/restart_check.py b/geos-ats/src/geos/ats/helpers/restart_check.py
similarity index 99%
rename from geos_ats_package/geos_ats/helpers/restart_check.py
rename to geos-ats/src/geos/ats/helpers/restart_check.py
index ad7c8d5f..7aa282e5 100644
--- a/geos_ats_package/geos_ats/helpers/restart_check.py
+++ b/geos-ats/src/geos/ats/helpers/restart_check.py
@@ -9,15 +9,15 @@
import time
from pathlib import Path
try:
- from geos_ats.helpers.permute_array import permuteArray # type: ignore[import]
+ from geos.ats.helpers.permute_array import permuteArray # type: ignore[import]
except ImportError:
- # Fallback method to be used if geos_ats isn't found
+ # Fallback method to be used if geos-ats isn't found
from permute_array import permuteArray # type: ignore[import]
RTOL_DEFAULT = 0.0
ATOL_DEFAULT = 0.0
EXCLUDE_DEFAULT = [ ".*/commandLine", ".*/schema$", ".*/globalToLocalMap", ".*/timeHistoryOutput.*/restart" ]
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
def write( output, msg ):
diff --git a/geos_ats_package/geos_ats/history.py b/geos-ats/src/geos/ats/history.py
similarity index 100%
rename from geos_ats_package/geos_ats/history.py
rename to geos-ats/src/geos/ats/history.py
diff --git a/geos_ats_package/geos_ats/machine_utilities.py b/geos-ats/src/geos/ats/machine_utilities.py
similarity index 84%
rename from geos_ats_package/geos_ats/machine_utilities.py
rename to geos-ats/src/geos/ats/machine_utilities.py
index 356de83a..baa99bf9 100644
--- a/geos_ats_package/geos_ats/machine_utilities.py
+++ b/geos-ats/src/geos/ats/machine_utilities.py
@@ -1,6 +1,6 @@
-# Common functions for geos_ats modifications to machine files
+# Common functions for geos-ats modifications to machine files
-from geos_ats.configuration_record import config
+from geos.ats.configuration_record import config
import re
import os
diff --git a/geos_ats_package/geos_ats/machines/__init__.py b/geos-ats/src/geos/ats/machines/__init__.py
similarity index 100%
rename from geos_ats_package/geos_ats/machines/__init__.py
rename to geos-ats/src/geos/ats/machines/__init__.py
diff --git a/geos_ats_package/geos_ats/machines/batchGeosatsMoab.py b/geos-ats/src/geos/ats/machines/batchGeosatsMoab.py
similarity index 99%
rename from geos_ats_package/geos_ats/machines/batchGeosatsMoab.py
rename to geos-ats/src/geos/ats/machines/batchGeosatsMoab.py
index 488aba17..533c5ae0 100644
--- a/geos_ats_package/geos_ats/machines/batchGeosatsMoab.py
+++ b/geos-ats/src/geos/ats/machines/batchGeosatsMoab.py
@@ -7,7 +7,7 @@
import logging
debug = configuration.debug
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
class BatchGeosatsMoab( BatchMachine ):
diff --git a/geos_ats_package/geos_ats/machines/bgqos_0_ASQ.py b/geos-ats/src/geos/ats/machines/bgqos_0_ASQ.py
similarity index 100%
rename from geos_ats_package/geos_ats/machines/bgqos_0_ASQ.py
rename to geos-ats/src/geos/ats/machines/bgqos_0_ASQ.py
diff --git a/geos_ats_package/geos_ats/machines/darwin.py b/geos-ats/src/geos/ats/machines/darwin.py
similarity index 100%
rename from geos_ats_package/geos_ats/machines/darwin.py
rename to geos-ats/src/geos/ats/machines/darwin.py
diff --git a/geos_ats_package/geos_ats/machines/geosAtsSlurmProcessorScheduled.py b/geos-ats/src/geos/ats/machines/geosAtsSlurmProcessorScheduled.py
similarity index 94%
rename from geos_ats_package/geos_ats/machines/geosAtsSlurmProcessorScheduled.py
rename to geos-ats/src/geos/ats/machines/geosAtsSlurmProcessorScheduled.py
index ef24cbbf..38839b18 100644
--- a/geos_ats_package/geos_ats/machines/geosAtsSlurmProcessorScheduled.py
+++ b/geos-ats/src/geos/ats/machines/geosAtsSlurmProcessorScheduled.py
@@ -6,8 +6,8 @@
#ATS:slurm24 machines.GeosAtsSlurmProcessorScheduled GeosAtsSlurmProcessorScheduled 24
#ATS:chaos_5_x86_64_ib machines.GeosAtsSlurmProcessorScheduled GeosAtsSlurmProcessorScheduled 16
-from geos_ats.scheduler import scheduler
-from geos_ats.machine_utilities import CheckForEarlyTimeOut
+from geos.ats.scheduler import scheduler
+from geos.ats.machine_utilities import CheckForEarlyTimeOut
from slurmProcessorScheduled import SlurmProcessorScheduled # type: ignore[import]
import subprocess
import logging
@@ -17,7 +17,7 @@ class GeosAtsSlurmProcessorScheduled( SlurmProcessorScheduled ):
def init( self ):
super( GeosAtsSlurmProcessorScheduled, self ).init()
- self.logger = logging.getLogger( 'geos_ats' )
+ self.logger = logging.getLogger( 'geos-ats' )
if not self.runWithSalloc:
try:
# Try to get the number of processors per node via sinfo.
diff --git a/geos_ats_package/geos_ats/machines/lassen.py b/geos-ats/src/geos/ats/machines/lassen.py
similarity index 98%
rename from geos_ats_package/geos_ats/machines/lassen.py
rename to geos-ats/src/geos/ats/machines/lassen.py
index 0694c5cc..51668957 100644
--- a/geos_ats_package/geos_ats/machines/lassen.py
+++ b/geos-ats/src/geos/ats/machines/lassen.py
@@ -20,7 +20,7 @@ class lassenMachine( machines.Machine ):
def init( self ):
self.numtests = 0
self.numProcsAvailable = 0
- self.logger = logging.getLogger( 'geos_ats' )
+ self.logger = logging.getLogger( 'geos-ats' )
def examineOptions( self, options ):
"Examine options from command line, possibly override command line choices."
diff --git a/geos_ats_package/geos_ats/machines/nersc.py b/geos-ats/src/geos/ats/machines/nersc.py
similarity index 93%
rename from geos_ats_package/geos_ats/machines/nersc.py
rename to geos-ats/src/geos/ats/machines/nersc.py
index e92a3e97..e6d1af69 100644
--- a/geos_ats_package/geos_ats/machines/nersc.py
+++ b/geos-ats/src/geos/ats/machines/nersc.py
@@ -6,8 +6,8 @@
#ATS:slurm24 machines.nersc Nersc 24
#ATS:chaos_5_x86_64_ib machines.nersc Nersc 16
-from geos_ats.scheduler import scheduler
-from geos_ats.machine_utilities import CheckForEarlyTimeOut
+from geos.ats.scheduler import scheduler
+from geos.ats.machine_utilities import CheckForEarlyTimeOut
from slurmProcessorScheduled import SlurmProcessorScheduled # type: ignore[import]
import subprocess
import logging
@@ -17,7 +17,7 @@ class Nersc( SlurmProcessorScheduled ):
def init( self ):
super( Nersc, self ).init()
- self.logger = logging.getLogger( 'geos_ats' )
+ self.logger = logging.getLogger( 'geos-ats' )
if not self.runWithSalloc:
try:
# Try to get the number of processors per node via sinfo.
diff --git a/geos_ats_package/geos_ats/machines/openmpi.py b/geos-ats/src/geos/ats/machines/openmpi.py
similarity index 98%
rename from geos_ats_package/geos_ats/machines/openmpi.py
rename to geos-ats/src/geos/ats/machines/openmpi.py
index 8304ca84..524f4108 100644
--- a/geos_ats_package/geos_ats/machines/openmpi.py
+++ b/geos-ats/src/geos/ats/machines/openmpi.py
@@ -18,7 +18,7 @@ def init( self ):
self.numtests = 0
self.maxtests = 0
self.numProcsAvailable = 0
- self.logger = logging.getLogger( 'geos_ats' )
+ self.logger = logging.getLogger( 'geos-ats' )
def examineOptions( self, options ):
"Examine options from command line, possibly override command line choices."
@@ -43,7 +43,7 @@ def examineOptions( self, options ):
self.numberTestsRunningMax = self.numberMaxProcessors
self.numProcsAvailable = self.numberMaxProcessors
- # Copy options for geos_ats config
+ # Copy options for geos-ats config
self.openmpi_numnodes = options.openmpi_numnodes
self.openmpi_maxprocs = options.openmpi_maxprocs
self.maxtests = options.openmpi_maxprocs
diff --git a/geos_ats_package/geos_ats/machines/summit.py b/geos-ats/src/geos/ats/machines/summit.py
similarity index 98%
rename from geos_ats_package/geos_ats/machines/summit.py
rename to geos-ats/src/geos/ats/machines/summit.py
index 016d5f29..3f2ab956 100644
--- a/geos_ats_package/geos_ats/machines/summit.py
+++ b/geos-ats/src/geos/ats/machines/summit.py
@@ -20,7 +20,7 @@ class summitMachine( machines.Machine ):
def init( self ):
self.numtests = 0
self.numProcsAvailable = 0
- self.logger = logging.getLogger( 'geos_ats' )
+ self.logger = logging.getLogger( 'geos-ats' )
def examineOptions( self, options ):
"Examine options from command line, possibly override command line choices."
diff --git a/geos_ats_package/geos_ats/main.py b/geos-ats/src/geos/ats/main.py
similarity index 95%
rename from geos_ats_package/geos_ats/main.py
rename to geos-ats/src/geos/ats/main.py
index eaf0f3b7..efcec428 100644
--- a/geos_ats_package/geos_ats/main.py
+++ b/geos-ats/src/geos/ats/main.py
@@ -6,14 +6,14 @@
import time
import logging
import glob
-from geos_ats import command_line_parsers, baseline_io, history
+from geos.ats import command_line_parsers, baseline_io, history
test_actions = ( "run", "rerun", "check", "continue" )
report_actions = ( "run", "rerun", "report", "continue" )
# Setup the logger
logging.basicConfig( level=logging.DEBUG, format='(%(asctime)s %(module)s:%(lineno)d) %(message)s' )
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
# Job records
current_subproc = None
@@ -46,9 +46,9 @@ def build_ats_arguments( options, originalargv, config ):
def write_log_dir_summary( logdir, originalargv ):
- from geos_ats import configuration_record
+ from geos.ats import configuration_record
- with open( os.path.join( logdir, "geos_ats.config" ), "w" ) as logconfig:
+ with open( os.path.join( logdir, "geos-ats.config" ), "w" ) as logconfig:
tmp = " ".join( originalargv[ 1: ] )
logconfig.write( f'Run with: "{tmp}"\n' )
configuration_record.infoConfigShow( True, logconfig )
@@ -121,7 +121,7 @@ def create_log_directory( options ):
tests, the LogDir is temporary, and only sticks around if geos_ats
exited abnormally.
"""
- from geos_ats import common_utilities
+ from geos.ats import common_utilities
if options.logs is None:
if options.action in test_actions:
basename = getLogDirBaseName()
@@ -166,7 +166,7 @@ def check_timing_file( options, config ):
logger.warning( f'Timing file does not exist {config.timing_file}' )
return
- from geos_ats import configuration_record
+ from geos.ats import configuration_record
with open( config.timing_file, "r" ) as filep:
for line in filep:
if not line.startswith( '#' ):
@@ -175,7 +175,7 @@ def check_timing_file( options, config ):
def infoOptions( title, options ):
- from geos_ats import common_utilities
+ from geos.ats import common_utilities
topic = common_utilities.InfoTopic( title )
topic.startBanner()
table = common_utilities.TextTable( 2 )
@@ -186,7 +186,7 @@ def infoOptions( title, options ):
def info( args ):
- from geos_ats import ( common_utilities, configuration_record, test_steps, suite_settings, test_case,
+ from geos.ats import ( common_utilities, configuration_record, test_steps, suite_settings, test_case,
test_modifier )
infoLabels = lambda *x: suite_settings.infoLabels( suite_settings.__file__ )
@@ -210,7 +210,7 @@ def info( args ):
def report( manager ):
"""The report action"""
- from geos_ats import ( reporting, configuration_record )
+ from geos.ats import ( reporting, configuration_record )
if configuration_record.config.report_html:
reporter = reporting.ReportHTML( manager.testlist )
@@ -224,7 +224,7 @@ def report( manager ):
def summary( manager, alog, short=False ):
"""Periodic summary and final summary"""
- from geos_ats import ( reporting, configuration_record )
+ from geos.ats import ( reporting, configuration_record )
if len( manager.testlist ) == 0:
return
@@ -265,7 +265,7 @@ def main():
logger.setLevel( verbosity_options[ options.verbose ] )
# Set key environment variables before importing ats
- from geos_ats import machines
+ from geos.ats import machines
search_path = ''
if options.machine_dir is not None:
if os.path.isdir( options.machine_dir ):
@@ -305,7 +305,7 @@ def main():
quit()
# Check the test configuration
- from geos_ats import configuration_record
+ from geos.ats import configuration_record
configuration_record.initializeConfig( configFile, configOverride, options )
config = configuration_record.config
config.geos_bin_dir = options.geos_bin_dir
@@ -344,7 +344,7 @@ def main():
# Note: the sys.argv is read here by default
import ats # type: ignore[import]
ats.manager.init()
- logger.debug( 'Copying options to the geos_ats config record file' )
+ logger.debug( 'Copying options to the geos-ats config record file' )
config.copy_values( ats.manager.machine )
# Glue global values
@@ -366,7 +366,7 @@ def main():
else:
ats.AtsTest.glue( testcases="all" )
- from geos_ats import ( common_utilities, suite_settings, test_case, test_steps, test_builder )
+ from geos.ats import ( common_utilities, suite_settings, test_case, test_steps, test_builder )
# Set ats options
append_geos_ats_summary( ats.manager )
diff --git a/geos_ats_package/geos_ats/reporting.py b/geos-ats/src/geos/ats/reporting.py
similarity index 99%
rename from geos_ats_package/geos_ats/reporting.py
rename to geos-ats/src/geos/ats/reporting.py
index 9222cb65..0da15353 100644
--- a/geos_ats_package/geos_ats/reporting.py
+++ b/geos-ats/src/geos/ats/reporting.py
@@ -1,8 +1,8 @@
import os
import socket
import time
-from geos_ats.configuration_record import config
-from geos_ats import assets
+from geos.ats.configuration_record import config
+from geos.ats import assets
from configparser import ConfigParser
from tabulate import tabulate
import glob
@@ -15,7 +15,7 @@
from ats import ( PASSED, FAILED, TIMEDOUT, EXPECTED, BATCHED, FILTERED, SKIPPED, CREATED, RUNNING, HALTED, LSFERROR )
# Get the active logger instance
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
# Status value in priority order
STATUS = ( EXPECTED, CREATED, BATCHED, FILTERED, SKIPPED, RUNNING, PASSED, TIMEDOUT, HALTED, LSFERROR, FAILED )
diff --git a/geos_ats_package/geos_ats/scheduler.py b/geos-ats/src/geos/ats/scheduler.py
similarity index 95%
rename from geos_ats_package/geos_ats/scheduler.py
rename to geos-ats/src/geos/ats/scheduler.py
index 51faa2f6..19fcc501 100644
--- a/geos_ats_package/geos_ats/scheduler.py
+++ b/geos-ats/src/geos/ats/scheduler.py
@@ -2,8 +2,8 @@
import os
import re
import time
-from geos_ats.configuration_record import config
-from geos_ats.common_utilities import Log
+from geos.ats.configuration_record import config
+from geos.ats.common_utilities import Log
from ats.log import log # type: ignore[import]
from ats.atsut import PASSED, FAILED, CREATED, EXPECTED, TIMEDOUT # type: ignore[import]
from ats.schedulers import StandardScheduler # type: ignore[import]
diff --git a/geos_ats_package/geos_ats/suite_settings.py b/geos-ats/src/geos/ats/suite_settings.py
similarity index 91%
rename from geos_ats_package/geos_ats/suite_settings.py
rename to geos-ats/src/geos/ats/suite_settings.py
index c9a2e5ea..c7fcfb72 100644
--- a/geos_ats_package/geos_ats/suite_settings.py
+++ b/geos-ats/src/geos/ats/suite_settings.py
@@ -1,4 +1,4 @@
-from geos_ats import common_utilities
+from geos.ats import common_utilities
import logging
testLabels = [
@@ -7,7 +7,7 @@
]
testOwners = [ ( "corbett5", "Ben Corbett" ) ]
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
def infoOwners( filename ):
diff --git a/geos_ats_package/geos_ats/test_builder.py b/geos-ats/src/geos/ats/test_builder.py
similarity index 99%
rename from geos_ats_package/geos_ats/test_builder.py
rename to geos-ats/src/geos/ats/test_builder.py
index cb1de711..21ec98ea 100644
--- a/geos_ats_package/geos_ats/test_builder.py
+++ b/geos-ats/src/geos/ats/test_builder.py
@@ -12,7 +12,7 @@
from .test_case import TestCase
test_build_failures = []
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
@dataclass( frozen=True )
diff --git a/geos_ats_package/geos_ats/test_case.py b/geos-ats/src/geos/ats/test_case.py
similarity index 98%
rename from geos_ats_package/geos_ats/test_case.py
rename to geos-ats/src/geos/ats/test_case.py
index 5d14d503..9c3c27fd 100644
--- a/geos_ats_package/geos_ats/test_case.py
+++ b/geos-ats/src/geos/ats/test_case.py
@@ -7,12 +7,12 @@
from configparser import ConfigParser
from ats import atsut
from ats import ( EXPECTED, PASSED, FAILED, FILTERED, SKIPPED )
-from geos_ats.common_utilities import Error, Log, removeLogDirectories
-from geos_ats.configuration_record import config, globalTestTimings
+from geos.ats.common_utilities import Error, Log, removeLogDirectories
+from geos.ats.configuration_record import config, globalTestTimings
test = ats.manager.test
testif = ats.manager.testif
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
all_test_names = []
diff --git a/geos_ats_package/geos_ats/test_modifier.py b/geos-ats/src/geos/ats/test_modifier.py
similarity index 92%
rename from geos_ats_package/geos_ats/test_modifier.py
rename to geos-ats/src/geos/ats/test_modifier.py
index 11187b22..b1f68e58 100644
--- a/geos_ats_package/geos_ats/test_modifier.py
+++ b/geos-ats/src/geos/ats/test_modifier.py
@@ -1,11 +1,11 @@
import ats # type: ignore[import]
-from geos_ats import common_utilities
-from geos_ats.configuration_record import config
-from geos_ats import test_steps
+from geos.ats import common_utilities
+from geos.ats.configuration_record import config
+from geos.ats import test_steps
import os
import logging
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
class TestModifier( object ):
diff --git a/geos_ats_package/geos_ats/test_steps.py b/geos-ats/src/geos/ats/test_steps.py
similarity index 99%
rename from geos_ats_package/geos_ats/test_steps.py
rename to geos-ats/src/geos/ats/test_steps.py
index 7eef286a..42691063 100644
--- a/geos_ats_package/geos_ats/test_steps.py
+++ b/geos-ats/src/geos/ats/test_steps.py
@@ -7,11 +7,11 @@
import subprocess
import re
import logging
-from geos_ats import common_utilities, history
-from geos_ats.common_utilities import Error, Log
-from geos_ats.configuration_record import config
+from geos.ats import common_utilities, history
+from geos.ats.common_utilities import Error, Log
+from geos.ats.configuration_record import config
-logger = logging.getLogger( 'geos_ats' )
+logger = logging.getLogger( 'geos-ats' )
def getGeosProblemName( deck, name ):
diff --git a/geos_ats_package/geos_ats/user_utilities.py b/geos-ats/src/geos/ats/user_utilities.py
similarity index 100%
rename from geos_ats_package/geos_ats/user_utilities.py
rename to geos-ats/src/geos/ats/user_utilities.py
diff --git a/geos-mesh/pyproject.toml b/geos-mesh/pyproject.toml
new file mode 100644
index 00000000..a15ceba0
--- /dev/null
+++ b/geos-mesh/pyproject.toml
@@ -0,0 +1,53 @@
+[build-system]
+requires = ["setuptools>=42", "wheel"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "geos-mesh"
+version = "0.0.1"
+description = "GEOS mesh tools"
+authors = [{name = "GEOS Contributors" }]
+maintainers = [
+ {name = "Christopher Sherman", email = "sherman27@llnl.gov"}
+]
+license = {text = "LGPL-2.1"}
+classifiers = [
+ "Development Status :: 4 - Beta",
+ "Programming Language :: Python"
+]
+
+requires-python = ">=3.8"
+
+dependencies = [
+ "vtk >= 9.1",
+ "networkx >= 2.4",
+ "tqdm",
+ "numpy",
+ "meshio>=5.3.2",
+]
+
+[project.scripts]
+ mesh-doctor = "geos.mesh.doctor.mesh_doctor:main"
+ convert_abaqus = "geos.mesh.conversion.main:main"
+
+[project.urls]
+Homepage = "https://github.com/GEOS-DEV/geosPythonPackages"
+Documentation = "https://geosx-geosx.readthedocs-hosted.com/projects/geosx-geospythonpackages/en/latest/"
+Repository = "https://github.com/GEOS-DEV/geosPythonPackages.git"
+"Bug Tracker" = "https://github.com/GEOS-DEV/geosPythonPackages/issues"
+
+[tool.pytest.ini_options]
+addopts = [
+ "--import-mode=importlib",
+]
+pythonpath = [
+ "checks", "parsing",
+]
+
+[tool.mypy]
+python_version = "3.11"
+warn_return_any = true
+warn_unused_configs = true
+ignore_missing_imports = true
+allow_redefinition = true
+plugins = "numpy.typing.mypy_plugin"
diff --git a/geosx_mesh_tools_package/geosx_mesh_tools/__init__.py b/geos-mesh/src/geos/mesh/conversion/__init__.py
similarity index 100%
rename from geosx_mesh_tools_package/geosx_mesh_tools/__init__.py
rename to geos-mesh/src/geos/mesh/conversion/__init__.py
diff --git a/geosx_mesh_tools_package/geosx_mesh_tools/abaqus_converter.py b/geos-mesh/src/geos/mesh/conversion/abaqus_converter.py
similarity index 100%
rename from geosx_mesh_tools_package/geosx_mesh_tools/abaqus_converter.py
rename to geos-mesh/src/geos/mesh/conversion/abaqus_converter.py
diff --git a/geosx_mesh_tools_package/geosx_mesh_tools/main.py b/geos-mesh/src/geos/mesh/conversion/main.py
similarity index 100%
rename from geosx_mesh_tools_package/geosx_mesh_tools/main.py
rename to geos-mesh/src/geos/mesh/conversion/main.py
diff --git a/geosx_mesh_tools_package/geosx_mesh_tools/py.typed b/geos-mesh/src/geos/mesh/conversion/py.typed
similarity index 100%
rename from geosx_mesh_tools_package/geosx_mesh_tools/py.typed
rename to geos-mesh/src/geos/mesh/conversion/py.typed
diff --git a/geosx_mesh_doctor/checks/__init__.py b/geos-mesh/src/geos/mesh/doctor/checks/__init__.py
similarity index 100%
rename from geosx_mesh_doctor/checks/__init__.py
rename to geos-mesh/src/geos/mesh/doctor/checks/__init__.py
diff --git a/geosx_mesh_doctor/checks/check_fractures.py b/geos-mesh/src/geos/mesh/doctor/checks/check_fractures.py
similarity index 100%
rename from geosx_mesh_doctor/checks/check_fractures.py
rename to geos-mesh/src/geos/mesh/doctor/checks/check_fractures.py
diff --git a/geosx_mesh_doctor/checks/collocated_nodes.py b/geos-mesh/src/geos/mesh/doctor/checks/collocated_nodes.py
similarity index 100%
rename from geosx_mesh_doctor/checks/collocated_nodes.py
rename to geos-mesh/src/geos/mesh/doctor/checks/collocated_nodes.py
diff --git a/geosx_mesh_doctor/checks/element_volumes.py b/geos-mesh/src/geos/mesh/doctor/checks/element_volumes.py
similarity index 100%
rename from geosx_mesh_doctor/checks/element_volumes.py
rename to geos-mesh/src/geos/mesh/doctor/checks/element_volumes.py
diff --git a/geosx_mesh_doctor/checks/fix_elements_orderings.py b/geos-mesh/src/geos/mesh/doctor/checks/fix_elements_orderings.py
similarity index 100%
rename from geosx_mesh_doctor/checks/fix_elements_orderings.py
rename to geos-mesh/src/geos/mesh/doctor/checks/fix_elements_orderings.py
diff --git a/geosx_mesh_doctor/checks/generate_cube.py b/geos-mesh/src/geos/mesh/doctor/checks/generate_cube.py
similarity index 100%
rename from geosx_mesh_doctor/checks/generate_cube.py
rename to geos-mesh/src/geos/mesh/doctor/checks/generate_cube.py
diff --git a/geosx_mesh_doctor/checks/generate_fractures.py b/geos-mesh/src/geos/mesh/doctor/checks/generate_fractures.py
similarity index 100%
rename from geosx_mesh_doctor/checks/generate_fractures.py
rename to geos-mesh/src/geos/mesh/doctor/checks/generate_fractures.py
diff --git a/geosx_mesh_doctor/checks/generate_global_ids.py b/geos-mesh/src/geos/mesh/doctor/checks/generate_global_ids.py
similarity index 100%
rename from geosx_mesh_doctor/checks/generate_global_ids.py
rename to geos-mesh/src/geos/mesh/doctor/checks/generate_global_ids.py
diff --git a/geosx_mesh_doctor/checks/non_conformal.py b/geos-mesh/src/geos/mesh/doctor/checks/non_conformal.py
similarity index 100%
rename from geosx_mesh_doctor/checks/non_conformal.py
rename to geos-mesh/src/geos/mesh/doctor/checks/non_conformal.py
diff --git a/geosx_mesh_doctor/checks/reorient_mesh.py b/geos-mesh/src/geos/mesh/doctor/checks/reorient_mesh.py
similarity index 100%
rename from geosx_mesh_doctor/checks/reorient_mesh.py
rename to geos-mesh/src/geos/mesh/doctor/checks/reorient_mesh.py
diff --git a/geosx_mesh_doctor/checks/self_intersecting_elements.py b/geos-mesh/src/geos/mesh/doctor/checks/self_intersecting_elements.py
similarity index 100%
rename from geosx_mesh_doctor/checks/self_intersecting_elements.py
rename to geos-mesh/src/geos/mesh/doctor/checks/self_intersecting_elements.py
diff --git a/geosx_mesh_doctor/checks/supported_elements.py b/geos-mesh/src/geos/mesh/doctor/checks/supported_elements.py
similarity index 100%
rename from geosx_mesh_doctor/checks/supported_elements.py
rename to geos-mesh/src/geos/mesh/doctor/checks/supported_elements.py
diff --git a/geosx_mesh_doctor/checks/triangle_distance.py b/geos-mesh/src/geos/mesh/doctor/checks/triangle_distance.py
similarity index 100%
rename from geosx_mesh_doctor/checks/triangle_distance.py
rename to geos-mesh/src/geos/mesh/doctor/checks/triangle_distance.py
diff --git a/geosx_mesh_doctor/checks/vtk_polyhedron.py b/geos-mesh/src/geos/mesh/doctor/checks/vtk_polyhedron.py
similarity index 100%
rename from geosx_mesh_doctor/checks/vtk_polyhedron.py
rename to geos-mesh/src/geos/mesh/doctor/checks/vtk_polyhedron.py
diff --git a/geosx_mesh_doctor/checks/vtk_utils.py b/geos-mesh/src/geos/mesh/doctor/checks/vtk_utils.py
similarity index 100%
rename from geosx_mesh_doctor/checks/vtk_utils.py
rename to geos-mesh/src/geos/mesh/doctor/checks/vtk_utils.py
diff --git a/geosx_mesh_doctor/mesh_doctor.py b/geos-mesh/src/geos/mesh/doctor/mesh_doctor.py
similarity index 86%
rename from geosx_mesh_doctor/mesh_doctor.py
rename to geos-mesh/src/geos/mesh/doctor/mesh_doctor.py
index 0e652acf..ea1bfe8a 100644
--- a/geosx_mesh_doctor/mesh_doctor.py
+++ b/geos-mesh/src/geos/mesh/doctor/mesh_doctor.py
@@ -9,9 +9,9 @@
import logging
-from parsing import CheckHelper
-from parsing.cli_parsing import parse_and_set_verbosity
-import register
+from geos.mesh.doctor.parsing import CheckHelper
+from geos.mesh.doctor.parsing.cli_parsing import parse_and_set_verbosity
+import geos.mesh.doctor.register as register
def main():
diff --git a/geosx_mesh_doctor/parsing/__init__.py b/geos-mesh/src/geos/mesh/doctor/parsing/__init__.py
similarity index 100%
rename from geosx_mesh_doctor/parsing/__init__.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/__init__.py
diff --git a/geosx_mesh_doctor/parsing/check_fractures_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/check_fractures_parsing.py
similarity index 100%
rename from geosx_mesh_doctor/parsing/check_fractures_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/check_fractures_parsing.py
diff --git a/geosx_mesh_doctor/parsing/cli_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/cli_parsing.py
similarity index 100%
rename from geosx_mesh_doctor/parsing/cli_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/cli_parsing.py
diff --git a/geosx_mesh_doctor/parsing/collocated_nodes_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/collocated_nodes_parsing.py
similarity index 96%
rename from geosx_mesh_doctor/parsing/collocated_nodes_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/collocated_nodes_parsing.py
index fd737a83..7fb84420 100644
--- a/geosx_mesh_doctor/parsing/collocated_nodes_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/collocated_nodes_parsing.py
@@ -5,7 +5,7 @@
List,
)
-from checks.collocated_nodes import Options, Result
+from geos.mesh.doctor.checks.collocated_nodes import Options, Result
from . import COLLOCATES_NODES
diff --git a/geosx_mesh_doctor/parsing/element_volumes_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/element_volumes_parsing.py
similarity index 94%
rename from geosx_mesh_doctor/parsing/element_volumes_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/element_volumes_parsing.py
index 3c126cde..162b9d3c 100644
--- a/geosx_mesh_doctor/parsing/element_volumes_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/element_volumes_parsing.py
@@ -1,6 +1,6 @@
import logging
-from checks.element_volumes import Options, Result
+from geos.mesh.doctor.checks.element_volumes import Options, Result
from . import ELEMENT_VOLUMES
diff --git a/geosx_mesh_doctor/parsing/fix_elements_orderings_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/fix_elements_orderings_parsing.py
similarity index 97%
rename from geosx_mesh_doctor/parsing/fix_elements_orderings_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/fix_elements_orderings_parsing.py
index 7a620067..71fb3a51 100644
--- a/geosx_mesh_doctor/parsing/fix_elements_orderings_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/fix_elements_orderings_parsing.py
@@ -11,7 +11,7 @@
VTK_WEDGE,
)
-from checks.fix_elements_orderings import Options, Result
+from geos.mesh.doctor.checks.fix_elements_orderings import Options, Result
from . import vtk_output_parsing, FIX_ELEMENTS_ORDERINGS
diff --git a/geosx_mesh_doctor/parsing/generate_cube_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/generate_cube_parsing.py
similarity index 98%
rename from geosx_mesh_doctor/parsing/generate_cube_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/generate_cube_parsing.py
index 3c8a17d2..650adf04 100644
--- a/geosx_mesh_doctor/parsing/generate_cube_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/generate_cube_parsing.py
@@ -1,6 +1,6 @@
import logging
-from checks.generate_cube import Options, Result, FieldInfo
+from geos.mesh.doctor.checks.generate_cube import Options, Result, FieldInfo
from . import vtk_output_parsing, generate_global_ids_parsing, GENERATE_CUBE
from .generate_global_ids_parsing import GlobalIdsInfo
diff --git a/geosx_mesh_doctor/parsing/generate_fractures_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/generate_fractures_parsing.py
similarity index 97%
rename from geosx_mesh_doctor/parsing/generate_fractures_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/generate_fractures_parsing.py
index f3840895..9d94b899 100644
--- a/geosx_mesh_doctor/parsing/generate_fractures_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/generate_fractures_parsing.py
@@ -1,6 +1,6 @@
import logging
-from checks.generate_fractures import Options, Result, FracturePolicy
+from geos.mesh.doctor.checks.generate_fractures import Options, Result, FracturePolicy
from . import vtk_output_parsing, GENERATE_FRACTURES
diff --git a/geosx_mesh_doctor/parsing/generate_global_ids_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/generate_global_ids_parsing.py
similarity index 96%
rename from geosx_mesh_doctor/parsing/generate_global_ids_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/generate_global_ids_parsing.py
index 06efd434..43997c67 100644
--- a/geosx_mesh_doctor/parsing/generate_global_ids_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/generate_global_ids_parsing.py
@@ -1,7 +1,7 @@
from dataclasses import dataclass
import logging
-from checks.generate_global_ids import Options, Result
+from geos.mesh.doctor.checks.generate_global_ids import Options, Result
from . import vtk_output_parsing, GENERATE_GLOBAL_IDS
diff --git a/geosx_mesh_doctor/parsing/non_conformal_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/non_conformal_parsing.py
similarity index 96%
rename from geosx_mesh_doctor/parsing/non_conformal_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/non_conformal_parsing.py
index 046c9605..d4aeb46a 100644
--- a/geosx_mesh_doctor/parsing/non_conformal_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/non_conformal_parsing.py
@@ -5,7 +5,7 @@
List,
)
-from checks.non_conformal import Options, Result
+from geos.mesh.doctor.checks.non_conformal import Options, Result
from . import NON_CONFORMAL
diff --git a/geosx_mesh_doctor/parsing/self_intersecting_elements_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/self_intersecting_elements_parsing.py
similarity index 94%
rename from geosx_mesh_doctor/parsing/self_intersecting_elements_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/self_intersecting_elements_parsing.py
index b5c2f545..3f440d93 100644
--- a/geosx_mesh_doctor/parsing/self_intersecting_elements_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/self_intersecting_elements_parsing.py
@@ -2,7 +2,7 @@
import numpy
-from checks.self_intersecting_elements import Options, Result
+from geos.mesh.doctor.checks.self_intersecting_elements import Options, Result
from . import SELF_INTERSECTING_ELEMENTS
diff --git a/geosx_mesh_doctor/parsing/supported_elements_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/supported_elements_parsing.py
similarity index 96%
rename from geosx_mesh_doctor/parsing/supported_elements_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/supported_elements_parsing.py
index b43ae042..fea58f3c 100644
--- a/geosx_mesh_doctor/parsing/supported_elements_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/supported_elements_parsing.py
@@ -1,7 +1,7 @@
import logging
import multiprocessing
-from checks.supported_elements import Options, Result
+from geos.mesh.doctor.checks.supported_elements import Options, Result
from . import SUPPORTED_ELEMENTS
diff --git a/geosx_mesh_doctor/parsing/vtk_output_parsing.py b/geos-mesh/src/geos/mesh/doctor/parsing/vtk_output_parsing.py
similarity index 97%
rename from geosx_mesh_doctor/parsing/vtk_output_parsing.py
rename to geos-mesh/src/geos/mesh/doctor/parsing/vtk_output_parsing.py
index be31037d..8b5d3e8d 100644
--- a/geosx_mesh_doctor/parsing/vtk_output_parsing.py
+++ b/geos-mesh/src/geos/mesh/doctor/parsing/vtk_output_parsing.py
@@ -2,7 +2,7 @@
import logging
import textwrap
-from checks.vtk_utils import VtkOutput
+from geos.mesh.doctor.checks.vtk_utils import VtkOutput
__OUTPUT_FILE = "output"
__OUTPUT_BINARY_MODE = "data-mode"
diff --git a/geosx_mesh_doctor/register.py b/geos-mesh/src/geos/mesh/doctor/register.py
similarity index 90%
rename from geosx_mesh_doctor/register.py
rename to geos-mesh/src/geos/mesh/doctor/register.py
index 1626053b..75e8d486 100644
--- a/geosx_mesh_doctor/register.py
+++ b/geos-mesh/src/geos/mesh/doctor/register.py
@@ -3,20 +3,20 @@
import logging
from typing import Dict, Callable, Any, Tuple
-import parsing
-from parsing import CheckHelper, cli_parsing
+import geos.mesh.doctor.parsing as parsing
+from geos.mesh.doctor.parsing import CheckHelper, cli_parsing
__HELPERS: Dict[ str, Callable[ [ None ], CheckHelper ] ] = dict()
__CHECKS: Dict[ str, Callable[ [ None ], Any ] ] = dict()
def __load_module_check( module_name: str, check_fct="check" ):
- module = importlib.import_module( "checks." + module_name )
+ module = importlib.import_module( "geos.mesh.doctor.checks." + module_name )
return getattr( module, check_fct )
def __load_module_check_helper( module_name: str, parsing_fct_suffix="_parsing" ):
- module = importlib.import_module( "parsing." + module_name + parsing_fct_suffix )
+ module = importlib.import_module( "geos.mesh.doctor.parsing." + module_name + parsing_fct_suffix )
return CheckHelper( fill_subparser=module.fill_subparser,
convert=module.convert,
display_results=module.display_results )
diff --git a/geosx_mesh_doctor/tests/test_cli_parsing.py b/geos-mesh/tests/test_cli_parsing.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_cli_parsing.py
rename to geos-mesh/tests/test_cli_parsing.py
diff --git a/geosx_mesh_doctor/tests/test_collocated_nodes.py b/geos-mesh/tests/test_collocated_nodes.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_collocated_nodes.py
rename to geos-mesh/tests/test_collocated_nodes.py
diff --git a/geosx_mesh_doctor/tests/test_element_volumes.py b/geos-mesh/tests/test_element_volumes.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_element_volumes.py
rename to geos-mesh/tests/test_element_volumes.py
diff --git a/geosx_mesh_doctor/tests/test_generate_cube.py b/geos-mesh/tests/test_generate_cube.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_generate_cube.py
rename to geos-mesh/tests/test_generate_cube.py
diff --git a/geosx_mesh_doctor/tests/test_generate_fractures.py b/geos-mesh/tests/test_generate_fractures.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_generate_fractures.py
rename to geos-mesh/tests/test_generate_fractures.py
diff --git a/geosx_mesh_doctor/tests/test_generate_global_ids.py b/geos-mesh/tests/test_generate_global_ids.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_generate_global_ids.py
rename to geos-mesh/tests/test_generate_global_ids.py
diff --git a/geosx_mesh_doctor/tests/test_non_conformal.py b/geos-mesh/tests/test_non_conformal.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_non_conformal.py
rename to geos-mesh/tests/test_non_conformal.py
diff --git a/geosx_mesh_doctor/tests/test_reorient_mesh.py b/geos-mesh/tests/test_reorient_mesh.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_reorient_mesh.py
rename to geos-mesh/tests/test_reorient_mesh.py
diff --git a/geosx_mesh_doctor/tests/test_self_intersecting_elements.py b/geos-mesh/tests/test_self_intersecting_elements.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_self_intersecting_elements.py
rename to geos-mesh/tests/test_self_intersecting_elements.py
diff --git a/geosx_mesh_doctor/tests/test_supported_elements.py b/geos-mesh/tests/test_supported_elements.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_supported_elements.py
rename to geos-mesh/tests/test_supported_elements.py
diff --git a/geosx_mesh_doctor/tests/test_triangle_distance.py b/geos-mesh/tests/test_triangle_distance.py
similarity index 100%
rename from geosx_mesh_doctor/tests/test_triangle_distance.py
rename to geos-mesh/tests/test_triangle_distance.py
diff --git a/geos-timehistory/pyproject.toml b/geos-timehistory/pyproject.toml
new file mode 100644
index 00000000..ad27bbf6
--- /dev/null
+++ b/geos-timehistory/pyproject.toml
@@ -0,0 +1,33 @@
+[build-system]
+requires = ["setuptools>=42", "wheel"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "geos-timehistory"
+version = "0.1.0"
+description = "Scripts to plot time-series data from GEOSX time-history output files"
+authors = [{name = "GEOS Contributors" }]
+maintainers = [
+ {name = "William Tobin", email = "tobin6@llnl.gov"}
+]
+license = {text = "LGPL-2.1"}
+classifiers = [
+ "Development Status :: 4 - Beta",
+ "Programming Language :: Python"
+]
+
+requires-python = ">=3.6"
+
+dependencies = [
+ "matplotlib",
+ "h5py",
+ "numpy",
+]
+
+[project.scripts]
+ plot-timehistory = "geos.timehistory.plot:main"
+
+[tool.mypy]
+python_version = "3.8"
+warn_return_any = true
+warn_unused_configs = true
diff --git a/timehistory_package/timehistory/__init__.py b/geos-timehistory/src/geos/timehistory/__init__.py
similarity index 100%
rename from timehistory_package/timehistory/__init__.py
rename to geos-timehistory/src/geos/timehistory/__init__.py
diff --git a/timehistory_package/timehistory/plot_time_history.py b/geos-timehistory/src/geos/timehistory/plot_time_history.py
similarity index 97%
rename from timehistory_package/timehistory/plot_time_history.py
rename to geos-timehistory/src/geos/timehistory/plot_time_history.py
index 512c4b11..422d2847 100644
--- a/timehistory_package/timehistory/plot_time_history.py
+++ b/geos-timehistory/src/geos/timehistory/plot_time_history.py
@@ -1,5 +1,5 @@
import numpy as np
-from hdf5_wrapper import hdf5_wrapper as h5w
+from geos.hdf5_wrapper import wrapper as h5w
import matplotlib as mpl
import matplotlib.pyplot as plt
import os
@@ -22,7 +22,7 @@ def getHistorySeries( database, variable, setname, indices=None, components=None
Retrieve a series of time history structures suitable for plotting in addition to the specific set index and component for the time series
Args:
- database (hdf5_wrapper.hdf5_wrapper): database to retrieve time history data from
+ database (geos.hdf5_wrapper.hdf5_wrapper): database to retrieve time history data from
variable (str): the name of the time history variable for which to retrieve time-series data
setname (str): the name of the index set as specified in the geosx input xml for which to query time-series data
indices (int, list): the indices in the named set to query for, if None, defaults to all
diff --git a/geos-xml-tools/pyproject.toml b/geos-xml-tools/pyproject.toml
new file mode 100644
index 00000000..33275bef
--- /dev/null
+++ b/geos-xml-tools/pyproject.toml
@@ -0,0 +1,32 @@
+[build-system]
+requires = ["setuptools>=42", "wheel"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "geos-xml-tools"
+version = "0.6.0"
+description = "Tools for enabling advanced xml features in GEOSX"
+maintainers = [
+ {name = "Christopher Sherman", email = "sherman27@llnl.gov" }
+]
+license = {text = "LGPL-2.1"}
+
+requires-python = ">=3.8"
+
+dependencies = [
+ "lxml>=4.5.0",
+ "parameterized",
+ "numpy"
+]
+
+[project.scripts]
+ preprocess_xml = "geos.xml_tools.main:preprocess_serial"
+ format_xml = "geos.xml_tools.xml_formatter:main"
+ test_geosx_xml_tools = "geos.xml_tools.tests.test_manager:main"
+ check_xml_attribute_coverage = "geos.xml_tools.attribute_coverage:main"
+ check_xml_redundancy = "geos.xml_tools.xml_redundancy_check:main"
+
+[tool.mypy]
+python_version = "3.8"
+warn_return_any = true
+warn_unused_configs = true
diff --git a/geosx_xml_tools_package/geosx_xml_tools/__init__.py b/geos-xml-tools/src/geos/xml_tools/__init__.py
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/__init__.py
rename to geos-xml-tools/src/geos/xml_tools/__init__.py
diff --git a/geosx_xml_tools_package/geosx_xml_tools/attribute_coverage.py b/geos-xml-tools/src/geos/xml_tools/attribute_coverage.py
similarity index 99%
rename from geosx_xml_tools_package/geosx_xml_tools/attribute_coverage.py
rename to geos-xml-tools/src/geos/xml_tools/attribute_coverage.py
index 7f7af99e..806cf68e 100644
--- a/geosx_xml_tools_package/geosx_xml_tools/attribute_coverage.py
+++ b/geos-xml-tools/src/geos/xml_tools/attribute_coverage.py
@@ -2,7 +2,7 @@
import os
from pathlib import Path
from typing import Any, Iterable, Dict
-from geosx_xml_tools import command_line_parsers
+from geos.xml_tools import command_line_parsers
record_type = Dict[ str, Dict[ str, Any ] ]
diff --git a/geosx_xml_tools_package/geosx_xml_tools/command_line_parsers.py b/geos-xml-tools/src/geos/xml_tools/command_line_parsers.py
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/command_line_parsers.py
rename to geos-xml-tools/src/geos/xml_tools/command_line_parsers.py
diff --git a/geosx_xml_tools_package/geosx_xml_tools/main.py b/geos-xml-tools/src/geos/xml_tools/main.py
similarity index 98%
rename from geosx_xml_tools_package/geosx_xml_tools/main.py
rename to geos-xml-tools/src/geos/xml_tools/main.py
index c907cf7e..a5cef1bd 100644
--- a/geosx_xml_tools_package/geosx_xml_tools/main.py
+++ b/geos-xml-tools/src/geos/xml_tools/main.py
@@ -4,7 +4,7 @@
import argparse
import os
import time
-from geosx_xml_tools import xml_processor, command_line_parsers
+from geos.xml_tools import xml_processor, command_line_parsers
from typing import Callable, Any, Union, Tuple, Iterable
diff --git a/geosx_xml_tools_package/geosx_xml_tools/py.typed b/geos-xml-tools/src/geos/xml_tools/py.typed
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/py.typed
rename to geos-xml-tools/src/geos/xml_tools/py.typed
diff --git a/geosx_xml_tools_package/geosx_xml_tools/regex_tools.py b/geos-xml-tools/src/geos/xml_tools/regex_tools.py
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/regex_tools.py
rename to geos-xml-tools/src/geos/xml_tools/regex_tools.py
diff --git a/geosx_xml_tools_package/geosx_xml_tools/table_generator.py b/geos-xml-tools/src/geos/xml_tools/table_generator.py
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/table_generator.py
rename to geos-xml-tools/src/geos/xml_tools/table_generator.py
diff --git a/geosx_xml_tools_package/geosx_xml_tools/tests/__init__.py b/geos-xml-tools/src/geos/xml_tools/tests/__init__.py
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/tests/__init__.py
rename to geos-xml-tools/src/geos/xml_tools/tests/__init__.py
diff --git a/geosx_xml_tools_package/geosx_xml_tools/tests/generate_test_xml.py b/geos-xml-tools/src/geos/xml_tools/tests/generate_test_xml.py
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/tests/generate_test_xml.py
rename to geos-xml-tools/src/geos/xml_tools/tests/generate_test_xml.py
diff --git a/geosx_xml_tools_package/geosx_xml_tools/tests/test_manager.py b/geos-xml-tools/src/geos/xml_tools/tests/test_manager.py
similarity index 100%
rename from geosx_xml_tools_package/geosx_xml_tools/tests/test_manager.py
rename to geos-xml-tools/src/geos/xml_tools/tests/test_manager.py
diff --git a/geosx_xml_tools_package/geosx_xml_tools/unit_manager.py b/geos-xml-tools/src/geos/xml_tools/unit_manager.py
similarity index 99%
rename from geosx_xml_tools_package/geosx_xml_tools/unit_manager.py
rename to geos-xml-tools/src/geos/xml_tools/unit_manager.py
index 4f04fa81..228c505e 100644
--- a/geosx_xml_tools_package/geosx_xml_tools/unit_manager.py
+++ b/geos-xml-tools/src/geos/xml_tools/unit_manager.py
@@ -1,7 +1,7 @@
"""Tools for managing units in GEOSX"""
import re
-from geosx_xml_tools import regex_tools
+from geos.xml_tools import regex_tools
from typing import List, Any, Dict, Union
diff --git a/geosx_xml_tools_package/geosx_xml_tools/xml_formatter.py b/geos-xml-tools/src/geos/xml_tools/xml_formatter.py
similarity index 99%
rename from geosx_xml_tools_package/geosx_xml_tools/xml_formatter.py
rename to geos-xml-tools/src/geos/xml_tools/xml_formatter.py
index 4695e65e..8edfa1e3 100644
--- a/geosx_xml_tools_package/geosx_xml_tools/xml_formatter.py
+++ b/geos-xml-tools/src/geos/xml_tools/xml_formatter.py
@@ -2,7 +2,7 @@
from lxml import etree as ElementTree # type: ignore[import]
import re
from typing import List, Any, TextIO
-from geosx_xml_tools import command_line_parsers
+from geos.xml_tools import command_line_parsers
def format_attribute( attribute_indent: str, ka: str, attribute_value: str ) -> str:
diff --git a/geosx_xml_tools_package/geosx_xml_tools/xml_processor.py b/geos-xml-tools/src/geos/xml_tools/xml_processor.py
similarity index 99%
rename from geosx_xml_tools_package/geosx_xml_tools/xml_processor.py
rename to geos-xml-tools/src/geos/xml_tools/xml_processor.py
index d5a34c35..9795c4b5 100644
--- a/geosx_xml_tools_package/geosx_xml_tools/xml_processor.py
+++ b/geos-xml-tools/src/geos/xml_tools/xml_processor.py
@@ -4,8 +4,8 @@
from lxml.etree import XMLSyntaxError # type: ignore[import]
import re
import os
-from geosx_xml_tools import regex_tools, unit_manager
-from geosx_xml_tools import xml_formatter
+from geos.xml_tools import regex_tools, unit_manager
+from geos.xml_tools import xml_formatter
from typing import Iterable, Tuple, List
# Create an instance of the unit, parameter regex handlers
diff --git a/geosx_xml_tools_package/geosx_xml_tools/xml_redundancy_check.py b/geos-xml-tools/src/geos/xml_tools/xml_redundancy_check.py
similarity index 94%
rename from geosx_xml_tools_package/geosx_xml_tools/xml_redundancy_check.py
rename to geos-xml-tools/src/geos/xml_tools/xml_redundancy_check.py
index f970a6d7..b8141157 100644
--- a/geosx_xml_tools_package/geosx_xml_tools/xml_redundancy_check.py
+++ b/geos-xml-tools/src/geos/xml_tools/xml_redundancy_check.py
@@ -1,9 +1,9 @@
-from geosx_xml_tools.attribute_coverage import parse_schema
-from geosx_xml_tools.xml_formatter import format_file
+from geos.xml_tools.attribute_coverage import parse_schema
+from geos.xml_tools.xml_formatter import format_file
from lxml import etree as ElementTree # type: ignore[import]
import os
from pathlib import Path
-from geosx_xml_tools import command_line_parsers
+from geos.xml_tools import command_line_parsers
from typing import Iterable, Dict, Any
diff --git a/geos_ats_package/pyproject.toml b/geos_ats_package/pyproject.toml
deleted file mode 100644
index 008c8e4a..00000000
--- a/geos_ats_package/pyproject.toml
+++ /dev/null
@@ -1,4 +0,0 @@
-[build-system]
-requires = ["setuptools>=42", "wheel"]
-build-backend = "setuptools.build_meta"
-
diff --git a/geos_ats_package/setup.cfg b/geos_ats_package/setup.cfg
deleted file mode 100644
index 6ee5dde7..00000000
--- a/geos_ats_package/setup.cfg
+++ /dev/null
@@ -1,39 +0,0 @@
-[metadata]
-name = geos_ats
-version = 0.2.0
-description = ATS implementation for GEOS testing
-author = GEOS Contributors
-author_email = sherman27@llnl.gov
-license = LGPL-2.1
-
-[options]
-packages =
- geos_ats
- geos_ats.assets
- geos_ats.helpers
- geos_ats.machines
-install_requires =
- h5py
- mpi4py
- numpy
- lxml
- tabulate
- pyyaml
- tqdm
- requests
- GitPython
- google-cloud-storage
- pip-system-certs
- ats @ https://github.com/LLNL/ATS/archive/refs/tags/7.0.105.tar.gz
-python_requires = >=3.7
-
-[options.package_data]
-* = *.js, *.css, *.zip
-
-[options.entry_points]
-console_scripts =
- run_geos_ats = geos_ats.main:main
- setup_ats_environment = geos_ats.environment_setup:main
- geos_ats_log_check = geos_ats.helpers.log_check:main
- geos_ats_restart_check = geos_ats.helpers.restart_check:main
- geos_ats_curve_check = geos_ats.helpers.curve_check:main
diff --git a/geosx_mesh_doctor/pyproject.toml b/geosx_mesh_doctor/pyproject.toml
deleted file mode 100644
index 20051350..00000000
--- a/geosx_mesh_doctor/pyproject.toml
+++ /dev/null
@@ -1,15 +0,0 @@
-[tool.pytest.ini_options]
-addopts = [
- "--import-mode=importlib",
-]
-pythonpath = [
- "checks", "parsing",
-]
-
-[tool.mypy]
-python_version = "3.11"
-warn_return_any = true
-warn_unused_configs = true
-ignore_missing_imports = true
-allow_redefinition = true
-plugins = "numpy.typing.mypy_plugin"
diff --git a/geosx_mesh_doctor/requirements.txt b/geosx_mesh_doctor/requirements.txt
deleted file mode 100644
index 4c9b1763..00000000
--- a/geosx_mesh_doctor/requirements.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-vtk >= 9.1
-networkx >= 2.4
-tqdm
-numpy
\ No newline at end of file
diff --git a/geosx_mesh_doctor/setup.py b/geosx_mesh_doctor/setup.py
deleted file mode 100644
index dc03ac1d..00000000
--- a/geosx_mesh_doctor/setup.py
+++ /dev/null
@@ -1,3 +0,0 @@
-from setuptools import setup, find_packages
-
-setup( name='mesh_doctor', version='0.0.1', packages=find_packages() )
diff --git a/geosx_mesh_tools_package/pyproject.toml b/geosx_mesh_tools_package/pyproject.toml
deleted file mode 100644
index c2f433af..00000000
--- a/geosx_mesh_tools_package/pyproject.toml
+++ /dev/null
@@ -1,8 +0,0 @@
-[build-system]
-requires = ["setuptools>=42", "wheel"]
-build-backend = "setuptools.build_meta"
-
-[tool.mypy]
-python_version = "3.8"
-warn_return_any = true
-warn_unused_configs = true
diff --git a/geosx_mesh_tools_package/setup.cfg b/geosx_mesh_tools_package/setup.cfg
deleted file mode 100644
index 06ca8c2c..00000000
--- a/geosx_mesh_tools_package/setup.cfg
+++ /dev/null
@@ -1,22 +0,0 @@
-[metadata]
-name = geosx_mesh_tools
-version = 0.2.0
-description = Tools for managing meshes in GEOSX
-author = Christopher Sherman
-author_email = sherman27@llnl.gov
-license = LGPL-2.1
-
-[options]
-packages =
- geosx_mesh_tools
-install_requires =
- meshio>=5.3.2
- numpy
-python_requires = >=3.6
-
-[options.package_data]
-geosx_mesh_tools = py.typed
-
-[options.entry_points]
-console_scripts =
- convert_abaqus = geosx_mesh_tools.main:main
diff --git a/geosx_xml_tools_package/.gitignore b/geosx_xml_tools_package/.gitignore
deleted file mode 100644
index 59d52651..00000000
--- a/geosx_xml_tools_package/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-build
-*.egg-info
diff --git a/geosx_xml_tools_package/pyproject.toml b/geosx_xml_tools_package/pyproject.toml
deleted file mode 100644
index c2f433af..00000000
--- a/geosx_xml_tools_package/pyproject.toml
+++ /dev/null
@@ -1,8 +0,0 @@
-[build-system]
-requires = ["setuptools>=42", "wheel"]
-build-backend = "setuptools.build_meta"
-
-[tool.mypy]
-python_version = "3.8"
-warn_return_any = true
-warn_unused_configs = true
diff --git a/geosx_xml_tools_package/setup.cfg b/geosx_xml_tools_package/setup.cfg
deleted file mode 100644
index b369ca6f..00000000
--- a/geosx_xml_tools_package/setup.cfg
+++ /dev/null
@@ -1,28 +0,0 @@
-[metadata]
-name = geosx_xml_tools
-version = 0.6.0
-description = Tools for enabling advanced xml features in GEOSX
-author = Christopher Sherman
-author_email = sherman27@llnl.gov
-license = LGPL-2.1
-
-[options]
-packages =
- geosx_xml_tools
- geosx_xml_tools.tests
-install_requires =
- lxml>=4.5.0
- parameterized
- numpy
-python_requires = >=3.6
-
-[options.package_data]
-geosx_xml_tools = py.typed
-
-[options.entry_points]
-console_scripts =
- preprocess_xml = geosx_xml_tools.main:preprocess_serial
- format_xml = geosx_xml_tools.xml_formatter:main
- test_geosx_xml_tools = geosx_xml_tools.tests.test_manager:main
- check_xml_attribute_coverage = geosx_xml_tools.attribute_coverage:main
- check_xml_redundancy = geosx_xml_tools.xml_redundancy_check:main
diff --git a/hdf5-wrapper/pyproject.toml b/hdf5-wrapper/pyproject.toml
new file mode 100644
index 00000000..09300ffb
--- /dev/null
+++ b/hdf5-wrapper/pyproject.toml
@@ -0,0 +1,27 @@
+[build-system]
+requires = ["setuptools>=42", "wheel"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "hdf5-wrapper"
+version = "0.2.0"
+description = "Simple wrapper for h5py objects"
+maintainers = [
+ {name = "Christopher Sherman", email = "sherman27@llnl.gov" }
+]
+license = {text = "LGPL-2.1"}
+
+requires-python = ">=3.8"
+
+dependencies = [
+ "h5py>=2.10.0",
+ "numpy>=1.16.2",
+]
+
+[project.scripts]
+ hdf5_wrapper_tests = "geos.hdf5_wrapper.wrapper_tests:main"
+
+[tool.mypy]
+python_version = "3.8"
+warn_return_any = true
+warn_unused_configs = true
diff --git a/hdf5_wrapper_package/hdf5_wrapper/__init__.py b/hdf5-wrapper/src/geos/hdf5_wrapper/__init__.py
similarity index 100%
rename from hdf5_wrapper_package/hdf5_wrapper/__init__.py
rename to hdf5-wrapper/src/geos/hdf5_wrapper/__init__.py
diff --git a/hdf5_wrapper_package/hdf5_wrapper/py.typed b/hdf5-wrapper/src/geos/hdf5_wrapper/py.typed
similarity index 100%
rename from hdf5_wrapper_package/hdf5_wrapper/py.typed
rename to hdf5-wrapper/src/geos/hdf5_wrapper/py.typed
diff --git a/hdf5_wrapper_package/hdf5_wrapper/use_example.py b/hdf5-wrapper/src/geos/hdf5_wrapper/use_example.py
similarity index 82%
rename from hdf5_wrapper_package/hdf5_wrapper/use_example.py
rename to hdf5-wrapper/src/geos/hdf5_wrapper/use_example.py
index 92434514..35425458 100644
--- a/hdf5_wrapper_package/hdf5_wrapper/use_example.py
+++ b/hdf5-wrapper/src/geos/hdf5_wrapper/use_example.py
@@ -1,21 +1,21 @@
import numpy as np
-import hdf5_wrapper
+from geos.hdf5_wrapper import hdf5_wrapper
from typing import Union, Dict
-def print_database_iterative( database: hdf5_wrapper.hdf5_wrapper, level: int = 0 ) -> None:
+def print_database_iterative( database: hdf5_wrapper, level: int = 0 ) -> None:
"""
Print the database targets iteratively by level
Args:
- database (hdf5_wrapper.hdf5_wrapper) the wrapper for the current database
+ database (hdf5_wrapper) the wrapper for the current database
level (int): the depth within the database
"""
# Note: you can also iterate over the hdf5_wrapper object directly
for k in database.keys():
print( '%s%s' % ( ' ' * level, k ) )
- if isinstance( database[ k ], hdf5_wrapper.hdf5_wrapper ):
+ if isinstance( database[ k ], hdf5_wrapper ):
# This is a group, so continue iterating downward
print_database_iterative( database[ k ], level + 1 )
else:
@@ -53,7 +53,7 @@ def read_write_hdf5_database_example() -> None:
# ------------------------
# Write the first piece-by-piece to an hdf5_file
# Note: when you exit the following scope, the database is automatically closed
- with hdf5_wrapper.hdf5_wrapper( 'database_a.hdf5', mode='a' ) as database_a:
+ with hdf5_wrapper( 'database_a.hdf5', mode='a' ) as database_a:
# Assign the two array objects to this level
database_a[ '1D_double_array' ] = source_a[ '1D_double_array' ]
database_a[ 'string_array' ] = source_a[ 'string_array' ]
@@ -63,11 +63,11 @@ def read_write_hdf5_database_example() -> None:
child_a[ '2D_double_array' ] = source_a[ 'child_a' ][ '2D_double_array' ]
# Automatically write the second source to a second database
- with hdf5_wrapper.hdf5_wrapper( 'database_b.hdf5', mode='a' ) as database_b:
+ with hdf5_wrapper( 'database_b.hdf5', mode='a' ) as database_b:
database_b[ '/' ] = source_b
# Create a third database that links the either two
- with hdf5_wrapper.hdf5_wrapper( 'database_c.hdf5', mode='a' ) as database_c:
+ with hdf5_wrapper( 'database_c.hdf5', mode='a' ) as database_c:
database_c.link( 'database_a', 'database_a.hdf5' )
database_c.link( 'database_b', 'database_b.hdf5' )
@@ -75,7 +75,7 @@ def read_write_hdf5_database_example() -> None:
# Read the databases from the filesystem
# ---------------------------------------
print( 'Database contents:' )
- with hdf5_wrapper.hdf5_wrapper( 'database_c.hdf5' ) as database_c:
+ with hdf5_wrapper( 'database_c.hdf5' ) as database_c:
# Iteratively print the database contents
print_database_iterative( database_c, 1 )
diff --git a/hdf5_wrapper_package/hdf5_wrapper/wrapper.py b/hdf5-wrapper/src/geos/hdf5_wrapper/wrapper.py
similarity index 100%
rename from hdf5_wrapper_package/hdf5_wrapper/wrapper.py
rename to hdf5-wrapper/src/geos/hdf5_wrapper/wrapper.py
diff --git a/hdf5_wrapper_package/hdf5_wrapper/wrapper_tests.py b/hdf5-wrapper/src/geos/hdf5_wrapper/wrapper_tests.py
similarity index 73%
rename from hdf5_wrapper_package/hdf5_wrapper/wrapper_tests.py
rename to hdf5-wrapper/src/geos/hdf5_wrapper/wrapper_tests.py
index 8f963df1..0382759b 100644
--- a/hdf5_wrapper_package/hdf5_wrapper/wrapper_tests.py
+++ b/hdf5-wrapper/src/geos/hdf5_wrapper/wrapper_tests.py
@@ -4,7 +4,7 @@
import numpy as np
import random
import string
-import hdf5_wrapper
+from geos.hdf5_wrapper import hdf5_wrapper
def random_string( N ):
@@ -30,7 +30,7 @@ def build_test_dict( depth=0, max_depth=3 ):
# Test the unit manager definitions
-class TestHDF5Wrapper( unittest.TestCase ):
+class Testhdf5_wrapper( unittest.TestCase ):
@classmethod
def setUpClass( cls ):
@@ -52,11 +52,11 @@ def compare_wrapper_dict( self, x, y ):
vx, vy = x[ k ], y[ k ]
tx, ty = type( vx ), type( vy )
- if ( ( tx != ty ) and not ( isinstance( vx, ( dict, hdf5_wrapper.hdf5_wrapper ) )
- and isinstance( vy, ( dict, hdf5_wrapper.hdf5_wrapper ) ) ) ):
+ if ( ( tx != ty )
+ and not ( isinstance( vx, ( dict, hdf5_wrapper ) ) and isinstance( vy, ( dict, hdf5_wrapper ) ) ) ):
self.assertTrue( np.issubdtype( tx, ty ) )
- if isinstance( vx, ( dict, hdf5_wrapper.hdf5_wrapper ) ):
+ if isinstance( vx, ( dict, hdf5_wrapper ) ):
self.compare_wrapper_dict( vx, vy )
else:
if isinstance( vx, np.ndarray ):
@@ -66,40 +66,40 @@ def compare_wrapper_dict( self, x, y ):
self.assertTrue( vx == vy )
def test_a_insert_write( self ):
- data = hdf5_wrapper.hdf5_wrapper( os.path.join( self.test_dir, 'test_insert.hdf5' ), mode='w' )
+ data = hdf5_wrapper( os.path.join( self.test_dir, 'test_insert.hdf5' ), mode='w' )
data.insert( self.test_dict )
def test_b_manual_write( self ):
- data = hdf5_wrapper.hdf5_wrapper( os.path.join( self.test_dir, 'test_manual.hdf5' ), mode='w' )
+ data = hdf5_wrapper( os.path.join( self.test_dir, 'test_manual.hdf5' ), mode='w' )
for k, v in self.test_dict.items():
data[ k ] = v
def test_c_link_write( self ):
- data = hdf5_wrapper.hdf5_wrapper( os.path.join( self.test_dir, 'test_linked.hdf5' ), mode='w' )
+ data = hdf5_wrapper( os.path.join( self.test_dir, 'test_linked.hdf5' ), mode='w' )
for k, v in self.test_dict.items():
if ( 'child' in k ):
child_path = os.path.join( self.test_dir, 'test_%s.hdf5' % ( k ) )
- data_child = hdf5_wrapper.hdf5_wrapper( child_path, mode='w' )
+ data_child = hdf5_wrapper( child_path, mode='w' )
data_child.insert( v )
data.link( k, child_path )
else:
data[ k ] = v
def test_d_compare_wrapper( self ):
- data = hdf5_wrapper.hdf5_wrapper( os.path.join( self.test_dir, 'test_insert.hdf5' ) )
+ data = hdf5_wrapper( os.path.join( self.test_dir, 'test_insert.hdf5' ) )
self.compare_wrapper_dict( self.test_dict, data )
def test_e_compare_wrapper_copy( self ):
- data = hdf5_wrapper.hdf5_wrapper( os.path.join( self.test_dir, 'test_insert.hdf5' ) )
+ data = hdf5_wrapper( os.path.join( self.test_dir, 'test_insert.hdf5' ) )
tmp = data.copy()
self.compare_wrapper_dict( self.test_dict, tmp )
def test_f_compare_wrapper( self ):
- data = hdf5_wrapper.hdf5_wrapper( os.path.join( self.test_dir, 'test_manual.hdf5' ) )
+ data = hdf5_wrapper( os.path.join( self.test_dir, 'test_manual.hdf5' ) )
self.compare_wrapper_dict( self.test_dict, data )
def test_g_compare_wrapper( self ):
- data = hdf5_wrapper.hdf5_wrapper( os.path.join( self.test_dir, 'test_linked.hdf5' ) )
+ data = hdf5_wrapper( os.path.join( self.test_dir, 'test_linked.hdf5' ) )
self.compare_wrapper_dict( self.test_dict, data )
@@ -116,7 +116,7 @@ def main():
args = parser.parse_args()
# Unit manager tests
- suite = unittest.TestLoader().loadTestsFromTestCase( TestHDF5Wrapper )
+ suite = unittest.TestLoader().loadTestsFromTestCase( Testhdf5_wrapper )
unittest.TextTestRunner( verbosity=args.verbose ).run( suite )
diff --git a/hdf5_wrapper_package/pyproject.toml b/hdf5_wrapper_package/pyproject.toml
deleted file mode 100644
index c2f433af..00000000
--- a/hdf5_wrapper_package/pyproject.toml
+++ /dev/null
@@ -1,8 +0,0 @@
-[build-system]
-requires = ["setuptools>=42", "wheel"]
-build-backend = "setuptools.build_meta"
-
-[tool.mypy]
-python_version = "3.8"
-warn_return_any = true
-warn_unused_configs = true
diff --git a/hdf5_wrapper_package/setup.cfg b/hdf5_wrapper_package/setup.cfg
deleted file mode 100644
index 13db52e1..00000000
--- a/hdf5_wrapper_package/setup.cfg
+++ /dev/null
@@ -1,23 +0,0 @@
-[metadata]
-name = hdf5_wrapper
-version = 0.2.0
-description = Simple wrapper for h5py objects
-author = Christopher Sherman
-author_email = sherman27@llnl.gov
-license = LGPL-2.1
-
-[options]
-packages =
- hdf5_wrapper
-install_requires =
- h5py>=2.10.0
- numpy>=1.16.2
-python_requires = >=3.6
-
-[options.package_data]
-hdf5_wrapper = py.typed
-
-[options.entry_points]
-console_scripts =
- hdf5_wrapper_tests = hdf5_wrapper.wrapper_tests:main
-
diff --git a/pygeos-tools/pyproject.toml b/pygeos-tools/pyproject.toml
new file mode 100644
index 00000000..2a6f5dec
--- /dev/null
+++ b/pygeos-tools/pyproject.toml
@@ -0,0 +1,30 @@
+[build-system]
+requires = ["setuptools>=42", "wheel"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "pygeos-tools"
+version = "0.1.0"
+description = "Tools for interacting with pygeosx"
+maintainers = [
+ {name = "Christopher Sherman", email = "sherman27@llnl.gov" }
+]
+license = {text = "LGPL-2.1"}
+classifiers = [
+ "Development Status :: 4 - Beta",
+ "Programming Language :: Python"
+]
+
+requires-python = ">=3.8"
+
+dependencies = [
+ "matplotlib",
+ "numpy",
+ "scipy",
+ "mpi4py",
+]
+
+[tool.mypy]
+python_version = "3.8"
+warn_return_any = true
+warn_unused_configs = true
diff --git a/pygeosx_tools_package/pygeosx_tools/__init__.py b/pygeos-tools/src/geos/pygeos_tools/__init__.py
similarity index 100%
rename from pygeosx_tools_package/pygeosx_tools/__init__.py
rename to pygeos-tools/src/geos/pygeos_tools/__init__.py
diff --git a/pygeosx_tools_package/pygeosx_tools/file_io.py b/pygeos-tools/src/geos/pygeos_tools/file_io.py
similarity index 100%
rename from pygeosx_tools_package/pygeosx_tools/file_io.py
rename to pygeos-tools/src/geos/pygeos_tools/file_io.py
diff --git a/pygeosx_tools_package/pygeosx_tools/mesh_interpolation.py b/pygeos-tools/src/geos/pygeos_tools/mesh_interpolation.py
similarity index 100%
rename from pygeosx_tools_package/pygeosx_tools/mesh_interpolation.py
rename to pygeos-tools/src/geos/pygeos_tools/mesh_interpolation.py
diff --git a/pygeosx_tools_package/pygeosx_tools/py.typed b/pygeos-tools/src/geos/pygeos_tools/py.typed
similarity index 100%
rename from pygeosx_tools_package/pygeosx_tools/py.typed
rename to pygeos-tools/src/geos/pygeos_tools/py.typed
diff --git a/pygeosx_tools_package/pygeosx_tools/well_log.py b/pygeos-tools/src/geos/pygeos_tools/well_log.py
similarity index 100%
rename from pygeosx_tools_package/pygeosx_tools/well_log.py
rename to pygeos-tools/src/geos/pygeos_tools/well_log.py
diff --git a/pygeosx_tools_package/pygeosx_tools/wrapper.py b/pygeos-tools/src/geos/pygeos_tools/wrapper.py
similarity index 100%
rename from pygeosx_tools_package/pygeosx_tools/wrapper.py
rename to pygeos-tools/src/geos/pygeos_tools/wrapper.py
diff --git a/pygeosx_tools_package/pyproject.toml b/pygeosx_tools_package/pyproject.toml
deleted file mode 100644
index c2f433af..00000000
--- a/pygeosx_tools_package/pyproject.toml
+++ /dev/null
@@ -1,8 +0,0 @@
-[build-system]
-requires = ["setuptools>=42", "wheel"]
-build-backend = "setuptools.build_meta"
-
-[tool.mypy]
-python_version = "3.8"
-warn_return_any = true
-warn_unused_configs = true
diff --git a/pygeosx_tools_package/setup.cfg b/pygeosx_tools_package/setup.cfg
deleted file mode 100644
index 4df92e3d..00000000
--- a/pygeosx_tools_package/setup.cfg
+++ /dev/null
@@ -1,20 +0,0 @@
-[metadata]
-name = pygeosx_tools
-version = 0.1.0
-description = Tools for interacting with pygeosx
-author = Christopher Sherman
-author_email = sherman27@llnl.gov
-license = LGPL-2.1
-
-[options]
-packages =
- pygeosx_tools
-install_requires =
- matplotlib
- numpy
- scipy
- mpi4py
-python_requires = >=3.6
-
-[options.package_data]
-pygeosx_tools = py.typed
diff --git a/timehistory_package/pyproject.toml b/timehistory_package/pyproject.toml
deleted file mode 100644
index c2f433af..00000000
--- a/timehistory_package/pyproject.toml
+++ /dev/null
@@ -1,8 +0,0 @@
-[build-system]
-requires = ["setuptools>=42", "wheel"]
-build-backend = "setuptools.build_meta"
-
-[tool.mypy]
-python_version = "3.8"
-warn_return_any = true
-warn_unused_configs = true
diff --git a/timehistory_package/setup.cfg b/timehistory_package/setup.cfg
deleted file mode 100644
index 8201bb1b..00000000
--- a/timehistory_package/setup.cfg
+++ /dev/null
@@ -1,16 +0,0 @@
-[metadata]
-name = time_history_plotting
-version = 0.1.0
-description = Scripts to plot time-series data from GEOSX time-history output files
-author = William Tobin
-author_email = tobin6@llnl.gov
-license = LGPL-2.1
-
-[options]
-packages =
- timehistory
-install_requires =
- matplotlib
- h5py
- numpy
-python_requires = >=3.6