Skip to content

Commit

Permalink
Merge branch 'master' into Migrate-Label-for-M1-Runners
Browse files Browse the repository at this point in the history
  • Loading branch information
vfdev-5 committed Feb 5, 2024
2 parents 22810e4 + 77906da commit cd83ec6
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/triage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
steps:
- name: Pull Request Labeler
# if: github.event_name == 'pull_request_target'
uses: actions/labeler@v3
uses: actions/labeler@v5
with:
configuration-path: .github/pr-labeler-config.yml
repo-token: "${{ secrets.GITHUB_TOKEN }}"
Expand Down
2 changes: 1 addition & 1 deletion ignite/distributed/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ def train_fn(local_rank, a, b, c, d=12):
idist.spawn("xla-tpu", train_fn, args=(a, b, c), kwargs_dict={"d": 23}, nproc_per_node=8)
.. _dist.init_process_group: https://pytorch.org/docs/stable/distributed.html#torch.distributed.init_process_group
.. _mp.start_processes: https://pytorch.org/docs/stable/multiprocessing.html#torch.multiprocessing.spawn
.. _mp.start_processes: https://pytorch.org/docs/stable/multiprocessing.html#torch.multiprocessing.spawn.spawn
.. _xmp.spawn: https://pytorch.org/xla/release/1.6/index.html#torch_xla.distributed.xla_multiprocessing.spawn
.. _hvd_run: https://horovod.readthedocs.io/en/latest/api.html#module-horovod.run
Expand Down
8 changes: 5 additions & 3 deletions tests/ignite/engine/test_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -639,7 +639,7 @@ def limited_data_iterator():
self._test_check_triggered_events(limited_data_iterator(), max_epochs=1, epoch_length=100, exp_iter_stops=0)
self._test_check_triggered_events(limited_data_iterator(), max_epochs=10, epoch_length=10, exp_iter_stops=0)

# These tests will fail
# These tests should fail
with pytest.raises(AssertionError):
with pytest.warns(UserWarning, match=r"Data iterator can not provide data anymore"):
self._test_check_triggered_events(limited_data_iterator(), max_epochs=3, epoch_length=100)
Expand All @@ -649,8 +649,10 @@ def limited_data_iterator():
self._test_check_triggered_events(limited_data_iterator(), max_epochs=3, epoch_length=75)

with pytest.raises(AssertionError):
with pytest.warns(UserWarning, match=r"Data iterator can not provide data anymore"):
self._test_check_triggered_events(limited_data_iterator(), max_epochs=1, epoch_length=101)
# Below test does not raise "Data iterator can not provide data anymore" warning as the last
# epoch is equal max_epochs
# with pytest.warns(UserWarning, match=r"Data iterator can not provide data anymore"):
self._test_check_triggered_events(limited_data_iterator(), max_epochs=1, epoch_length=101)

def test_run_check_triggered_events_on_iterator(self):
self._test_run_check_triggered_events_on_iterator()
Expand Down

0 comments on commit cd83ec6

Please sign in to comment.