Skip to content

Commit c408727

Browse files
committed
Fix documentation issues
Fix various documentation issues like broken formatting and links.
1 parent c17a7cd commit c408727

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+168
-143
lines changed

lib/ramble/docs/conf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -201,8 +201,8 @@ def setup(sphinx):
201201
("py:class", "unittest.case.TestCase"),
202202
("py:class", "_frozen_importlib_external.SourceFileLoader"),
203203
("py:class", "clingo.Control"),
204-
("py:class", "six.moves.urllib.parse.ParseResult"),
205204
("py:class", "TextIO"),
205+
("py:class", "func"),
206206
]
207207

208208
# The reST default role (used for this markup: `text`) to use for all documents.

lib/ramble/docs/configuration_files.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ Upload
213213

214214
Ramble aims to support the upload of experiment outcomes (including FOMs), to
215215
SQL-like datastores. To do this we can specify an ``upload:type`` as defined by
216-
:mod:`ramble.experimental.uploader.Upload`, and a ``upload:uri`` to specify the
216+
:mod:`ramble.experimental.uploader.uploader_types`, and a ``upload:uri`` to specify the
217217
destination.
218218

219219
As part of the upload it tries to attribute the data to a user. This can be
@@ -534,9 +534,9 @@ be searched for when looking for application definitions. Its format is as follo
534534
535535
.. _software-config:
536536

537-
--------------
537+
-----------------
538538
Software Section:
539-
--------------
539+
-----------------
540540

541541
The software config section is used to define package definitions, and software
542542
environments created from those packages. Its format is as follows:

lib/ramble/docs/dev_guides/advanced_topics.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ types supported in Ramble.
2424

2525
.. _ramble-pipelines-and-phases:
2626

27-
------------------------------
27+
-------------------------------
2828
Experiment Pipelines and Phases
29-
------------------------------
29+
-------------------------------
3030

3131
Ramble has a concept of ``pipeline``, which represent full actions that can
3232
be taken on a workspace. Some of the common ``pipelines`` that are used are the

lib/ramble/docs/dev_guides/modifier_dev_guide.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ This guide will provide general steps for creating a new modifier definition fil
2323
**NOTE:** Modifiers are considered a more advanced feature of Ramble. Writing a
2424
new modifier definition file in Ramble largely follows the same workflow as
2525
writing an application definition file, although the intent and behavior are
26-
different. It is recommended that you review :ref:`application-def-guide`
26+
different. It is recommended that you review :ref:`application-dev-guide`
2727
before writing a modifier.
2828

2929
-----------

lib/ramble/docs/dev_guides/package_manager_dev_guide.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ definition file.
2727
Writing a new pcakage manager definition file in Ramble largely follows the
2828
same workflow as writing an application definition file, although the intent
2929
and behavior are different. It is recommended that you review
30-
:ref:`application-def-guide` before writing a modifier.
30+
:ref:`application-dev-guide` before writing a modifier.
3131

3232
-----------
3333
Preparation

lib/ramble/docs/index.rst

+2
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ If you're new to Ramble and want to start using it, see :doc:`getting_started`.
2929
workspace_config
3030
package_managers
3131
success_criteria
32+
results
33+
mirror_config
3234

3335
.. toctree::
3436
:maxdepth: 2
File renamed without changes.

lib/ramble/docs/package_managers.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ determine what packages to install within the resulting virtual environment.
113113
The use of this package manager requires ``pip`` to be installed outside of
114114
Ramble. This happens automatically in several Python installations. For more
115115
information see
116-
`pip's documentation<https://pip.pypa.io/en/stable/installation/>`_.
116+
`pip's documentation <https://pip.pypa.io/en/stable/installation/>`_.
117117

118118
^^^^^^^^^^^^^^^^^^^^^
119119
Spack Package Manager

lib/ramble/docs/requirements.txt

+4-1
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,8 @@ sphinx_rtd_theme
44
sphinxcontrib-programoutput
55
sphinxcontrib-jquery
66
sphinx-copybutton
7-
tdqm
7+
tqdm
88
deprecation
9+
pytest
10+
pandas
11+
matplotlib

lib/ramble/docs/results.rst

+10-10
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
99
.. _workspace:
1010

11-
================
11+
==============
1212
Ramble Results
13-
================
13+
==============
1414

1515
Ramble provides support and tooling around processing results data.
1616

@@ -20,9 +20,9 @@ Most notably, the two supported functionalities are:
2020
* Uploading of stand alone JSON in ramble-output format
2121
* Generation of plots and analysis as part of a report
2222

23-
-------------------
23+
------
2424
Upload
25-
-------------------
25+
------
2626

2727
The ``ramble results upload`` command is used to import experiment results from
2828
a JSON file, and upload them as specified in the upload block of Ramble's
@@ -31,9 +31,9 @@ config file (see :ref:`config documentation<upload-config-option>`).
3131
This can be used for both results from an arbitrary ramble workspace, or for
3232
data that is generated by tools which conform to rambles data schema.
3333

34-
-------------------
34+
------
3535
Report
36-
-------------------
36+
------
3737
The ``ramble results report`` command is experimental functionality that provides
3838
the user a way to generate plots and reports from the output of a workspace.
3939
This output is in the form of individual `png` plots, and a combined `pdf`
@@ -47,9 +47,9 @@ Multiple plot types are supported, to aid in comparison of runs and common tasks
4747
For these plots, common operations are supported such as log axis, data
4848
grouping, and idealized line plotting.
4949

50-
^^^^^^^^^^^^^^^
50+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
5151
Strong and Weak Scaling Plots
52-
^^^^^^^^^^^^^^^
52+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
5353

5454
Activated by either the ``strong-scaling`` or ``weak-scaling`` subcommand, these plots generate a line plot and attempt to annotate idealized scaling based on the data input.
5555

@@ -73,9 +73,9 @@ Another common use case might be to plot data by context (such as in OMB), which
7373
7474
Other compelling options include ``-n`` to normalize the plot y values, or ``--logx``/``--logy`` for log axes.
7575

76-
^^^^^^^^^^^^^^^^^^^
76+
^^^^^^^^^^^^^^^^^^^^^^^^
7777
Comparison and FOM plots
78-
^^^^^^^^^^^^^^^^^^^
78+
^^^^^^^^^^^^^^^^^^^^^^^^
7979

8080
A comparison plot compares a specific FOM across all valid experiments, and generates a bar plot with one bar per experiment. It can be invoked by:
8181

lib/ramble/docs/tutorials/10_using_modifiers.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ experiment run directories to see what changed after applying the ``lscpu``
145145
modifier.
146146

147147
Advanced Modifiers
148-
-----------------
148+
------------------
149149

150150
Some modifiers have additional functionality, which can include requiring
151151
specific software packages to be present. An example of this is the

lib/ramble/docs/tutorials/3_modifying_a_gromacs_experiment.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
option. This file may not be copied, modified, or distributed
77
except according to those terms.
88
9-
.. _modifying_an_experiment_tutorial:
9+
.. _modifying_a_gromacs_experiment_tutorial:
1010

1111
=======================================
1212
3) Modifying A GROMACS Experiment
@@ -203,7 +203,7 @@ This command opens the ``ramble.yaml`` file, along with any ``*.tpl`` files in
203203
the workspace's ``configs`` directory. The root directory of the workspace can
204204
be seen in the ``Location`` attribute output from:
205205

206-
.. code-blocks:: console
206+
.. code-block:: console
207207
208208
$ ramble workspace info
209209

lib/ramble/docs/tutorials/5_changing_your_software_stack.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
option. This file may not be copied, modified, or distributed
77
except according to those terms.
88
9-
.. _modifying_an_experiment_tutorial:
9+
.. _changing_a_software_stack_tutorial:
1010

1111
============================
1212
5) Changing A Software Stack

lib/ramble/docs/tutorials/7_using_zips_and_matrices.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ Your final configuration file should look something like:
165165
.. include:: shared/wrf_execute.rst
166166

167167
**NOTE** Some of these experiments can take a while to execute. Experiments can
168-
be filtered using the :ref:`--where<filter-experiments>`` option to execute the
168+
be filtered using the :ref:`--where <filter-experiments>`` option to execute the
169169
higher scale experiments if desired. To do this, try:
170170

171171
.. code-block:: console

lib/ramble/docs/tutorials/shared/gromacs_workspace.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ contents of ``$RAMBLE_ROOT/examples/basic_gromacs_config.yaml``:
7575
requires ``spack`` is installed and available in your path. Modifications to
7676
the ``package_manager`` variant will change this behavior.
7777

78-
.. literalinclude:: ../../../../examples/basic_gromacs_config.yaml
78+
.. literalinclude:: $RAMBLE_ROOT/examples/basic_gromacs_config.yaml
7979
:language: YAML
8080

8181
Note that specifying compilers that Spack doesn't have installed may take a while.

lib/ramble/docs/workspace_config.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ Variant Control
403403
Within a workspace configuration file, experiments are able to define variants.
404404
Variants are able to manipulate specific aspects of experiments and
405405
applications. More information on these configuration options can be seen in
406-
the :ref:`Variants Configuration Section<variants-config>` documentation. To
406+
the :ref:`Variants Configuration Section <variants-config>` documentation. To
407407
begin with, the only variant that can be specific is the ``package_manager``.
408408

409409
The ``package_manager`` variant is used to define which package manager is used
@@ -806,7 +806,7 @@ This config section is defined in the
806806

807807
Below are examples of using this within a workspace config file.
808808

809-
""""""""""""""""""
809+
810810
Custom Executables
811811
""""""""""""""""""
812812

@@ -831,7 +831,7 @@ The above example creates a custom executable, named ``lscpu`` that will inject
831831
the command ``lscpu`` into the command for an experiment when it is used. It is
832832
important to note that this only creates the executable, and does not use it.
833833

834-
""""""""""""""""""""""""""""
834+
835835
Controlling Executable Order
836836
""""""""""""""""""""""""""""
837837

lib/ramble/ramble/application.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -507,7 +507,7 @@ def build_used_variables(self, workspace):
507507
variables referenced by any of them are tracked properly.
508508
509509
Args:
510-
workspace (Workspace): Workspace to extract templates from
510+
workspace (ramble.workspace.Workspace): Workspace to extract templates from
511511
512512
Returns:
513513
(set): All variable names used by this experiment.

lib/ramble/ramble/cmd/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ def find_workspace_path(args):
298298
args (argparse.Namespace): argparse namespace with command arguments
299299
300300
Returns:
301-
(string): Path to workspace root, or None
301+
(str): Path to workspace root, or None
302302
"""
303303

304304
# treat workspace as a name

lib/ramble/ramble/cmd/common/info.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ def all_object_attributes(obj):
120120
definitions in) and return a list of such attributes.
121121
122122
Returns:
123-
(list) all_attrs: List of all attributes the object contains
123+
(list): List of all attributes the object contains
124124
"""
125125
all_attrs = []
126126
for name in obj_attribute_map:

lib/ramble/ramble/context.py

+5-4
Original file line numberDiff line numberDiff line change
@@ -111,12 +111,13 @@ def create_context_from_dict(context_name, in_dict):
111111
'exclude': {},
112112
'zips': {},
113113
'matrices': {} or [],
114-
'tags': []
115-
'n_repeats': '',
114+
'tags': [],
115+
'n_repeats': ''
116+
}
116117
117118
Args:
118-
context_name: The name of the context (e.g., application name)
119-
in_dict: A dictionary representing the variable definitions
119+
context_name (str): The name of the context (e.g., application name)
120+
in_dict (dict): A dictionary representing the variable definitions
120121
121122
Returns:
122123
Context(object)

lib/ramble/ramble/expander.py

+12-8
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,8 @@ def relative_indices(self, relative_to):
135135
"""Compute node indices relative to another node
136136
137137
Args:
138-
relative_to (node): node to shift current node's indices relative to
138+
relative_to (ExpansionNode): node to shift current node's indices
139+
relative to
139140
140141
Returns:
141142
(tuple) indices of shifted match set
@@ -146,7 +147,8 @@ def add_children(self, children):
146147
"""Add children to this node
147148
148149
Args:
149-
children (node, or list): nodes to adds as children of self
150+
children (ExpansionNode, or list): nodes to adds as children of
151+
self
150152
"""
151153
if isinstance(children, list):
152154
self.children.extend(children)
@@ -173,13 +175,15 @@ def define_value(
173175
174176
Args:
175177
expansion_dict (dict): variable definitions to use for expanding
176-
detected matches
178+
detected matches
177179
allow_passthrough (bool): if true, expansion is allowed to fail. if
178-
false, failed expansion raises an error.
180+
false, failed expansion raises an error.
179181
expansion_func (func): function to use for expansion of nested
180-
variable definitions
181-
evaluation_func (func): function to use for evaluating math of strings
182-
no_expand_vars (set): set of variable names that should never be expanded
182+
variable definitions
183+
evaluation_func (func): function to use for evaluating math of
184+
strings
185+
no_expand_vars (set): set of variable names that should never be
186+
expanded
183187
"""
184188
if no_expand_vars is None:
185189
no_expand_vars = set()
@@ -626,7 +630,7 @@ def evaluate_predicate(self, in_str, extra_vars=None, merge_used_stage: bool = T
626630
extra_vars: Variable definitions to use with highest precedence
627631
628632
Returns:
629-
boolean: True or False, based on the evaluation of in_str
633+
bool: True or False, based on the evaluation of in_str
630634
"""
631635

632636
evaluated = self.expand_var(

0 commit comments

Comments
 (0)