Python Interpret String As Variable Frequency