Python Replace String Using Sed With Variables In Research