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

[FIX] owrocanalysis: Fix test for non empty points array #5571

Merged
merged 1 commit into from
Aug 28, 2021

Conversation

ales-erjavec
Copy link
Contributor

Issue

ROC Analysis raises

---------------------------- ValueError Exception -----------------------------
Traceback (most recent call last):
  File "/Users/aleserjavec/Documents/workspace/orange3/Orange/widgets/evaluate/owrocanalysis.py", line 674, in _on_mouse_moved
    if pts:
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
-------------------------------------------------------------------------------

on mouse hover when two (or more) hovered threshold points are close to each other in viewport.

E.g on Ionospere with logistic regression:

Screen Shot 2021-08-27 at 15 31 16

run the mouse cursor over the curve on a small sized ROC Analysis plot.

Description of changes
  • Fix test for non empty points array
Includes
  • Code changes
  • Tests
  • Documentation

`pts` is an np.ndarray, raises error on `if pts:`
@codecov
Copy link

codecov bot commented Aug 27, 2021

Codecov Report

Merging #5571 (9df9755) into master (79ac616) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #5571   +/-   ##
=======================================
  Coverage   85.90%   85.91%           
=======================================
  Files         313      313           
  Lines       65353    65352    -1     
=======================================
+ Hits        56143    56145    +2     
+ Misses       9210     9207    -3     

@janezd janezd merged commit 8569e42 into biolab:master Aug 28, 2021
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