def remove_str_from_keys(dct, key_str):
    """ convert dictionary keys by removing key_str"""
    new_dct = {}
    for key, value in dct.iteritems():
        if key_str in key:
            new_key = key.replace(key_str, '')
            new_dct[new_key] = value
        else:
            new_dct[key] = value
    return new_dct
