complete gen_features.py