extract_targets.py tweaks