fixed the script to handle photometry files with and without placeholders