swyft icon indicating copy to clipboard operation
swyft copied to clipboard

HDI ValueError in plot.py

Open CHBKoenders opened this issue 3 years ago • 1 comments

First off, this issue only occurs when the model has high certainty (probably due to overfitting, or too simple a problem).

The problem can occur in lines 123-125. This is because zm[v > levels[i]] can be empty if v has all the mass in one bin. This can be fixed by changing to >=. Maybe even better to do a try catch with a message to increase the number of bins or check for overtraining.

-Kees

CHBKoenders avatar Sep 02 '21 12:09 CHBKoenders

Nice find! I'll take a look.

bkmi avatar Sep 02 '21 15:09 bkmi

Stalled? Closing now. Reopen if still an issue.

cweniger avatar May 13 '23 19:05 cweniger