[scikit-learn] custom scorer needs group information: how?

Emanuele Olivetti emanuele.olivetti at gmail.com
Thu Jun 3 03:04:10 EDT 2021


Thank you Adrin,

Your solution based on using Pandas DataFrames by leveraging the indexing
that comes with them is pretty ingenious. Moreover, the whole StackOverflow
page is quite interesting. I'll try also your suggestion.

Best,

Emanuele

On Wed, Jun 2, 2021 at 11:26 AM Adrin <adrin.jalali at gmail.com> wrote:

> Hi Emanuele,
>
> In the meantime, you could also try the hack I have written here:
> https://stackoverflow.com/questions/49581104/sklearn-gridsearchcv-not-using-sample-weight-in-score-function/49598597#49598597
>
> Cheers,
> Adrin
>
> On Sat, May 22, 2021 at 7:54 PM Emanuele Olivetti <
> emanuele.olivetti at gmail.com> wrote:
>
>> Hi Alex,
>>
>> Thank you for the quick response. That SLEP looks very interesting!
>> Indeed I had the impression that there was no easy way around the issue of
>> automatically passing additional (meta)data to scorers. Irrespective of my
>> issue, I hope the SLEP will get the green light soon.
>>
>> Best,
>>
>> Emanuele
>>
>> On Sat, May 22, 2021 at 10:27 AM Alexandre Gramfort <
>> alexandre.gramfort at inria.fr> wrote:
>>
>>> hi Emanuelle,
>>>
>>> I would suggest you have a look at
>>> https://github.com/scikit-learn/enhancement_proposals/pull/55
>>>
>>> it's work in progress though
>>>
>>> Alex
>>>
>>> _______________________________________________
>>> scikit-learn mailing list
>>> scikit-learn at python.org
>>> https://mail.python.org/mailman/listinfo/scikit-learn
>>>
>> _______________________________________________
>> scikit-learn mailing list
>> scikit-learn at python.org
>> https://mail.python.org/mailman/listinfo/scikit-learn
>>
> _______________________________________________
> scikit-learn mailing list
> scikit-learn at python.org
> https://mail.python.org/mailman/listinfo/scikit-learn
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.python.org/pipermail/scikit-learn/attachments/20210603/9d22bc34/attachment.html>


More information about the scikit-learn mailing list