I\'m working on an implementation of an Extended Isolation Forest for a uni project. Everything works fine except for one part, which is the splitting of a dataset