Closed MaksimMisin closed 11 months ago
I can't reproduce LightGBM example:
> python exmaple_lgb.py ...(training outputs)... ----- Found Rules ----- Traceback (most recent call last): File "example_lgb.py", line 51, in <module> print(mdl) File "../defragTrees.py", line 87, in __str__ box, vmin, vmax = self.__r2box(self.rule_[i], self.dim_) File "../defragTrees.py", line 187, in __r2box box[1, rr[0]-1] = np.minimum(box[1, rr[0]-1], rr[2]) IndexError: only integers, slices (`:`), ellipsis (`...`), numpy.newaxis (`None`) and integer or boolean arrays are valid indices
I am using python 3.7 with the following packages:
lightgbm==2.2.2 numpy==1.15.4 pandas==0.23.4 scikit-learn==0.20.1 scipy==1.1.0
On the related note, could you please add requirements.txt file.
requirements.txt
Thanks you for pointing out the bug. I found that defragTrees.py was trying to assign float values to the array indices. The bug is now fixed.
I can't reproduce LightGBM example:
I am using python 3.7 with the following packages:
On the related note, could you please add
requirements.txt
file.