Skip to content
Snippets Groups Projects
Commit a4af457b authored by Bas Nijholt's avatar Bas Nijholt
Browse files

use isinstance

parent 3735b196
No related branches found
No related tags found
No related merge requests found
Pipeline #12045 passed
This commit is part of merge request !101. Comments created here will be created in the context of that merge request.
......@@ -216,7 +216,7 @@ class Learner1D(BaseLearner):
if real:
# either it is a float/int, if not, try casting to a np.array
if type(y) not in [float, int]:
if not isinstance(y, (float, int)):
y = np.asarray(y, dtype='float64')
# Add point to the real data dict
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment