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

fixes integration test #4368

Closed
wants to merge 0 commits into from
Closed

fixes integration test #4368

wants to merge 0 commits into from

Conversation

wyli
Copy link
Contributor

@wyli wyli commented May 27, 2022

Signed-off-by: Wenqi Li [email protected]

followup of #4347

fixes error:

 ======================================================================                                                                                                                                                                                                                                       
 ERROR: test_timing (__main__.IntegrationWorkflows)                                                                          
 ----------------------------------------------------------------------                                                      
 ValueError: operands could not be broadcast together with shapes (0,) (40,)                                                 
                                                                                                                             
 The above exception was the direct cause of the following exception:                                                        
                                                                                                                             
 Traceback (most recent call last):                                                                                          
   File "/opt/monai/tests/utils.py", line 575, in _wrapper                                                                   
     raise RuntimeError(res.traceback) from res                                                                              
 RuntimeError: Traceback (most recent call last):                                                                            
   File "/opt/monai/tests/utils.py", line 526, in run_process                                                                
     output = func(*args, **kwargs)                                                                                          
   File "/opt/monai/tests/utils.py", line 607, in _call_original_func                                                        
     return f(*args, **kwargs)                                                                                               
   File "/opt/monai/tests/test_integration_workflows.py", line 354, in test_timing                                           
     self.train_and_infer(idx=2)                                                                                             
   File "/opt/monai/tests/test_integration_workflows.py", line 330, in train_and_infer                                       
     _test_saved_files(postfix="seg_handler")                                                                                
   File "/opt/monai/tests/test_integration_workflows.py", line 326, in _test_saved_files                                     
     self.assertTrue(test_integration_value(TASK, key="output_sums_2", data=values, rtol=1e-2))                              
   File "/opt/monai/tests/testing_data/integration_answers.py", line 593, in test_integration_value                          
     if np.allclose(data, value, rtol=rtol):                                                                                 
   File "<__array_function__ internals>", line 180, in allclose                                                              
   File "/opt/conda/lib/python3.8/site-packages/numpy/core/numeric.py", line 2251, in allclose                               
     res = all(isclose(a, b, rtol=rtol, atol=atol, equal_nan=equal_nan))                                                     
   File "<__array_function__ internals>", line 180, in isclose                                                               
   File "/opt/conda/lib/python3.8/site-packages/numpy/core/numeric.py", line 2361, in isclose                                
     return within_tol(x, y, atol, rtol)                                                                                     
   File "/opt/conda/lib/python3.8/site-packages/numpy/core/numeric.py", line 2342, in within_tol                             
     return less_equal(abs(x-y), atol + rtol * abs(y))                                                                       
 ValueError: operands could not be broadcast together with shapes (0,) (40,)  

Status

Readyd

Types of changes

  • Non-breaking change (fix or new feature that would not break existing functionality).
  • Breaking change (fix or new feature that would cause existing functionality to change).
  • New tests added to cover the changes.
  • Integration tests passed locally by running ./runtests.sh -f -u --net --coverage.
  • Quick tests passed locally by running ./runtests.sh --quick --unittests --disttests.
  • In-line docstrings updated.
  • Documentation updated, tested make html command in the docs/ folder.

@wyli
Copy link
Contributor Author

wyli commented May 27, 2022

/integration-test

@wyli wyli marked this pull request as ready for review May 27, 2022 11:41
@wyli wyli requested review from Nic-Ma and yiheng-wang-nv May 27, 2022 11:41
@wyli
Copy link
Contributor Author

wyli commented May 27, 2022

/build

@wyli wyli enabled auto-merge (squash) May 27, 2022 17:23
@wyli wyli closed this May 27, 2022
auto-merge was automatically disabled May 27, 2022 17:25

Pull request was closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants