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

fix the links in sphinx docs #217

Merged
merged 2 commits into from
Nov 14, 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
4 changes: 2 additions & 2 deletions Doc/sphinx/source/covariance.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ Covariance
==========

This module contains the covariance objetcs which Mach3 uses to deal with systematic parameters. It also includes
the :py:class:`pyMaCh3.covariance.CovarianceBase` class which you can use to implement your own!
the :py:class:`pyMaCh3._pyMaCh3.covariance.CovarianceBase` class which you can use to implement your own!

.. automodapi:: pyMaCh3.covariance
.. automodapi:: pyMaCh3._pyMaCh3.covariance
:members:
:undoc-members:
:show-inheritance:
4 changes: 2 additions & 2 deletions Doc/sphinx/source/fitter.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ Fitter
======

This module contains the various MaCh3 fitter algorithms which are available, as well as
the :py:class:`pyMaCh3.fitter.FitterBase` class which you can use to implement your own!
the :py:class:`pyMaCh3._pyMaCh3.fitter.FitterBase` class which you can use to implement your own!

.. automodapi:: pyMaCh3.fitter
.. automodapi:: pyMaCh3._pyMaCh3.fitter
:members:
:undoc-members:
:show-inheritance:
4 changes: 2 additions & 2 deletions Doc/sphinx/source/manager.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Manager
=======

This module handles the high level stuff like config options and YAML stuff. The main class is the :py:class:`pyMaCh3.manager.Manager` class. \
This module handles the high level stuff like config options and YAML stuff. The main class is the :py:class:`pyMaCh3._pyMaCh3.manager.Manager` class. \
You can read more about the manager and config files on `the wiki page <https://github.com/mach3-software/MaCh3/wiki/01.-Manager-and-config-handling>`_. \
YAML stuff works essentially the same as in the c++ version but with some caveats.
The main difference is that in the python version, the way that you access the actual data of a yaml node is different due to the way the python binding of the c++ code works.
Expand Down Expand Up @@ -45,7 +45,7 @@ Parsing arrays can be made a bit less painful using list comprehension ::
str_list = [i.data() for i in node['StrArray']]


.. automodapi:: pyMaCh3.manager
.. automodapi:: pyMaCh3._pyMaCh3.manager
:members:
:undoc-members:
:show-inheritance:
4 changes: 2 additions & 2 deletions Doc/sphinx/source/plotting.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ plotting

The plotting module can be used to make beautiful plots. See the `plotting wiki page <https://github.com/mach3-software/MaCh3/wiki/15.-Plotting>`_ for information on how to configure the plotting library to work with your MaCh3 output files and other non-MaCh3 based fitters so you can compare results.

The main class to worry about is :py:class:`pyMaCh3.plotting.PlottingManager` which provides the
The main class to worry about is :py:class:`pyMaCh3._pyMaCh3.plotting.PlottingManager` which provides the
high level functionality and gives you access to everything else you should need.

To use this in your plotting script simply do ::
Expand All @@ -22,7 +22,7 @@ To use this in your plotting script simply do ::



.. automodapi:: pyMaCh3.plotting
.. automodapi:: pyMaCh3._pyMaCh3.plotting
:members:
:undoc-members:
:show-inheritance:
4 changes: 2 additions & 2 deletions Doc/sphinx/source/sample-pdf.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ Sample PDF
This module deals with sampling from the posterior density function of your
particular experimental model at different points, given your data.

In order to do this, you will generally need to create a SamplePDF object derived from :py:class:`pyMaCh3.fitter.SamplePDFFDBase`
In order to do this, you will generally need to create a SamplePDF object derived from :py:class:`pyMaCh3._pyMaCh3.fitter.SamplePDFFDBase`
for each sample of events for your experiment. For some more details on this you can see `the wiki page <https://github.com/mach3-software/MaCh3/wiki/04.-Making-a-samplePDF-experiment-class>`_ on this.
The code examples there are written using c++ however the general ideas are the same.
Happy sampling!

.. automodapi:: pyMaCh3.sample_pdf
.. automodapi:: pyMaCh3._pyMaCh3.sample_pdf
:members:
:undoc-members:
:show-inheritance:
10 changes: 5 additions & 5 deletions Doc/sphinx/source/splines.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ Splines

This module provides the utility for dealing with spline parameters. For some background reading se the `Splines wiki page <https://github.com/mach3-software/MaCh3/wiki/05.-Splines>`_.

The main class which represents individual spline functions is :py:class:`pyMaCh3.splines.ResponseFunction`.
The main class which represents individual spline functions is :py:class:`pyMaCh3._pyMaCh3.splines.ResponseFunction`.
This is an abstract representation which covers multiple different types of interpolation, where the type of interpolation is specified at the time of construction.
The available interpolation types are defined by :py:class:`pyMaCh3.splines.InterpolationType`. Here are some examples
The available interpolation types are defined by :py:class:`pyMaCh3._pyMaCh3.splines.InterpolationType`. Here are some examples

.. image:: spline-examples.png
:width: 400
Expand All @@ -21,7 +21,7 @@ To construct a ResponseFunction you must specify the x and y positions of the kn
TSpline3_response_2 = splines.ResponseFunction([0.0, 1.0, 2.0], [2.0, 3.0, 0.0], splines.InterpolationType.Cubic_TSpline3)
linear_response_2 = splines.ResponseFunction([10.0, 11.0, 12.0], [3.0, 0.0, 4.5], splines.InterpolationType.Linear)

Another important part of this module is the :py:class:`pyMaCh3.splines.EventSplineMonolith` class which allows you to easily and speedily deal with event-by-event splines in your analysis.
Another important part of this module is the :py:class:`pyMaCh3._pyMaCh3.splines.EventSplineMonolith` class which allows you to easily and speedily deal with event-by-event splines in your analysis.
To build this you first need to construct a response function for each event-by-event spline parameter for each of your events as in the example above.

Let's take those example responses and build a simple EventSplineMonolith::
Expand All @@ -30,7 +30,7 @@ Let's take those example responses and build a simple EventSplineMonolith::

This will create an EventSplineMonolith which can deal with the reweighting of two events with two spline parameters.
We now need to be able to set the values of the parameters so that we can calculate event weights.
This is done using the :py:func:`pyMaCh3.splines.EventSplineMonolith.set_param_value_array` function.
This is done using the :py:func:`pyMaCh3._pyMaCh3.splines.EventSplineMonolith.set_param_value_array` function.
This allows us to bind a numpy array to our EventSplineMonolith, whose values we can change, and this will set the values of the parameters inside of the monolith.
This works as follows::

Expand Down Expand Up @@ -62,7 +62,7 @@ This works as follows::

Happy splining!

.. automodapi:: pyMaCh3.splines
.. automodapi:: pyMaCh3._pyMaCh3.splines
:members:
:undoc-members:
:show-inheritance: