Revert part of 0733d93b, which removed a descriptive comment for a complicated function and mixed feature processing and feature generation.
Revert part of 0733d93b, which removed a descriptive comment for a complicated function and mixed feature processing and feature generation.

dssg/tweedr,dssg/tweedr,dssg/tweedr,dssg/tweedr