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

[GHA] Speed up PyTorch Layer unit tests #20613

Merged

Conversation

mryzhov
Copy link
Contributor

@mryzhov mryzhov commented Oct 19, 2023

Details:

  • Enabled parallel call of PyTorch Layer tests on Linux
  • Fixed tests to be compatible with pytest-xdist plugin (moved random tensor generation inside the tests )

Tickets:

  • ticket-id

@github-actions github-actions bot added category: CI OpenVINO public CI github_actions Pull requests that update GitHub Actions code category: PyTorch FE OpenVINO PyTorch Frontend category: dependency_changes Pull requests that update a dependency file and removed category: dependency_changes Pull requests that update a dependency file labels Oct 19, 2023
@mryzhov mryzhov changed the title [GHA] Tests xdist fixes [GHA] Speed up PyTorch Layer unit tests Oct 23, 2023
@mryzhov mryzhov marked this pull request as ready for review October 23, 2023 07:13
@mryzhov mryzhov requested review from a team as code owners October 23, 2023 07:13
Copy link
Contributor

@mvafin mvafin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing from np.random.randn to np.random.random_sample is not good. Previously negative numbers were also created, while random_sample create numbers in range [0,1)

tests/layer_tests/pytorch_tests/test_adaptive_avg_pool.py Outdated Show resolved Hide resolved
@mryzhov mryzhov force-pushed the github_actions/pytests_xdist branch from a9c69df to 8a4f20b Compare October 23, 2023 17:43
@mryzhov mryzhov requested a review from mvafin October 24, 2023 09:05
@mryzhov mryzhov requested a review from a team as a code owner October 24, 2023 09:06
@github-actions github-actions bot added the category: dependency_changes Pull requests that update a dependency file label Oct 24, 2023
@mryzhov mryzhov force-pushed the github_actions/pytests_xdist branch from 31c37c4 to 4361c6f Compare October 24, 2023 09:46
@github-actions github-actions bot removed the category: dependency_changes Pull requests that update a dependency file label Oct 24, 2023
Copy link
Contributor

@mvafin mvafin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small comments

tests/layer_tests/pytorch_tests/test_adaptive_avg_pool.py Outdated Show resolved Hide resolved
tests/layer_tests/pytorch_tests/test_all.py Outdated Show resolved Hide resolved
@mryzhov mryzhov force-pushed the github_actions/pytests_xdist branch from cabe848 to 2d38d21 Compare October 26, 2023 08:09
@ilya-lavrenov ilya-lavrenov merged commit 4078bd9 into openvinotoolkit:master Oct 26, 2023
37 of 45 checks passed
alvoron pushed a commit to alvoron/openvino that referenced this pull request Nov 6, 2023
* test

* fixed tests

* typo

* fixed tests

* rest of the tests

* fixed rsub test

* tmp fix

* Revert "tmp fix"

This reverts commit b8bf1e9.

* fixed test params

* reset thirdparty/pugixml

* Revert "fixed rsub test"

This reverts commit 9b6be34.

* fixed typo

* fixed test data

* reset test_rsub

* removed unused param

* reverrted runner

* simplified call

* fixed random

* changed logical to auto mode

* Revert "fixed random"

This reverts commit 8a4f20b.

* fixed test_all

* replaced random_sample with randn

* fixed rebase issue

* reverted logical splitting

* Update tests/layer_tests/pytorch_tests/test_repeat_interleave.py

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* Update tests/layer_tests/pytorch_tests/test_all.py

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* Apply suggestions from code review

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* fixed merge conflict

---------

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>
allnes pushed a commit to allnes/openvino that referenced this pull request Nov 23, 2023
* test

* fixed tests

* typo

* fixed tests

* rest of the tests

* fixed rsub test

* tmp fix

* Revert "tmp fix"

This reverts commit b8bf1e9.

* fixed test params

* reset thirdparty/pugixml

* Revert "fixed rsub test"

This reverts commit 9b6be34.

* fixed typo

* fixed test data

* reset test_rsub

* removed unused param

* reverrted runner

* simplified call

* fixed random

* changed logical to auto mode

* Revert "fixed random"

This reverts commit 8a4f20b.

* fixed test_all

* replaced random_sample with randn

* fixed rebase issue

* reverted logical splitting

* Update tests/layer_tests/pytorch_tests/test_repeat_interleave.py

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* Update tests/layer_tests/pytorch_tests/test_all.py

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* Apply suggestions from code review

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* fixed merge conflict

---------

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>
@mryzhov mryzhov deleted the github_actions/pytests_xdist branch October 10, 2024 08:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: CI OpenVINO public CI category: PyTorch FE OpenVINO PyTorch Frontend github_actions Pull requests that update GitHub Actions code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants