def clean_for_iam(name):
 return re.sub('[^A-Za-z0-9+=,.@_-]+', '-', name)

def clean_for_iam ( name ) : return re . sub ( '[^A-Za-z0-9+=,.@_-]+' , '-' , name )
cleans a name to fit iams naming requirements .