Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft: Naming convention class #149

Merged
merged 16 commits into from
Apr 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
sfe_restart.cfg
flow.*
*sql
reports

*cgns
*ugrid
Expand Down
2 changes: 1 addition & 1 deletion docs/_exts/embed_code.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

from docutils.parsers.rst.directives import unchanged, images

from mphys.doc_utils._utils.docutil import get_source_code, remove_docstrings, \
from mphys.utils.docs._utils.docutil import get_source_code, remove_docstrings, \
remove_initial_empty_lines, replace_asserts_with_prints, \
strip_header, dedent, insert_output_start_stop_indicators, run_code, \
get_skip_output_node, get_interleaved_io_nodes, get_output_block_node, \
Expand Down
2 changes: 1 addition & 1 deletion docs/_exts/embed_compare.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

import sphinx
from docutils.parsers.rst import Directive
from mphys.doc_utils._utils.docutil import get_source_code
from mphys.utils.docs._utils.docutil import get_source_code


class ContentContainerDirective(Directive):
Expand Down
2 changes: 1 addition & 1 deletion docs/basics/model_hierarchy.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ For example, a sonic boom propagator requires the flow solution as an input but

MPhys provides a library of these Scenario groups designed for specific type problems.
See :ref:`scenario_library` for details about specific standardized scenarios.
If a particular multiphysics problem is not covered by the MPhys library, new scenarios and coupling groups can be created by subclassing the :class:`~mphys.mphys_group.MphysGroup`.
If a particular multiphysics problem is not covered by the MPhys library, new scenarios and coupling groups can be created by subclassing the :class:`~mphys.mphys_group.MPhysGroup`.


=================
Expand Down
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
import importlib
from unittest.mock import Mock

from mphys.doc_utils.config_params import MOCK_MODULES
from mphys.doc_utils._utils.patch import do_monkeypatch
from mphys.utils.docs.config_params import MOCK_MODULES
from mphys.utils.docs._utils.patch import do_monkeypatch

# Only mock the ones that don't import.
for mod_name in MOCK_MODULES:
Expand Down
16 changes: 8 additions & 8 deletions docs/developers/mphys_group.rst
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
**************
The MphysGroup
The MPhysGroup
**************

The purpose of the MphysGroup is to implement the mechananics of promoting the MPhys variables by tags.
Subsystems with tagged variables that will be promoted are added with the :func:`~mphys.mphys_group.MphysGroup.mphys_add_subsystem` method.
The purpose of the MPhysGroup is to implement the mechanics of promoting the MPhys variables by tags.
Subsystems with tagged variables that will be promoted are added with the :func:`~mphys.mphys_group.MPhysGroup.mphys_add_subsystem` method.
Subsystems that have variables that should not be promoted can still be added with ``add_subsystem``
The automated promotion of tagged variables is done during the configure phase of OpenMDAO setup.
If you need to use ``configure`` in your CouplingGroup or Scenario group, be sure to call the parent's configure with
``super().configure()``.

The :class:`~mphys.mphys_group.MphysGroup` is the base class of the :ref:`dev_coupling_group` and :ref:`dev_scenario_group`.
While it is important to understand the MphysGroup's :func:`~mphys.mphys_group.MphysGroup.configure` and :func:`~mphys.mphys_group.MphysGroup.mphys_add_subsystem` interactions,
The :class:`~mphys.mphys_group.MPhysGroup` is the base class of the :ref:`dev_coupling_group` and :ref:`dev_scenario_group`.
While it is important to understand the MPhysGroup's :func:`~mphys.mphys_group.MPhysGroup.configure` and :func:`~mphys.mphys_group.MPhysGroup.mphys_add_subsystem` interactions,
any new scenario or coupling group should inherit from :class:`~mphys.scenario.Scenario` and :class:`~mphys.coupling_group.CouplingGroup`.
rather than subclassing MphysGroup directly.
rather than subclassing MPhysGroup directly.

.. automodule:: mphys.mphys_group

.. autoclass:: MphysGroup
.. autoclass:: MPhysGroup
:members:


Expand All @@ -25,5 +25,5 @@ Manual Connection of Variables
==============================

In some instances, the use of automated promotion is not appropriate.
Because the MphysGroup inherits from the standard OpenMDAO group,
Because the MPhysGroup inherits from the standard OpenMDAO group,
subsystems can be added with the standard ``add_subsystem`` method and connected manually.
1 change: 0 additions & 1 deletion examples/aero_only/agard/fun3d/README.md

This file was deleted.

48 changes: 0 additions & 48 deletions examples/aero_only/agard/fun3d/run_fun3d.py

This file was deleted.

1 change: 0 additions & 1 deletion examples/aerostructural/crm9/fun3d_meld_tacs/README.md

This file was deleted.

29 changes: 0 additions & 29 deletions examples/aerostructural/crm9/fun3d_meld_tacs/input.cfg

This file was deleted.

91 changes: 0 additions & 91 deletions examples/aerostructural/crm9/fun3d_meld_tacs/mphys_analysis.py

This file was deleted.

91 changes: 0 additions & 91 deletions examples/aerostructural/crm9/fun3d_meld_tacs/sfe.cfg

This file was deleted.

Loading
Loading