giuliowaitforitdavide / recsyslearn

GNU General Public License v3.0
7 stars 0 forks source link

WrongProportionsException raised if proportions are a list #39

Open mmosc opened 11 months ago

mmosc commented 11 months ago

Hi!

In v1.0.1 calling the InteractionSegmentation with a list of proportions summing up to 1. sometimes (wrongly) raises the WrongProportionsException. However, if this list is first converted to a np.array and then passed to the segmentation, the Exception is not raised. (see attachments)

I therefore see two possible solutions:

  1. Require the proportions argument to be a np.array (and not a list as it currently is)
  2. Convert the proportions to a np.array at the beginning of the segment method

What do you think would be best, @giuliowaitforitdavide ?

Cheers, Marta

Screenshot from 2023-08-22 16-19-28 Screenshot from 2023-08-22 16-20-31