open(INFILE, "$inputfn") || die "Error reading input file: $!\n";