anirudh2290 commented on a change in pull request #11630: [WIP] Fix flaky test 
test_deconvolution
URL: https://github.com/apache/incubator-mxnet/pull/11630#discussion_r201805255
 
 

 ##########
 File path: tests/python/unittest/common.py
 ##########
 @@ -94,6 +95,23 @@ def random_seed(seed=None):
         random.seed(next_seed)
 
 
+def assert_raises_cudnn_disabled(assertion_error=False):
+    def test_helper(orig_test):
+        @make_decorator(orig_test)
+        def test_new(*args, **kwargs):
+            cudnn_disabled = (os.getenv('CUDNN_DISABLED') == "ON")
+            if not cudnn_disabled or mx.context.current_context().device_type 
== 'cpu':
+                orig_test(*args, **kwargs)
+            else:
+                if assertion_error:
 
 Review comment:
   yep the issue was uncovered as part of the PR and is documented here: 
https://github.com/apache/incubator-mxnet/issues/11568 . As I have mentioned in 
#11470, this is not something we should be blocking the PR for. This issue 
seems could have been there for a long time. Its possible that there are user 
codes depending on the buggy behavior and raising an exception would be a 
breaking change for these users. Its better to fix the issue with cudnn enabled 
rather than throwing an exception saying cudnn not supported atleast for 1.3.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to