Change test of continuous labels #25835
thomasryck
started this conversation in
Ideas
Replies: 1 comment
-
I am moving this to an issue to improve its visibility. #25933 I guess it could be possible to adapt this code indeed. It seems like we could put the logic we want in the scikit-learn/sklearn/utils/multiclass.py Lines 122 to 123 in e305e80 Googling a bit, it seems like Comment: the cast is not safe even from |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi
I was using the method type_of_target from the multiclass file.
And I had some warnings because of the following line.
Indeed as there is a cast into int32, and I have some int64 and float64 arrays, the cast is not safe.
I was asking myself if it could be a could idea to modify the test and to test by taking the floor of the array in place of doing a cast.
I do not know if it is really better, for now I just think that it could avoid not safe cast (that are not risky in that case).
And I do not know what is the best regarding time and memory.
Beta Was this translation helpful? Give feedback.
All reactions