mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-21 05:34:18 +08:00
[Openreg][PrivateUse1] Enable CI for openreg (#151007)
Changes: - move test_openreg.py from test/cpp_extensions/open_registration_extension/ to test/ - update README.md for openreg - enable CI Pull Request resolved: https://github.com/pytorch/pytorch/pull/151007 Approved by: https://github.com/albanD
This commit is contained in:
@ -268,6 +268,7 @@ RUN_PARALLEL_BLOCKLIST = [
|
||||
"test_multiprocessing",
|
||||
"test_multiprocessing_spawn",
|
||||
"test_namedtuple_return_api",
|
||||
"test_openreg",
|
||||
"test_overrides",
|
||||
"test_show_pickle",
|
||||
"test_tensorexpr",
|
||||
@ -1222,6 +1223,7 @@ CUSTOM_HANDLERS = {
|
||||
"test_autoload_enable": test_autoload_enable,
|
||||
"test_autoload_disable": test_autoload_disable,
|
||||
"test_cpp_extensions_open_device_registration": run_test_with_openreg,
|
||||
"test_openreg": run_test_with_openreg,
|
||||
"test_transformers_privateuse1": run_test_with_openreg,
|
||||
}
|
||||
|
||||
@ -1512,10 +1514,14 @@ def get_selected_tests(options) -> list[str]:
|
||||
|
||||
# Filter to only run functorch tests when --functorch option is specified
|
||||
if options.functorch:
|
||||
selected_tests = [tname for tname in selected_tests if tname in FUNCTORCH_TESTS]
|
||||
selected_tests = list(
|
||||
filter(lambda test_name: test_name in FUNCTORCH_TESTS, selected_tests)
|
||||
)
|
||||
|
||||
if options.cpp:
|
||||
selected_tests = [tname for tname in selected_tests if tname in CPP_TESTS]
|
||||
selected_tests = list(
|
||||
filter(lambda test_name: test_name in CPP_TESTS, selected_tests)
|
||||
)
|
||||
else:
|
||||
# Exclude all C++ tests otherwise as they are still handled differently
|
||||
# than Python test at the moment
|
||||
|
Reference in New Issue
Block a user