Skip to content

Commit d1ae9b1

Browse files
authored
Merge pull request #162 from mrava87/doc-benchmark
doc: added benchmark to doc
2 parents 7f0b01e + 7308475 commit d1ae9b1

File tree

5 files changed

+13
-4
lines changed

5 files changed

+13
-4
lines changed

docs/source/api/index.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,9 +118,11 @@ Utils
118118
local_split
119119

120120

121-
.. currentmodule:: pylops_mpi.utils.dottest
121+
.. currentmodule:: pylops_mpi.utils
122122

123123
.. autosummary::
124124
:toctree: generated/
125125

126-
dottest
126+
dottest
127+
benchmark
128+
mark

docs/source/benchmarking.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
.. _benchmarkutility:
22

3-
Benchmark Utility in PyLops-MPI
4-
===============================
3+
Benchmarking
4+
============
5+
56
PyLops-MPI users can convenienly benchmark the performance of their code with a simple decorator.
67
:py:func:`pylops_mpi.utils.benchmark` and :py:func:`pylops_mpi.utils.mark` support various
78
function calling patterns that may arise when benchmarking distributed code.

docs/source/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ class and implementing the ``_matvec`` and ``_rmatvec``.
7676
self
7777
installation.rst
7878
gpu.rst
79+
benchmarking.rst
7980

8081
.. toctree::
8182
:maxdepth: 2

pylops_mpi/utils/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# isort: skip_file
22

3+
from .benchmark import *
34
from .dottest import *
45
from .deps import *

pylops_mpi/utils/benchmark.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
__all__ = ["benchmark",
2+
"mark",
3+
]
4+
15
import functools
26
import logging
37
import os

0 commit comments

Comments
 (0)