why would this solve a memory problem?
And if it does, there is a bug, since set_features references the features from clone