refactored extract features lib such that we can scale it up more easily (currently the AttributeStats class prevents this, we need to write an alternative for this)