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

[CI] Migrate from sphinx.ext.doctest to pytest-sphinx #35286

Merged
merged 102 commits into from
May 30, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
5984f1e
Rename `"model_state_dict"` to `"model"`
bveeramani Nov 22, 2022
8f58490
Revert "Rename `"model_state_dict"` to `"model"`"
bveeramani Nov 22, 2022
63432eb
Merge remote-tracking branch 'upstream/master'
bveeramani Dec 5, 2022
2c33947
Merge remote-tracking branch 'upstream/master'
bveeramani Dec 6, 2022
89694a0
Merge remote-tracking branch 'upstream/master'
bveeramani Dec 19, 2022
fe60ca3
Merge remote-tracking branch 'upstream/master'
bveeramani Dec 27, 2022
d45ae9a
Merge remote-tracking branch 'upstream/master'
bveeramani Jan 2, 2023
c703dfc
Merge remote-tracking branch 'upstream/master'
bveeramani Jan 6, 2023
81dd25c
Merge remote-tracking branch 'upstream/master'
bveeramani Jan 19, 2023
fba788e
Merge remote-tracking branch 'upstream/master'
bveeramani Jan 24, 2023
de05655
Update annotations.py
bveeramani Jan 26, 2023
fd2ff91
Revert "Update annotations.py"
bveeramani Jan 26, 2023
7c3ac36
Merge remote-tracking branch 'upstream/master'
bveeramani Feb 14, 2023
9c7b546
Merge remote-tracking branch 'upstream/master'
bveeramani Feb 28, 2023
9d7a15f
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 2, 2023
4f02efe
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 2, 2023
46f43d9
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 6, 2023
a644307
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 10, 2023
e5d0bf1
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 20, 2023
fe7286c
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 21, 2023
51b3a09
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 24, 2023
79f8be9
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 28, 2023
53bede6
Merge remote-tracking branch 'upstream/master'
bveeramani Mar 28, 2023
7cec6e3
Merge remote-tracking branch 'upstream/master'
bveeramani Apr 10, 2023
9407930
Merge remote-tracking branch 'upstream/master'
bveeramani Apr 17, 2023
67ae591
Merge remote-tracking branch 'upstream/master'
bveeramani Apr 18, 2023
93414b8
Merge remote-tracking branch 'upstream/master'
bveeramani May 1, 2023
fcfa9a5
Merge remote-tracking branch 'upstream/master'
bveeramani May 2, 2023
fbfe52d
Merge remote-tracking branch 'upstream/master'
bveeramani May 3, 2023
16132de
Merge remote-tracking branch 'upstream/master'
bveeramani May 10, 2023
4302db7
Merge remote-tracking branch 'upstream/master'
bveeramani May 12, 2023
13025f8
Initial commit
bveeramani May 12, 2023
1f0856a
Update files
bveeramani May 12, 2023
8f3f734
Update files
bveeramani May 12, 2023
450dedf
Update files
bveeramani May 12, 2023
da32cc6
Update stuff
bveeramani May 12, 2023
89ed612
Update files
bveeramani May 12, 2023
a9ac162
Update style
bveeramani May 12, 2023
4d49627
Update pipeline.build.yml
bveeramani May 12, 2023
6d4d9b8
Update pipeline.build.yml
bveeramani May 12, 2023
9c876d3
Update python.bzl
bveeramani May 12, 2023
601bd32
Add `pytest-sphinx` dependency
bveeramani May 12, 2023
22e25f9
Update pipeline
bveeramani May 12, 2023
7633cf4
Remove env
bveeramani May 12, 2023
165d7de
Update filters
bveeramani May 12, 2023
d8fcc6b
Update pytest_wrapper.py
bveeramani May 12, 2023
c05fe1c
Update pipeline.gpu.yml
bveeramani May 12, 2023
9f8695a
Update filters
bveeramani May 12, 2023
889286d
Update env
bveeramani May 12, 2023
65f9e04
Update step
bveeramani May 12, 2023
65fd83f
Update pipelines
bveeramani May 13, 2023
fcc1d7c
Update pipeline.gpu_large.yml
bveeramani May 13, 2023
dd69206
Update pipeline.gpu_large.yml
bveeramani May 13, 2023
ce56268
Merge remote-tracking branch 'upstream/master'
bveeramani May 15, 2023
09da6e1
Update pipelines
bveeramani May 15, 2023
9428afd
Merge remote-tracking branch 'upstream/master' into doctest-test
bveeramani May 15, 2023
7ac7203
Merge remote-tracking branch 'upstream/master'
bveeramani May 16, 2023
a2679e8
Remove mock package
bveeramani May 19, 2023
c18dae2
Update pipelines
bveeramani May 19, 2023
a9406a3
Update files
bveeramani May 19, 2023
7661e30
Update pipeline.ml.yml
bveeramani May 19, 2023
5fac19f
Delete BUIL
bveeramani May 19, 2023
cd2d66d
Merge remote-tracking branch 'upstream/master'
bveeramani May 19, 2023
b2f0cf8
Merge branch 'master' into doctest-test
bveeramani May 19, 2023
4bb1507
Fix stuff
bveeramani May 19, 2023
c75a44f
Fix stuff
bveeramani May 19, 2023
4c37349
Fix stuff
bveeramani May 19, 2023
4508711
Update BUILD
bveeramani May 19, 2023
7930ac3
Update
bveeramani May 23, 2023
21eb373
Fix stuff
bveeramani May 23, 2023
6c54a1d
Fix stuff
bveeramani May 23, 2023
0b45445
Fix stuff
bveeramani May 23, 2023
5def728
Update files
bveeramani May 23, 2023
2e4052a
Update files
bveeramani May 23, 2023
52280e8
Fix stuff
bveeramani May 23, 2023
926e821
Fix stuff
bveeramani May 23, 2023
ea3d9d1
Update stuff
bveeramani May 24, 2023
1af1a07
Update lightning_predictor.py
bveeramani May 24, 2023
325f9f5
Add GPU tests
bveeramani May 24, 2023
fd2fe99
Update BUILD
bveeramani May 24, 2023
cee5bf7
Fix stuff
bveeramani May 24, 2023
87b82b2
Update BUILD
bveeramani May 24, 2023
bc0539a
Update BUILD
bveeramani May 25, 2023
768a3e0
Fix stuff
bveeramani May 25, 2023
19918ae
Update debug.py
bveeramani May 25, 2023
44696c3
Initial commit
bveeramani May 26, 2023
470730e
Merge remote-tracking branch 'upstream/master' into doctest-test
bveeramani May 26, 2023
f816ed8
Undo some changes
bveeramani May 26, 2023
9689c6e
Merge branch 'train-docstrings' into doctest-test
bveeramani May 26, 2023
81bacbf
Merge branch 'util-doctest' into doctest-test
bveeramani May 26, 2023
e46a389
Clean up stuff
bveeramani May 26, 2023
a615556
Merge remote-tracking branch 'upstream/master' into doctest-test
bveeramani May 26, 2023
80df9c2
Update torch_detection_predictor.py
bveeramani May 26, 2023
4b640fb
Update torch_detection_predictor.py
bveeramani May 26, 2023
de82043
Merge branch 'fix-detection-func' into doctest-test
bveeramani May 26, 2023
9c685c4
Update GPU tests
bveeramani May 26, 2023
3b0eea7
Re-add flaky tests
bveeramani May 26, 2023
bd2a9cf
Update cli-sdk.rst
bveeramani May 26, 2023
732362f
Minor fix
bveeramani May 26, 2023
5bd2efd
Update tensorflow_trainer.py
bveeramani May 26, 2023
118f224
Address review comments
bveeramani May 27, 2023
87cd7cc
Merge remote-tracking branch 'upstream/master' into doctest-test
bveeramani May 27, 2023
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
Prev Previous commit
Next Next commit
Initial commit
Signed-off-by: Balaji Veeramani <balaji@anyscale.com>
  • Loading branch information
bveeramani committed May 26, 2023
commit 44696c3d555e9c917635e67928ad6a06b828dde8
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ def train_loop_per_worker():
It is tested with ``accelerate==0.17.1``.

Example:
.. testcode::
.. code-block:: python

import torch
import torch.nn as nn
Expand Down Expand Up @@ -225,12 +225,6 @@ def train_loop_per_worker():
# Assert loss is less 0.09
assert best_checkpoint_loss <= 0.09

.. testoutput::
:hide:
:options: +ELLIPSIS

...

Args:
train_loop_per_worker: The training function to execute.
This can either take in no arguments or a ``config`` dict.
Expand Down
7 changes: 1 addition & 6 deletions python/ray/train/lightning/lightning_predictor.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class LightningPredictor(TorchPredictor):
"""A predictor for PyTorch Lightning modules.

Example:
.. testcode:: python
.. testcode::

import torch
import numpy as np
Expand Down Expand Up @@ -55,11 +55,6 @@ def configure_optimizers(self):

assert output["predictions"].shape == (batch_size, output_dim)


.. testoutput::
:hide:
:options: +ELLIPSIS

Args:
model: The PyTorch Lightning module to use for predictions.
preprocessor: A preprocessor used to transform data batches prior
Expand Down
8 changes: 1 addition & 7 deletions python/ray/train/lightning/lightning_trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ class LightningTrainer(TorchTrainer):
run ``pytorch_lightning.Trainer.fit``.

Example:
.. testcode::
.. code-block:: python

import torch
import torch.nn.functional as F
Expand Down Expand Up @@ -326,12 +326,6 @@ def configure_optimizers(self):
result = trainer.fit()
result

.. testoutput::
:hide:
:options: +ELLIPSIS

...

Args:
lightning_config: Configuration for setting up the Pytorch Lightning Trainer.
You can setup the configurations with ``LightningConfigBuilder``, and
Expand Down
8 changes: 1 addition & 7 deletions python/ray/train/tensorflow/tensorflow_trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def train_loop_per_worker():

Example:

.. testcode::
.. code-block:: python

import tensorflow as tf

Expand Down Expand Up @@ -137,12 +137,6 @@ def train_loop_per_worker(config):
)
result = trainer.fit()

.. testoutput::
:hide:
:options: +ELLIPSIS

...

Args:
train_loop_per_worker: The training function to execute.
This can either take in no arguments or a ``config`` dict.
Expand Down
8 changes: 1 addition & 7 deletions python/ray/train/torch/torch_trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ def train_func():

Example:

.. testcode::
.. code-block:: python

import torch
import torch.nn as nn
Expand Down Expand Up @@ -229,12 +229,6 @@ def train_loop_per_worker():
# Assert loss is less 0.09
assert best_checkpoint_loss <= 0.09 # doctest: +SKIP

.. testoutput::
:hide:
:options: +ELLIPSIS

...

Args:

train_loop_per_worker: The training function to execute.
Expand Down