edm icon indicating copy to clipboard operation
edm copied to clipboard

fix infinite loop for small dataset

Open djstrong opened this issue 4 years ago • 2 comments

fix infinite loop if number of sentences is smaller than number of sections (30)

djstrong avatar Feb 13 '21 11:02 djstrong

Thank you for submitting the Pull Request. Much appreciated.

Two comments at this stage:

  1. Could you add a test case for that? (So that also the exact problem is better understood)
  2. I am wondering about the min(1,) statement. It seems that when total/sections > 1 the result will be 1 and otherwise it will be less than 1. -> I am not fully sure how this solves the problem you have encountered. Could you elaborate, please? I think this is where the test case would come in handy.

All the best, Niko

ai-nikolai avatar Feb 13 '21 15:02 ai-nikolai

Sorry, it should be max.

djstrong avatar Feb 13 '21 15:02 djstrong