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

[Feature Request] Mark as negative tests for minimal CUDA build #21394

Open
poweiw opened this issue Jul 17, 2024 · 5 comments
Open

[Feature Request] Mark as negative tests for minimal CUDA build #21394

poweiw opened this issue Jul 17, 2024 · 5 comments
Labels
ep:CUDA issues related to the CUDA execution provider feature request request for unsupported feature or enhancement

Comments

@poweiw
Copy link
Contributor

poweiw commented Jul 17, 2024

Describe the feature request

Mark tests that are expected to fail in the minimal CUDA build.

Describe scenario use case

Some tests are expected to fail while using the minimal CUDA EP by compiling with -Donnxruntime_CUDA_MINIMAL. Since the CUDA "EP" in result is more of an utility library for memory allocations etc, ops are not expected to run directly with the minimal CUDA EP. Should we mark those tests as negative tests if USE_CUDA_MINIMAL was defined?

Happy to contribute. Thanks!

@poweiw poweiw added the feature request request for unsupported feature or enhancement label Jul 17, 2024
@github-actions github-actions bot added the ep:CUDA issues related to the CUDA execution provider label Jul 17, 2024
@skottmckay
Copy link
Contributor

Typically if you're doing a build with reduced operators the simplest thing to do is use --skip_tests.

I expect the amount of time it would take to track and maintain lists of tests that are expected to pass/fail would far outweigh any benefit. For reference, there are currently over 4,000 tests in onnxruntime_test_all.

@poweiw
Copy link
Contributor Author

poweiw commented Jul 23, 2024

For context we try to build up a pipeline for building/testing onnxruntime, and it could be confusing if we have to check the logs to see if all the failed tests are expected.
Does the normal CUDA EP runs through all 4000 tests?

@skottmckay
Copy link
Contributor

Yes it does.

The majority of tests in onnruntime_test_all loop through all the execution providers that are enabled in the build as they test the individual onnx operators with different input values and different opsets. There are also other things like tests for the optimizers or regression tests that use models from the testdata directory.

@poweiw
Copy link
Contributor Author

poweiw commented Jul 23, 2024

Is it going to be non-trivial to do something like #ifdef USE_CUDA_MINIMAL -> don't run CUDA EP in onnxruntime_test_all? For the minimal cuda build, TRT EP will use utilities in the CUDA EP so they should be reasonably tested in that case as well.

@skottmckay
Copy link
Contributor

You could certainly try adding an ifdef around this line:

Given we do a similar thing for NHWC CUDA ops it doesn't seem unreasonable to use the same approach for a CUDA minimal build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ep:CUDA issues related to the CUDA execution provider feature request request for unsupported feature or enhancement
Projects
None yet
Development

No branches or pull requests

2 participants