You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I just wanted to point out a small corner case I encountered while using your code, in basemodel.py, when you are appending the scores to the train_result, what might happen is that the current batch is missing a class (i.e. if it's binary classification y_true has only 0 in it for example), this creates a problem when using the cross_entropy and auc_score as they need all classes to be present in each batch so I corrected the corss_entropy case by specifying the classes with the labels parameter, but the same doesn't seem to work with the auc case for which I implemented a try and catch.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi, I just wanted to point out a small corner case I encountered while using your code, in basemodel.py, when you are appending the scores to the train_result, what might happen is that the current batch is missing a class (i.e. if it's binary classification y_true has only 0 in it for example), this creates a problem when using the cross_entropy and auc_score as they need all classes to be present in each batch so I corrected the corss_entropy case by specifying the classes with the labels parameter, but the same doesn't seem to work with the auc case for which I implemented a try and catch.
Beta Was this translation helpful? Give feedback.
All reactions