epfl-lts2 / pygsp

Graph Signal Processing in Python
https://pygsp.rtfd.io
BSD 3-Clause "New" or "Revised" License
488 stars 93 forks source link

Small bug in utils.py #7

Closed dsacc closed 7 years ago

dsacc commented 7 years ago

In distanz():

# Size verification
if rx != ry:
    raise("The sizes of x and y do not fit")

when the condition is met the following error message is returned:

TypeError: exceptions must derive from BaseException

Something like the following should fix it:

# Size verification
if rx != ry:
    raise ValueError("The sizes of x and y do not fit")