basic code for high level features extraction.