Skip to content

Commit

Permalink
Updating docs, just add some equipment notes and docs are ready
Browse files Browse the repository at this point in the history
  • Loading branch information
Myoldmopar committed Oct 25, 2022
1 parent 5a7272b commit 08ec397
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 29 deletions.
7 changes: 1 addition & 6 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,7 @@ PET as in Parameter Estimation Tool, not a friendly supporter that hangs around
equipment/index
new_component_type
new_unit_type
correction_factor
data_manager
exceptions
runner
units

support_classes

Indices and tables
==================
Expand Down
26 changes: 10 additions & 16 deletions docs/new_component_type.rst
Original file line number Diff line number Diff line change
@@ -1,21 +1,15 @@
Adding a New Component Type
===========================

New component types can be added by following a well-defined series of steps, search for these strings in the code:
If you are ready to dive in and implement a new model type in this tool, here are the steps you should take!

#. Add component string here, the index should match with the SenderType enumeration below
#. Add component index here, should match with the names defined in EquipNames1 above
#. Add unit type array and header string array here
#. Return proper column header strings, they are defined below
#. Return proper column unit array, they are defined below
#. Return proper dry bulb column index, they are defined below
#. Return proper wet bulb column index, they are defined below
#. Add more nodes to the treeview based on the type added
#. Create an instance of this interface, along with a component data structure
#. Add data structure instances here
#. Pass array of data to each component class structure here
#. Generate a new detailed data form here
#. Retrieve detailed data values here
#. Instantiate proper threaded class and information
#. Add more components here, passing in their data structures and setting the Me.Component object
#. Identify the model to be implemented, along with identifying the independent and dependent variables
#. Create a new skeleton derived class from an existing component type inside the ``equipment`` folder
#. Generate example and test data, adding it to the ``examples/`` folder, mimicking the existing structures
#. Add entries to the classes and functions inside ``equipment/equip_types.py``
#. Add an entry to the factory method in ``equipment/manager.py``
#. Fully flesh out the equipment derived class, mimicking patterns and examples in other equipment
#. If there are model curve functions that can be reused by other classes, consider adding them to ``common_curves.py``
#. Add branches and nodes to the main form in the ``_build_treeview`` function in ``forms/main.py``

That's it!
11 changes: 4 additions & 7 deletions docs/new_unit_type.rst
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
Adding a New Unit Type
===========================

New unit types can be added by following a well-defined series of steps, search for these strings in the code:
If you are interested in adding a new unit type (dimension) or a new unit for a given dimension, follow these steps:

#. Need to add catch in here to report if a value is the calculation unit or not
#. Set array holder here
#. Return proper calculation unit
#. Add in unit conversion capabilities
#. Return Base IP unit
#. Return Base SI unit
#. For a new unit type, create a new entry in the ``UnitType`` enum in ``units.py``
#. For a new unit type, create a new derived class that inherits ``BaseValueWithUnit``, mimicking patterns as needed
#. For just a new unit within a given type, just add a new ID to the unit type class, and update the unit string/id/convert functions accordingly
15 changes: 15 additions & 0 deletions docs/support_classes.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
Other Support Modules
=====================

There are also a few modules that are used in many places of the code, that are not forms or equipment.
These are covered here lightly, primarily for developer information.

.. toctree::
:maxdepth: 2
:caption: Contents:

correction_factor
data_manager
exceptions
runner
units

0 comments on commit 08ec397

Please sign in to comment.